Here come the world
With that look in its eye
But certainly slight
A and B engage in trade. A exchanges resources up front for B's promise to pay his end of the bargain. That promise to pay usually has an explicit or implied near term time horizon. For example, furnace technician A inspects a furnace and then bills B for services rendered. The bill might provide a 30 day time window to pay. B has incurred a liability because B has received a benefit for which he has yet to pay.
A might reduce risk by requiring B to sign a formal contract up front. A is more prone to require this when his upfront resource outlay is substantial. Thus, roofer A may ask B to sign a contract in which B promises to pay A an agreed to amount once a new roof is installed. The contract might also specify the penalty to be incurred if B fails to pay within an agreed-to period.
B can also borrow money from A with the promise to repay principal with interest over some mutually agreed to period of time. If A and B engage in this kind of trade, then B incurs a special type of liability. B is borrowing economic resources in the present period with a promise to repay according to terms of the agreement in a future period. That repayment usually includes interest to be paid to A. Borrowing commonly requires a formal contract that is written and agreed to up front.
These features in combination--repayment in future periods, repayment with interest, and strong contract law context--make debt a particular type of liability. All debts are liabilities. But not all liabilities are debts.
If B fails to meet the terms of a debt agreement with A, then B is in default. Usually this involves B not paying the requisite amount of interest and/or principal on the requisite date. B has taken property from A with no or insufficient repayment. In a just system and if the contract is valid, A can take legal action against B to reclaim property or to enforce terms of the debt contract. A's legal recourse is stronger if the debt contract was 'secured' by assets of B.
If B fails to pay a bill owed to A for services rendered, then B is not in default. Instead, B has failed to live up to his end of a trade. Whether a formal contract was signed at the outset, this trade is still governed by contract law because the two parties agreed to exchange property and B has taken property from A with no or insufficient repayment. In a just system and if the contract involving the trade was valid, A can take legal action against B to obtain payment or to get his property back. However, A's legal recourse is stronger if a formal contract had been signed at the outset.