toip.tools

settle/payment/terms/accept

https://toip.tools/spec/settle/payment/terms/accept/0.1

The payee returns the agreed terms with its own signed acceptance. The payer checks that the terms are the ones it proposed and that the payee signed them. It then opens the escrow through the processor.

Sent
payee's party payer's party
Kind
One-way. No response is expected; any answer is a separate message.
Envelope
Signed by the issuer, addressed to one recipient, timestamped, and encrypted in a TSP Direct message. The signature and recipient binding prevent its use as a bearer token.
Defined in
projects/settle/src/protocol/specs.ts:9 as TERMS_ACCEPT
Handled in
projects/settle/src/agents/party.ts
Design
7. The Trust Tasks in projects/settle/docs/design.md

Payload

TypeScriptAs the handler declares it, in projects/settle/src/agents/party.ts
{ terms: Terms; acceptance: Acceptance }

Types it uses

TypeScriptprojects/settle/src/protocol/documents.ts:71
export interface Terms {
  type: "settle/terms";
  version: 1;
  payment: string;
  purpose: string;
  payer: Party;
  payee: Party & { credentials: Credential[] };
  arbiter: { did: string; key: Address };
  amount: { mint: Address; units: string; display: string };
  conditions: { policy: "settle/policies/attested-completion/1"; attester: string; disputeWindowSeconds: number };
  /** The processor's facilitator fee: `units` = max(price × bps, minUnits), funded on top of the price, paid on every outcome. */
  fee: { bps: number; minUnits: string; units: string; account: Address; to: string };
  threshold: number;
  refundAfter: number;
}
TypeScriptprojects/settle/src/protocol/documents.ts:94
/** A party's signature on the terms, as its own small document bound to the terms hash. */
export interface Acceptance {
  type: "settle/acceptance";
  issuer: string;
  termsHash: string;
  proof?: unknown;
}

Notes

The design says the payload is the terms with both proofs. The code sends the terms and the payee's acceptance only.

Document envelope

Every Trust Task uses this envelope. Replace payload with the structure shown above.

JSONShape of a document of this type
{
  "id": "urn:uuid:…",
  "type": "https://toip.tools/spec/settle/payment/terms/accept/0.1",
  "issuer": "did:key:… (the sender)",
  "recipient": "did:key:… (the receiver)",
  "issuedAt": "2026-11-06T18:00:00.000Z",
  "payload": { … },
  "proof": {
    "type": "DataIntegrityProof",
    "cryptosuite": "eddsa-jcs-2022",
    "verificationMethod": "did:key:…#…",
    "proofPurpose": "assertionMethod",
    "proofValue": "z…"
  }
}