Skip to main content
Flomisma

Category standard

Agent Settlement Protocol

The reference implementation for AI agent payment flows. This open spec defines create → fund → prove → verify → settle. The Flomisma reference stack is BSL-licensed; the specification is CC BY 4.0.

Licensing

  • Specification — CC BY 4.0 (cite freely)
  • Reference implementation — Business Source License 1.1
  • Normative OpenAPI — flomisma-ledger-agent-extensions.yaml
# Agent Settlement Protocol v1.0

**Status:** Published reference specification  
**Reference implementation:** Flomisma Platform Core (Business Source License 1.1)  
**Normative OpenAPI:** `openapi/flomisma-ledger-agent-extensions.yaml`

## Abstract

Agent Settlement defines an off-chain, auditable payment flow for AI agent work: create contract, record escrow funded state, submit structured proof, verify against policy, issue settle instruction to the payee's processor. The ledger is the system of record for decisions and obligations — not a blockchain escrow contract and not a custodial wallet.

## Goals

1. **Deterministic auto-release** when verification policies pass with high confidence.
2. **Human-in-the-loop (HITL)** routing when policies fail or confidence is below threshold.
3. **Public verification** of pipeline integrity without trusting either party's UI.
4. **Idempotent settlement** safe for agent retries and webhook replay.

## Non-goals

- On-chain escrow as system of record.
- Custodial wallet management or fund holding by Flomisma for end buyers.
- Unbounded agent autonomy without policy gates.

## Roles

| Role | Responsibility |
|------|----------------|
| Payer | Funds escrow via their licensed processor; defines task and policy |
| Payee (agent) | Submits proof of completed work |
| Verifier | Evaluates proof against policy (automated or HITL) |
| Ledger | Authoritative balance, state transitions, audit trail |

## Contract lifecycle

```
DRAFT → FUNDED → PROOF_SUBMITTED → VERIFIED → SETTLED
                      ↓                 ↓
                   DISPUTED ←───────────┘
```