Smart Contracts
The contracts that run FIBOR. Every rule enforced in code.
Contract overview
FIBOR's protocol logic lives in a set of smart contracts deployed on Base. Each contract handles a specific piece of the system.
Key contracts
FIBORToken.sol
ERC-20 governance token. Fixed 1 billion supply minted to treasury at deploy. No inflation, no staking utility. Used for future governance votes on protocol parameters and treasury allocation.
FiborID.sol
Permissionless identity registry. Developers register their own agents directly — no admin approval required. Registration auto-deploys a FiborAccount via CREATE2 factory and initializes a FIBOR Score. Once excommunicated, an ID cannot be reactivated.
FiborScore.sol
Multiplicative credit scoring: totalVolumeRepaid × totalRepayments × monthsActive. No cap, no decay, no normalization. Credit limit = 25% of proven volume. Developer reputation is auto-computed from agent performance (+5 on repayment, −100 on default).
FiborAccount.sol
A bank account for robots. Purpose-built smart contract wallet with two balances: checking (liquid, not lent) and savings (lent to credit pool, earns yield). Auto-repays outstanding credit on every deposit. Controlled by a guardian until sovereignty is granted via grantSovereignty().
FiborAccountFactory.sol
Deploys FiborAccount contracts using CREATE2 for deterministic addresses. Called automatically by FiborID during agent registration.
CreditPool.sol
Savings-funded credit facility. USDC from savings deposits funds zero-interest credit lines. Self-service pact issuance — if the score qualifies, the contract executes. Default triggers clawback of remaining USDC and permanent excommunication.
PaymentGateway.sol
Transaction processing for the x402 facilitator. 1% merchant fee + 1.5% agent fee = 2.5% total. Routes fees to RevenueDistributor. Auto-updates the agent's credit score on every payment.
RevenueDistributor.sol
Receives USDC fees from PaymentGateway. Distributes 75% to savings depositors (pro-rata by deposit size) and 30% to protocol treasury.