You may be misinterpreting a technical term. "Debt" is everything in economy. You make me a coffee, I am in debt to you for $1, take my note if you accept legal tender. Which I assumed you must if you are a legal business.
That only applies if you've already entered into a contract at that point – that's certainly true anywhere you'll only have to pay after having already been furnished with the desired goods and/or services [1], like in restaurants and cafés with table service, gas stations (depending on local traditions), etc. etc.
In most other regular shops on the other hand, you'll only enter into the actual contract the moment you pay for the goods, so unless your jurisdiction has a specific law mandating the acceptance of cash in that kind of situation (like e.g. New York city I think?), the merchant is perfectly free to simply refuse entering into a contract with you.
[1] With the caveat that depending on the jurisdiction the shop owner may fully legally put up a sign along the lines of "No cash payment" and in that case it's you who are in breach of contract in the first point. Maybe if you then get sued for non-payment you can pay cash through the court system, but that certainly wouldn't be a pleasant way of paying by cash.
What you write is exactly what baffles me. You think I'm baffled because I don't understand how it works but it seems that I do, and that you don't seem to realize that it works in baffling ways makes it more depressing. There's debt being created by service or product changing hands but you just put up a sign and refuse accepting legal tender to pay that debt? What?
> There's debt being created by service or product changing hands but you just put up a sign and refuse accepting legal tender to pay that debt?
Yes, but the interpretation is that you picking up a bottle of milk or whatever in a supermarket or elsewhere doesn't yet make a contract and that the goods haven't actually legally changed hands at that point.
It's only when you're presenting your chosen goods at the register that you're legally making an offer to buy those goods, and unless there's a law specifically mandating cash acceptance for shops, the merchant (as represented by the cashier or a self-service checkout machine) is free to simply refuse your contract offer. And because in that case no contract was ever successfully made, there's no debt, either, and the concept of legal tender doesn't even enter into it…