An agreement in the form of a contract, written or verbal, in which someone gets money or the opportunity to use an amount of money in return for agreeing to pay it back at some point in the future usually with interest. In double entry accounting, «credit» is the contraty to «debit» and means the company has decreased it assets (good purchased by customers) or increased its liabilities (financing/loans received by the company).
To have good/bad credit means a person or a company is good/bad (correct amount, on time, etc.) at paying back the money they had borrowed in the past.
When one applies for credit or a line of credit, the customer will be provided with a maximum amount of money that can be spent within the provisions of the contract. This amount, called a credit limit, can be renewed, extended or decreased based on the needs of both parties (usually the borrower and lended). The most typical example of this is a credit card, with which you can buy things now using the credit and pay for them either all at once at some time in the future or little by little over time while in both cases understanding you will end up paying back more than you originally spent because of the interest that´s added on.