A smart contract is program code deployed to a blockchain or distributed ledger that changes ledger state according to predefined rules when it is invoked and the required conditions are satisfied.
Smart contracts can transfer tokens, manage collateral, execute exchanges, enforce permissions, distribute payments, and coordinate tokenized settlement. Their execution is deterministic with respect to the inputs and state recognized by the ledger, but they cannot directly observe off-chain facts without external data mechanisms such as oracles. Smart-contract behavior also depends on the code, upgrade controls, administrative keys, and underlying network.
A smart contract provides programmable on-chain logic. It does not independently determine the truth of external events unless those events are supplied through an oracle or other trusted input.
Stablecoin issuance, DeFi liquidity, collateral management, bridges, and programmable payments often depend on smart-contract code, making code and governance risk part of the financial arrangement.
A stablecoin smart contract can verify a signed transfer request and update token balances according to the token's programmed rules.