FRAME · API REFERENCE

Integrate settlement.
Verify the outcome.

Connect your bank’s settlement and reporting systems to Frame. Submit instructions, follow their progress, and retain evidence your counterparty can verify.

This reference covers bank settlement submission, policy updates, and reporting in this build. URLs are relative to your Frame host. There is no universal sandbox URL: use the origin provided by your operator. Availability depends on the configured rails, tenants, and services.

Authentication & tenants

Begin with GET /v1/auth/config. In local mode, sign in with an onboarded email and password. Login returns an identity token and tenant memberships; the token does not grant access to every tenant. Select a membership with X-Frame-Tenant on subsequent requests. Send the token as Authorization: Bearer …. Browser sessions can use the frame_session cookie instead.

export FRAME_URL='http://localhost:8080'
# login.json: {"email":"your-email","password":"your-password"}
# Keep this file private. Use HTTPS for remote deployments.
curl --fail-with-body -sS "$FRAME_URL/v1/auth/login" \
  -H 'Content-Type: application/json' --data-binary @login.json

# Set FRAME_TOKEN from the response and FRAME_TENANT to a membership ID.
curl --fail-with-body -sS "$FRAME_URL/v1/me" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT"

Login values are under data: read data.token, data.expires_at and data.tenants. Use GET /v1/capabilities to discover the caller's available actions. Roles grant capabilities: viewers read; operators settle; approvers approve; admins also manage policy. Cryptographic approvals still require distinct authorized signers even when an admin has both capabilities.

dev-unverified is a development mode, not an integration credential. Bank integrations use an onboarded operator membership. The API currently has no separate API-key or client-credentials grant and no refresh-token endpoint. Reauthenticate when the 12-hour session expires or is revoked.

Settle & verify

  1. Prepare the tenant. An ACTIVE policy must be installed through the four-eyes workflow. Verify the attestation and sealing key before encrypting a policy. Register counterparties and arrange the signed funds, compliance, rates, and finality inputs required by that policy and rail.
  2. Submit the instruction. Send POST /settlements with an explicit tenant, a stable bank_request_id, legs, and attested inputs. The request schema below describes their wire format. Request bodies containing signatures must be produced by the authorized signer; editing a signed field invalidates the signature.
  3. Follow the returned ID. Read GET /settlements/{id}. HTTP 200 means the request returned a settlement record; inspect its status to distinguish approval, denial, pending finality, and recovery. Statuses include accepted, authorised, sealed, dispatched, confirmed, denied, reversed, stuck, and resolved_manual. Escalate stuck to the bank’s recovery procedure.
  4. Collect evidence. Download GET /settlements/{id}/pack. A sealed denial also has evidence. A 409 with Retry-After means the evidence is not sealed yet. A 410 means admission rejected the settlement and no sealed verdict will exist. Do not poll a 410 indefinitely.
  5. Verify independently. Retain the pack and verify it with frame-verify or Frame's browser verifier, using independently pinned trust material. A downloaded pack alone is not proof that a real chain anchor is final.
# instruction.json contains the complete bank-authorized instruction.
curl --fail-with-body -sS "$FRAME_URL/settlements" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT" \
  -H 'Content-Type: application/json' --data-binary @instruction.json

# FRAME_SETTLEMENT is the id returned above.
curl --fail-with-body -sS "$FRAME_URL/settlements/$FRAME_SETTLEMENT" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT"
curl --fail-with-body -sS "$FRAME_URL/settlements/$FRAME_SETTLEMENT/pack" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT" --output settlement-pack.cbor

Retry discipline. Settlement intake is keyed by (tenant, bank_request_id). After a timeout, retry the same instruction with the same explicit tenant and request ID. Changing the ID creates a new instruction. This is not a general idempotency guarantee for other POST endpoints. Confirming a leg requires the rail's applicable finality evidence; break-glass resolution is a separate four-eyes action.

Install & update policies

A policy update installs a new immutable version. Author and approver work with bank-held keys; Frame receives the sealed payload and their signatures. Arrange live governance key bindings with your operator before the first submission. Both keys need role=attester, purpose=approval, and root-signed policy-governance delegations inside the payload.

  1. Fetch GET /v1/policies/sealing-key. Verify the attestation, measurement and bound sealing key against bank-held pins. A key returned by the same host you are checking is not an independent trust anchor.
  2. Read GET /policies?tenant=… for the policy key’s full lineage, including deactivation tombstones. The maximum version is the signing floor; use 0 only when the history is empty. For a counterparty policy, pass party consistently on history, governance and submission calls.
  3. Prepare the versioned governance JSON payload bank-side: frame_policy_payload: "v1", governance_root, delegations, and cel. Each delegation carries tenant, purpose, key, nonzero expiry in Unix seconds, and the root’s signature. Seal the complete JSON bytes with crypto_box_seal to the verified enclave key. Raw CEL is not the current payload format. For a root rotation, include the outgoing root’s signed root_rotation containing prev_root and sig.
  4. Have two distinct authorized keys sign the same frame.policy.v2 preimage below. The approver must verify the ciphertext corresponds to the source and governance being approved. Keep the authoring document and its exact byte representation bank-side.
  5. POST /v1/policies/submit. Omit the optional rules field to avoid storing plaintext source on the host. Retain the returned version, policy hash, governance hash and leaf index. Compare the governance commitment with the bank’s expected root and delegations.
  6. Download /v1/policies/receipts/{leaf_index}/pack. Verify the receipt against independently pinned trust material and your retained source document.
Signing bytes and governance payload

All lengths and counts in DomainSep are unsigned 32-bit big-endian integers. Numeric fields below are unsigned 64-bit big-endian. Hex and base64 are wire encodings: signatures cover decoded bytes.

DomainSep(tag, fields...) =
  u32be(len(tag)) || UTF8(tag) || u32be(number_of_fields) ||
  for each field: u32be(len(field)) || field

policy_signature = Ed25519.Sign(private_key,
  DomainSep("frame.policy.v2",
    policy_key_uuid_16_bytes,
    u64be(version_floor),
    BLAKE3_256(ciphertext_bytes),
    source_hash_32_bytes,
    u64be(expiry_unix_seconds)))

source_hash = BLAKE3_256(
  DomainSep("frame.policy.source.v1", exact_authoring_document_bytes))

# If there is no authoring document, source_hash is 32 zero bytes.
# version_floor is signed but is NOT a field in the submit JSON.
# The server uses the stored maximum version when checking the signatures.

delegation_signature = Ed25519.Sign(governance_root_private_key,
  DomainSep("frame.govdelegation.v1",
    policy_key_uuid_16_bytes, UTF8(purpose), delegate_public_key_32_bytes,
    u64be(not_after_unix_seconds)))

root_rotation_signature = Ed25519.Sign(outgoing_root_private_key,
  DomainSep("frame.govrootrotation.v1",
    policy_key_uuid_16_bytes, outgoing_root_32_bytes, new_root_32_bytes))

The current bank Policy Console implements this protocol, including source-to-ciphertext checks and the governance envelope. Use its matching authoring engine and signing implementation when building a bank client.

curl --fail-with-body -sS "$FRAME_URL/v1/policies/submit" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT" \
  -H 'Content-Type: application/json' --data-binary @signed-policy.json

Concurrent updates and uncertain outcomes. An intervening activation or deactivation changes the floor and invalidates the earlier signatures. Read the lineage again and obtain fresh approvals. After a timeout, check whether the submitted policy hash already activated before signing again. Policy submission has no idempotency key. Deactivation appends a tombstone and stops new intake until a later activation; it uses the policy capability and has no signature fields in its request.

Reports & queries

Use GET /settlements/{id} to reconcile IDs you submitted, and GET /v1/positions for positions derived from confirmed settlement history. The recent settlements, activity, timeline and sealed-log views are bounded; they are not a complete bank statement or a proof of no missing settlements. Some views return an empty success response on a store read failure. Keep your bank’s submission ledger and evidence receipts.

For treasury reporting, discover GET /v1/treasury/groups, then select a group_id. Report endpoints verify source evidence before returning data. Treasury JSON preserves exact amounts as decimal strings and may encode absent collections as null. Their JSON is a direct report object, unlike the success/data envelopes used by many query views. Use as_of for a past RFC3339 checkpoint, from/to for a date window, or csv to request a named export. Report dates and journal dates have their own documented bases.

curl --fail-with-body -sS --get "$FRAME_URL/v1/treasury/report" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT" \
  --data-urlencode "group_id=$FRAME_GROUP_ID" \
  --data-urlencode 'from=2026-09-01' \
  --data-urlencode 'to=2026-09-30' \
  --data-urlencode 'csv=journal' --output journal.csv

Download GET /v1/treasury/pack?group_id=… alongside the report for offline evidence. A tax worklist’s review_date compares dates against current balances; it does not rewind the ledger.

Formats & errors

ValueWire convention
Money & ratesExact integer units at a declared scale. For settlement money, {"asset":"USD","scale":2,"units":"12345"} represents 123.45 USD. Keep decimal strings as strings; never round through floating point.
IdentifiersFollow each field's schema. Settlement and tenant UUIDs accept 32 hexadecimal characters with optional hyphens; responses use the conventional hyphenated form. Do not substitute a display name.
TimeRead the field contract: settlement inputs use milliseconds; JWT expiry uses Unix seconds. They are not interchangeable.
JSON bodiesSend Content-Type: application/json. The common JSON decoder limits requests to 1 MiB; individual endpoints can impose different limits.
PaginationEndpoint-specific query parameters and response shapes. There is no universal cursor or list envelope.

Most API failures return JSON such as {"error":"description"}. Routing failures, upstream downloads, and streams can use other formats. Preserve the HTTP status and X-Request-ID when investigating an error. Do not classify an enclave denial solely from the HTTP status.

StatusClient action
400Correct the request or missing input; repeating unchanged usually cannot help.
401 / 403Reauthenticate or check tenant membership, capability, and signer authority.
404Check the ID, tenant, route, and deployment feature availability. Resources outside the active tenant can be hidden as not found.
409Inspect the conflict. For an unsealed settlement pack, honor Retry-After; other conflicts may need operator action.
410For a settlement pack, admission rejection is permanent: no sealed verdict will arrive.
429Back off and honor Retry-After when present.
5xxCheck readiness and service configuration. Retry with bounded backoff only when the operation is safe to repeat.

Endpoint reference

Search by method, path, capability, or subject. Each operation has a stable link and a curl template. Replace path variables and prepare any named request file before running it. This bank contract excludes consumer-portal, demo and platform-administration endpoints. Schemas describe JSON wire shapes; conditional business requirements and signed payload constraints still apply. Optional properties may be omitted; clients should tolerate additive response fields. Expand requests and responses for the full contract.

Authentication

GET /v1/auth/config

Discover authentication mode

Public · no session required

Call before login. The success.data.mode field identifies local or dev-unverified mode. Local login requires an onboarded active account.

Responses
{
  "200": {
    "content": {
      "application/json": {
        "example": {
          "data": {
            "guest_demo_enabled": false,
            "login_url": "/v1/auth/login",
            "me_url": "/v1/me",
            "mode": "local",
            "policy_console_contract": 2
          },
          "success": true
        },
        "schema": {
          "properties": {
            "data": {
              "properties": {
                "google_url": {
                  "type": "string"
                },
                "guest_demo_enabled": {
                  "type": "boolean"
                },
                "login_url": {
                  "type": "string"
                },
                "me_url": {
                  "type": "string"
                },
                "mode": {
                  "enum": [
                    "local",
                    "dev-unverified"
                  ],
                  "type": "string"
                },
                "policy_console_contract": {
                  "type": "integer"
                },
                "policy_console_url": {
                  "type": "string"
                }
              },
              "type": "object"
            },
            "success": {
              "type": "boolean"
            }
          },
          "required": [
            "success",
            "data"
          ],
          "type": "object"
        }
      }
    },
    "description": "Successful response. Discover authentication mode."
  }
}
curl --fail-with-body -sS "$FRAME_URL/v1/auth/config"

POST /v1/auth/login

Create a bank operator session

Public · no session required

Authenticates email and password in local mode. Read data.token, data.expires_at and data.tenants. Current tokens expire after 12 hours and can be revoked earlier. Select an authorized tenant on subsequent requests. No client-credentials or API-key token grant is implemented.

JSON request fields

FieldTypeDescription
email
required
stringOnboarded active bank operator email.
password
required
string
Request body
{
  "content": {
    "application/json": {
      "schema": {
        "properties": {
          "email": {
            "description": "Onboarded active bank operator email.",
            "type": "string"
          },
          "password": {
            "type": "string",
            "writeOnly": true
          }
        },
        "required": [
          "email",
          "password"
        ],
        "type": "object"
      }
    }
  },
  "required": true
}
Responses
{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "properties": {
            "data": {
              "properties": {
                "email": {
                  "type": "string"
                },
                "expires_at": {
                  "description": "Unix seconds; current session lifetime is 12 hours.",
                  "type": "integer"
                },
                "tenants": {
                  "items": {
                    "properties": {
                      "id": {
                        "type": "string"
                      },
                      "name": {
                        "type": "string"
                      },
                      "party": {
                        "type": "string"
                      },
                      "role": {
                        "type": "string"
                      },
                      "status": {
                        "type": "string"
                      }
                    },
                    "type": "object"
                  },
                  "type": "array"
                },
                "token": {
                  "description": "Identity-only bearer JWT. Treat as a secret.",
                  "type": "string"
                }
              },
              "required": [
                "token",
                "expires_at",
                "email",
                "tenants"
              ],
              "type": "object"
            },
            "success": {
              "type": "boolean"
            }
          },
          "required": [
            "success",
            "data"
          ],
          "type": "object"
        }
      }
    },
    "description": "Successful response. Create a bank operator session."
  },
  "400": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Invalid request, malformed identifier, or unmet input requirement."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "404": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Resource not found in the caller scope."
  },
  "429": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Rate limited. Back off; honor Retry-After when supplied."
  },
  "500": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Internal failure."
  }
}
curl --fail-with-body -sS -X POST "$FRAME_URL/v1/auth/login" \
  -H 'Content-Type: application/json' --data-binary @login.json

GET /v1/capabilities

Discover permitted actions

Bank session · read capability

Returns role and capability-dependent UI/action metadata. Authorization remains enforced at each operation. This is discovery, not a substitute for checking errors.

Parameters

NameTypeDescription
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.
Responses
{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "properties": {
            "data": {
              "properties": {
                "actions": {
                  "items": {
                    "type": "string"
                  },
                  "type": "array"
                },
                "capabilities": {
                  "items": {
                    "type": "string"
                  },
                  "type": "array"
                },
                "role": {
                  "type": "string"
                },
                "sections": {
                  "items": {
                    "type": "string"
                  },
                  "type": "array"
                }
              },
              "type": "object"
            },
            "success": {
              "type": "boolean"
            }
          },
          "type": "object"
        }
      }
    },
    "description": "Successful response. Discover permitted actions."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  }
}
curl --fail-with-body -sS "$FRAME_URL/v1/capabilities" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT"

GET /v1/me

Read identity and tenant memberships

Bank session · read capability

Returns success.data with username, role, capabilities, active tenant, memberships and session expiry when available. Memberships are evaluated per request; authority is not embedded in the token.

Parameters

NameTypeDescription
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.
Responses
{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "properties": {
            "data": {
              "properties": {
                "capabilities": {
                  "items": {
                    "type": "string"
                  },
                  "type": "array"
                },
                "role": {
                  "type": "string"
                },
                "session_exp": {
                  "type": "integer"
                },
                "tenant": {
                  "type": "string"
                },
                "tenants": {
                  "items": {
                    "properties": {
                      "id": {
                        "type": "string"
                      },
                      "name": {
                        "type": "string"
                      },
                      "party": {
                        "type": "string"
                      },
                      "role": {
                        "type": "string"
                      },
                      "status": {
                        "type": "string"
                      }
                    },
                    "type": "object"
                  },
                  "type": "array"
                },
                "username": {
                  "type": "string"
                }
              },
              "type": "object"
            },
            "success": {
              "type": "boolean"
            }
          },
          "type": "object"
        }
      }
    },
    "description": "Successful response. Read identity and tenant memberships."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  }
}
curl --fail-with-body -sS "$FRAME_URL/v1/me" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT"

Policies

GET /policies

Read policy lineage including deactivations

Bank session · read capability

Returns policies newest-first, including deactivation tombstones, plus active_in_enclave and active_policy_version. Compute the signature version floor from the maximum policies[].version (0 when empty), not from active_policy_version. A concurrent update invalidates signatures based on an older floor.

Parameters

NameTypeDescription
tenantquery · stringOptional explicit tenant UUID; membership checked. Defaults to active tenant.
partyquery · stringOptional registered counterparty policy key.
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.
Responses
{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "properties": {
            "active_in_enclave": {
              "type": "boolean"
            },
            "active_policy_version": {
              "type": "integer"
            },
            "policies": {
              "items": {
                "properties": {
                  "activated_at": {
                    "type": "string"
                  },
                  "catalog_version": {
                    "type": "string"
                  },
                  "deactivated": {
                    "type": "boolean"
                  },
                  "gov_hash": {
                    "type": "string"
                  },
                  "name": {
                    "type": "string"
                  },
                  "party": {
                    "type": "string"
                  },
                  "policy_hash": {
                    "type": "string"
                  },
                  "rules": {
                    "type": "string"
                  },
                  "source_hash": {
                    "type": "string"
                  },
                  "tenant": {
                    "type": "string"
                  },
                  "version": {
                    "type": "integer"
                  }
                },
                "type": "object"
              },
              "type": "array"
            }
          },
          "required": [
            "policies",
            "active_in_enclave",
            "active_policy_version"
          ],
          "type": "object"
        }
      }
    },
    "description": "Successful response. Read policy lineage including deactivations."
  },
  "400": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Invalid request, malformed identifier, or unmet input requirement."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  },
  "500": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Internal failure."
  }
}
curl --fail-with-body -sS "$FRAME_URL/policies" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT"

POST /v1/policies/deactivate

Retire the active policy

Bank session · policy capability

Appends a deactivation version and removes the active policy from the enclave. New settlement intake fails closed until another policy is activated. This operation uses the policy capability; its request carries no four-eyes signatures. History is retained. Read the new lineage before signing a reactivation.

Parameters

NameTypeDescription
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.

JSON request fields

FieldTypeDescription
partystringOptional registered counterparty policy key.
tenantstringTenant whose active policy is retired.
Request body
{
  "content": {
    "application/json": {
      "schema": {
        "properties": {
          "party": {
            "description": "Optional registered counterparty policy key.",
            "type": "string"
          },
          "tenant": {
            "description": "Tenant whose active policy is retired.",
            "type": "string"
          }
        },
        "type": "object"
      }
    }
  },
  "required": true
}
Responses
{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "properties": {
            "active": {
              "const": false,
              "type": "boolean"
            },
            "party": {
              "type": "string"
            },
            "seclogrs": {
              "properties": {},
              "type": "object"
            },
            "tenant": {
              "type": "string"
            },
            "version": {
              "type": "integer"
            }
          },
          "type": "object"
        }
      }
    },
    "description": "Successful response. Retire the active policy."
  },
  "400": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Invalid request, malformed identifier, or unmet input requirement."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  },
  "404": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Resource not found in the caller scope."
  },
  "500": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Internal failure."
  }
}
curl --fail-with-body -sS -X POST "$FRAME_URL/v1/policies/deactivate" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT" \
  -H 'Content-Type: application/json' --data-binary @request.json

GET /v1/policies/governance

Read pinned policy governance

Bank session · read capability

Returns pinned=false when the enclave has no governance for this policy key. When pinned, returns governance_root, delegations and gov_hash. Compare these with the bank-owned root and delegation set; do not derive trust solely from this response.

Parameters

NameTypeDescription
tenantquery · stringOptional explicit tenant UUID; membership checked. Defaults to active tenant.
partyquery · stringOptional registered counterparty policy key.
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.
Responses
{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "properties": {
            "delegations": {
              "items": {
                "properties": {},
                "type": "object"
              },
              "type": "array"
            },
            "gov_hash": {
              "type": "string"
            },
            "governance_root": {
              "type": "string"
            },
            "party": {
              "type": "string"
            },
            "pinned": {
              "type": "boolean"
            },
            "tenant": {
              "type": "string"
            }
          },
          "type": "object"
        }
      }
    },
    "description": "Successful response. Read pinned policy governance."
  },
  "400": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Invalid request, malformed identifier, or unmet input requirement."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  }
}
curl --fail-with-body -sS "$FRAME_URL/v1/policies/governance" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT"

GET /v1/policies/metadata

Read policy authoring metadata

Bank session · read capability

Returns the deployed policy authoring metadata and supported inputs. Compile and evaluate confidential source on the bank side with the matching authoring engine; retain the source and catalogue version.

Parameters

NameTypeDescription
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.
Responses
{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "properties": {},
          "type": "object"
        }
      }
    },
    "description": "Successful response. Read policy authoring metadata."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  }
}
curl --fail-with-body -sS "$FRAME_URL/v1/policies/metadata" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT"

GET /v1/policies/receipts/{leaf_index}/pack

Download a policy activation receipt

Bank session · read capability

Use leaf_index from the activation response. The CBOR artifact contains the sealed activation hashes; retain the authoring document bank-side and verify it against source_hash. It is an activation receipt, not a plaintext policy download.

Parameters

NameTypeDescription
leaf_index
required
path · stringZero-based sealed log leaf index.
anchor_txquery · stringOptional anchor reference bytes carried in the pack. Supplying a value does not prove chain finality; omission uses a development reference.
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.
Responses
{
  "200": {
    "content": {
      "application/cbor": {
        "schema": {
          "description": "Binary Frame verify-pack. Save the bytes; do not JSON-decode.",
          "format": "binary",
          "type": "string"
        }
      }
    },
    "description": "Successful response. Download a policy activation receipt."
  },
  "400": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Invalid request, malformed identifier, or unmet input requirement."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  },
  "404": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Resource not found in the caller scope."
  },
  "500": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Internal failure."
  }
}
curl --fail-with-body -sS "$FRAME_URL/v1/policies/receipts/${FRAME_LEAF_INDEX}/pack" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT" --output evidence.cbor

GET /v1/policies/sealing-key

Get the enclave sealing key and attestation

Bank session · read capability

Returns enclave_box_pub and trust_root as hex, log_id, policy metadata, and attestation fields when available. Validate the attestation and bind its measurement and key to your independent pins before sealing a policy.

Parameters

NameTypeDescription
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.
Responses
{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "properties": {
            "attestation_b64": {
              "type": "string"
            },
            "attestation_mode": {
              "type": "string"
            },
            "enclave_box_pub": {
              "type": "string"
            },
            "log_id": {
              "type": "string"
            },
            "measurement": {
              "type": "string"
            },
            "policy": {
              "properties": {},
              "type": "object"
            },
            "trust_root": {
              "type": "string"
            }
          },
          "type": "object"
        }
      }
    },
    "description": "Successful response. Get the enclave sealing key and attestation."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  }
}
curl --fail-with-body -sS "$FRAME_URL/v1/policies/sealing-key" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT"

POST /v1/policies/submit

Install or update a client-sealed policy

Bank session · policy capability

Both signers must be distinct, registered live approval keys and authorized by the enclave governance payload. The signed version floor is read by the server from current storage; there is no version_floor request field. Read GET /policies immediately before signing. This call is not idempotent: after a timeout, reconcile versions and hashes before preparing another submission. Omit rules to avoid retaining plaintext authoring source on the host.

Parameters

NameTypeDescription
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.

JSON request fields

FieldTypeDescription
approver_pub
required
stringA distinct registered live governance Ed25519 key, 32 bytes as hex.
approver_sig
required
string64-byte Ed25519 signature over exactly the same preimage, produced by the distinct approver.
author_pub
required
stringRegistered live governance Ed25519 key, 32 bytes as 64 hex characters.
author_sig
required
string64-byte Ed25519 signature (128 hex characters) over the frame.policy.v2 framed preimage.
catalog_versionstringOptional authoring catalogue version. Recorded as submitter-provided metadata, not cryptographic proof of the lowering.
ciphertext_b64
required
stringBase64 crypto_box_seal ciphertext of the versioned governance JSON payload, including CEL. Verify the enclave sealing key before encrypting. Raw CEL alone is not a valid current payload.
expiryintegerUnix SECONDS at which the approval expires; zero means no expiry. Included in both signatures.
namestringOptional display name, outside the sealed policy.
partystringOptional registered counterparty. When set, the counterparty UUID is the policy key used in the signature and version lineage.
rulesstringOptional plaintext authoring metadata retained by the host. Omit to keep the bank policy source confidential.
source_hashstring32-byte hex source-document commitment, BLAKE3(DomainSep(frame.policy.source.v1, source bytes)). Empty means the all-zero absent commitment.
tenantstringTenant whose live governance key registry authorizes both signers. Send explicitly.
Request body
{
  "content": {
    "application/json": {
      "schema": {
        "properties": {
          "approver_pub": {
            "description": "A distinct registered live governance Ed25519 key, 32 bytes as hex.",
            "pattern": "^[0-9a-fA-F]{64}$",
            "type": "string"
          },
          "approver_sig": {
            "description": "64-byte Ed25519 signature over exactly the same preimage, produced by the distinct approver.",
            "pattern": "^[0-9a-fA-F]{128}$",
            "type": "string"
          },
          "author_pub": {
            "description": "Registered live governance Ed25519 key, 32 bytes as 64 hex characters.",
            "pattern": "^[0-9a-fA-F]{64}$",
            "type": "string"
          },
          "author_sig": {
            "description": "64-byte Ed25519 signature (128 hex characters) over the frame.policy.v2 framed preimage.",
            "pattern": "^[0-9a-fA-F]{128}$",
            "type": "string"
          },
          "catalog_version": {
            "description": "Optional authoring catalogue version. Recorded as submitter-provided metadata, not cryptographic proof of the lowering.",
            "type": "string"
          },
          "ciphertext_b64": {
            "description": "Base64 crypto_box_seal ciphertext of the versioned governance JSON payload, including CEL. Verify the enclave sealing key before encrypting. Raw CEL alone is not a valid current payload.",
            "type": "string"
          },
          "expiry": {
            "description": "Unix SECONDS at which the approval expires; zero means no expiry. Included in both signatures.",
            "type": "integer"
          },
          "name": {
            "description": "Optional display name, outside the sealed policy.",
            "type": "string"
          },
          "party": {
            "description": "Optional registered counterparty. When set, the counterparty UUID is the policy key used in the signature and version lineage.",
            "type": "string"
          },
          "rules": {
            "description": "Optional plaintext authoring metadata retained by the host. Omit to keep the bank policy source confidential.",
            "type": "string"
          },
          "source_hash": {
            "description": "32-byte hex source-document commitment, BLAKE3(DomainSep(frame.policy.source.v1, source bytes)). Empty means the all-zero absent commitment.",
            "type": "string"
          },
          "tenant": {
            "description": "Tenant whose live governance key registry authorizes both signers. Send explicitly.",
            "type": "string"
          }
        },
        "required": [
          "ciphertext_b64",
          "author_pub",
          "author_sig",
          "approver_pub",
          "approver_sig"
        ],
        "type": "object"
      }
    }
  },
  "required": true
}
Responses
{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "properties": {
            "gov_hash": {
              "type": "string"
            },
            "leaf_index": {
              "description": "Coordinate for GET /v1/policies/receipts/{leaf_index}/pack.",
              "type": "integer"
            },
            "party": {
              "type": "string"
            },
            "policy_hash": {
              "type": "string"
            },
            "seclogrs": {
              "properties": {},
              "type": "object"
            },
            "source_hash": {
              "type": "string"
            },
            "tenant": {
              "type": "string"
            },
            "version": {
              "type": "integer"
            }
          },
          "required": [
            "tenant",
            "version",
            "policy_hash",
            "gov_hash",
            "leaf_index"
          ],
          "type": "object"
        }
      }
    },
    "description": "Successful response. Install or update a client-sealed policy."
  },
  "400": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Invalid request, malformed identifier, or unmet input requirement."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  },
  "404": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Resource not found in the caller scope."
  },
  "500": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Internal failure."
  }
}
curl --fail-with-body -sS -X POST "$FRAME_URL/v1/policies/submit" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT" \
  -H 'Content-Type: application/json' --data-binary @signed-policy.json

GET /v1/policies

List policy versions for display

Bank session · read capability

Returns success.data.items, capped at 50 versions, with name, version, hashes, status, and optional authoring metadata. Deactivation tombstones are omitted, so use GET /policies for the signing version floor. The list can return an empty success envelope for store or policy-key resolution failures.

Parameters

NameTypeDescription
tenantquery · stringOptional explicit tenant UUID; membership checked. Defaults to active tenant.
partyquery · stringOptional registered counterparty policy key.
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.
Responses
{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "properties": {
            "data": {
              "properties": {
                "items": {
                  "items": {
                    "properties": {
                      "activated_at": {
                        "type": "string"
                      },
                      "catalog_version": {
                        "type": "string"
                      },
                      "gov_hash": {
                        "type": "string"
                      },
                      "has_source": {
                        "type": "boolean"
                      },
                      "name": {
                        "type": "string"
                      },
                      "party": {
                        "type": "string"
                      },
                      "policy_hash": {
                        "type": "string"
                      },
                      "source_hash": {
                        "type": "string"
                      },
                      "status": {
                        "type": "string"
                      },
                      "tenant": {
                        "type": "string"
                      },
                      "version": {
                        "type": "integer"
                      },
                      "yaml": {
                        "type": "string"
                      }
                    },
                    "type": "object"
                  },
                  "type": "array"
                }
              },
              "type": "object"
            },
            "success": {
              "type": "boolean"
            }
          },
          "type": "object"
        }
      }
    },
    "description": "Successful response. List policy versions for display."
  },
  "400": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Invalid request, malformed identifier, or unmet input requirement."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  }
}
curl --fail-with-body -sS "$FRAME_URL/v1/policies" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT"

Queries

GET /v1/activity

Read recent settlement activity

Bank session · read capability

Returns success.data.transfers from the latest 100 settlement events. No pagination or query filters are implemented. Store failures can produce an empty success envelope; use this view for recent activity, not a complete ledger export.

Parameters

NameTypeDescription
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.
Responses
{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "properties": {
            "data": {
              "properties": {
                "transfers": {
                  "items": {
                    "properties": {},
                    "type": "object"
                  },
                  "type": "array"
                }
              },
              "type": "object"
            },
            "success": {
              "type": "boolean"
            }
          },
          "type": "object"
        }
      }
    },
    "description": "Successful response. Read recent settlement activity."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  }
}
curl --fail-with-body -sS "$FRAME_URL/v1/activity" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT"

GET /v1/positions

Query tenant positions

Bank session · read capability

Returns success.data.parties and aggregate, derived from confirmed settlement history. Frame is not the bank balance authority. Store or snapshot failures return errors; use bank balance attestations where authoritative balances are required.

Parameters

NameTypeDescription
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.
Responses
{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "properties": {
            "data": {
              "properties": {
                "aggregate": {
                  "items": {
                    "properties": {
                      "asset": {
                        "type": "string"
                      },
                      "display": {
                        "type": "string"
                      },
                      "form": {
                        "type": "string"
                      },
                      "scale": {
                        "type": "integer"
                      },
                      "units": {
                        "type": "string"
                      }
                    },
                    "type": "object"
                  },
                  "type": "array"
                },
                "parties": {
                  "items": {
                    "properties": {
                      "name": {
                        "type": "string"
                      },
                      "party_id": {
                        "type": "string"
                      },
                      "positions": {
                        "items": {
                          "properties": {
                            "asset": {
                              "type": "string"
                            },
                            "display": {
                              "type": "string"
                            },
                            "form": {
                              "type": "string"
                            },
                            "scale": {
                              "type": "integer"
                            },
                            "units": {
                              "type": "string"
                            }
                          },
                          "type": "object"
                        },
                        "type": "array"
                      },
                      "settlement_ids": {
                        "items": {
                          "type": "string"
                        },
                        "type": "array"
                      }
                    },
                    "type": "object"
                  },
                  "type": "array"
                }
              },
              "type": "object"
            },
            "success": {
              "type": "boolean"
            }
          },
          "type": "object"
        }
      }
    },
    "description": "Successful response. Query tenant positions."
  },
  "400": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Invalid request, malformed identifier, or unmet input requirement."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  },
  "503": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Required service or evidence input is unavailable."
  }
}
curl --fail-with-body -sS "$FRAME_URL/v1/positions" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT"

GET /v1/seclog-entries

Query sealed-log entries

Bank session · read capability

Returns success.data.items, total and cursor. The cursor is currently an empty string, not an implemented continuation token. Filtering happens within a bounded recent event scan; do not infer whole-history completeness from this response. An invalid ref_id shape returns an empty list.

Parameters

NameTypeDescription
ref_idquery · stringSettlement UUID to match.
entry_typequery · stringExact event kind to match.
limitquery · integerRequested result count. Default 100; values clamp to 1–500. Invalid integers retain the default.
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.
Responses
{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "properties": {
            "data": {
              "properties": {
                "cursor": {
                  "const": "",
                  "type": "string"
                },
                "items": {
                  "items": {
                    "properties": {
                      "at": {
                        "type": "string"
                      },
                      "created_at": {
                        "type": "string"
                      },
                      "entry_type": {
                        "type": "string"
                      },
                      "id": {
                        "type": "string"
                      },
                      "kind": {
                        "type": "string"
                      },
                      "leaf_index": {
                        "type": "integer"
                      },
                      "log_id": {
                        "type": "string"
                      },
                      "payload": {
                        "properties": {},
                        "type": "object"
                      },
                      "prev_hash": {
                        "type": "string"
                      },
                      "ref_id": {
                        "type": "string"
                      },
                      "sealed": {
                        "type": "boolean"
                      },
                      "sealed_in": {
                        "type": [
                          "integer",
                          "null"
                        ]
                      },
                      "self_hash": {
                        "type": "string"
                      },
                      "sequence_num": {
                        "type": "integer"
                      },
                      "tenant_id": {}
                    },
                    "type": "object"
                  },
                  "type": "array"
                },
                "total": {
                  "type": "integer"
                }
              },
              "type": "object"
            },
            "success": {
              "type": "boolean"
            }
          },
          "type": "object"
        }
      }
    },
    "description": "Successful response. Query sealed-log entries."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  },
  "500": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Internal failure."
  }
}
curl --fail-with-body -sS "$FRAME_URL/v1/seclog-entries" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT"

GET /v1/settlements

List recent settlements

Bank session · read capability

Returns success.data.items and SLA metadata for at most 200 recent settlements. There are no filter, pagination, or bank_request_id lookup parameters on this endpoint. An empty list can also result from unavailable store reads; do not use it as an exhaustive reconciliation or completeness proof.

Parameters

NameTypeDescription
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.
Responses
{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "properties": {
            "data": {
              "properties": {
                "items": {
                  "items": {
                    "properties": {
                      "actions": {
                        "items": {},
                        "type": "array"
                      },
                      "amount": {
                        "type": [
                          "integer",
                          "null"
                        ]
                      },
                      "amount_display": {
                        "type": "string"
                      },
                      "atomicity": {
                        "type": "string"
                      },
                      "bank_request_id": {
                        "type": "string"
                      },
                      "corridor_id": {
                        "type": "string"
                      },
                      "created_at": {
                        "type": "string"
                      },
                      "currency": {
                        "type": "string"
                      },
                      "from_party": {
                        "type": "string"
                      },
                      "from_party_id": {
                        "type": "string"
                      },
                      "from_party_name": {
                        "type": "string"
                      },
                      "id": {
                        "type": "string"
                      },
                      "settlement_kind": {
                        "type": "string"
                      },
                      "simulated": {
                        "type": "boolean"
                      },
                      "status": {
                        "type": "string"
                      },
                      "status_view": {
                        "properties": {
                          "label": {
                            "type": "string"
                          },
                          "phase": {
                            "type": "string"
                          },
                          "tone": {
                            "type": "string"
                          },
                          "value": {
                            "type": "string"
                          }
                        },
                        "type": "object"
                      },
                      "to_party": {
                        "type": "string"
                      },
                      "to_party_id": {
                        "type": "string"
                      },
                      "to_party_name": {
                        "type": "string"
                      },
                      "total_amount": {
                        "type": [
                          "integer",
                          "null"
                        ]
                      },
                      "updated_at": {
                        "type": "string"
                      }
                    },
                    "type": "object"
                  },
                  "type": "array"
                },
                "sla": {
                  "properties": {
                    "overdue_after_seconds": {
                      "type": "integer"
                    },
                    "warn_after_seconds": {
                      "type": "integer"
                    }
                  },
                  "type": "object"
                }
              },
              "type": "object"
            },
            "success": {
              "type": "boolean"
            }
          },
          "type": "object"
        }
      }
    },
    "description": "Successful response. List recent settlements."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  }
}
curl --fail-with-body -sS "$FRAME_URL/v1/settlements" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT"

GET /v1/timeline

Read a settlement event timeline

Bank session · read capability

Returns success.data.items and total from a bounded event scan. No cursor is accepted. An empty success envelope can indicate unavailable store reads; this endpoint does not establish completeness.

Parameters

NameTypeDescription
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.
Responses
{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "properties": {
            "data": {
              "properties": {
                "items": {
                  "items": {
                    "properties": {
                      "decision": {
                        "type": "string"
                      },
                      "event_type": {
                        "type": "string"
                      },
                      "leaf_index": {
                        "type": "integer"
                      },
                      "ref_id": {
                        "type": "string"
                      },
                      "settlement_id": {
                        "type": "string"
                      },
                      "timestamp": {
                        "type": "string"
                      }
                    },
                    "type": "object"
                  },
                  "type": "array"
                },
                "total": {
                  "type": "integer"
                }
              },
              "type": "object"
            },
            "success": {
              "type": "boolean"
            }
          },
          "type": "object"
        }
      }
    },
    "description": "Successful response. Read a settlement event timeline."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  }
}
curl --fail-with-body -sS "$FRAME_URL/v1/timeline" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT"

Reports

GET /v1/treasury/close-report

Get a historical close report

Bank session · read capability

Replays verified evidence strictly before the cutoff in the agreement timezone. before_date defaults to tomorrow in that timezone. The response is a direct JSON report, not a success/data envelope.

Parameters

NameTypeDescription
tenantquery · stringOptional explicit tenant UUID; membership checked. Defaults to active tenant.
group_id
required
query · stringConfigured treasury group identifier. Discover with GET /v1/treasury/groups.
before_datequery · stringExclusive YYYY-MM-DD cutoff in the agreement timezone.
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.
Responses
{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "properties": {
            "actual_basis": {
              "type": "string"
            },
            "before_date": {
              "type": "string"
            },
            "report": {
              "properties": {
                "forecast": {
                  "anyOf": [
                    {
                      "items": {
                        "properties": {
                          "confirmed_principal": {
                            "properties": {
                              "asset": {
                                "type": "string"
                              },
                              "scale": {
                                "type": "integer"
                              },
                              "units": {
                                "anyOf": [
                                  {
                                    "description": "Exact decimal integer units.",
                                    "pattern": "^-?[0-9]+$",
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              }
                            },
                            "type": "object"
                          },
                          "expected": {
                            "properties": {
                              "asset": {
                                "type": "string"
                              },
                              "scale": {
                                "type": "integer"
                              },
                              "units": {
                                "anyOf": [
                                  {
                                    "description": "Exact decimal integer units.",
                                    "pattern": "^-?[0-9]+$",
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              }
                            },
                            "type": "object"
                          },
                          "forecast_present": {
                            "type": "boolean"
                          },
                          "from_date": {
                            "type": "string"
                          },
                          "party": {
                            "type": "string"
                          },
                          "period_id": {
                            "type": "string"
                          },
                          "to_date": {
                            "type": "string"
                          },
                          "variance": {
                            "properties": {
                              "asset": {
                                "type": "string"
                              },
                              "scale": {
                                "type": "integer"
                              },
                              "units": {
                                "anyOf": [
                                  {
                                    "description": "Exact decimal integer units.",
                                    "pattern": "^-?[0-9]+$",
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              }
                            },
                            "type": "object"
                          }
                        },
                        "type": "object"
                      },
                      "type": "array"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "interest_closes": {
                  "anyOf": [
                    {
                      "items": {
                        "properties": {
                          "command_id": {
                            "type": "string"
                          },
                          "declaration": {
                            "properties": {
                              "due_date": {
                                "type": "string"
                              },
                              "from_date": {
                                "type": "string"
                              },
                              "source_ref": {
                                "type": "string"
                              },
                              "to_date": {
                                "type": "string"
                              }
                            },
                            "type": "object"
                          },
                          "rows": {
                            "anyOf": [
                              {
                                "items": {
                                  "properties": {
                                    "accrued": {
                                      "properties": {
                                        "asset": {
                                          "type": "string"
                                        },
                                        "scale": {
                                          "type": "integer"
                                        },
                                        "units": {
                                          "anyOf": [
                                            {
                                              "description": "Exact decimal integer units.",
                                              "pattern": "^-?[0-9]+$",
                                              "type": "string"
                                            },
                                            {
                                              "type": "null"
                                            }
                                          ]
                                        }
                                      },
                                      "type": "object"
                                    },
                                    "carried_after": {
                                      "properties": {
                                        "denominator": {
                                          "anyOf": [
                                            {
                                              "description": "Exact decimal integer units.",
                                              "pattern": "^-?[0-9]+$",
                                              "type": "string"
                                            },
                                            {
                                              "type": "null"
                                            }
                                          ]
                                        },
                                        "numerator": {
                                          "anyOf": [
                                            {
                                              "description": "Exact decimal integer units.",
                                              "pattern": "^-?[0-9]+$",
                                              "type": "string"
                                            },
                                            {
                                              "type": "null"
                                            }
                                          ]
                                        }
                                      },
                                      "type": "object"
                                    },
                                    "carried_before": {
                                      "properties": {
                                        "denominator": {
                                          "anyOf": [
                                            {
                                              "description": "Exact decimal integer units.",
                                              "pattern": "^-?[0-9]+$",
                                              "type": "string"
                                            },
                                            {
                                              "type": "null"
                                            }
                                          ]
                                        },
                                        "numerator": {
                                          "anyOf": [
                                            {
                                              "description": "Exact decimal integer units.",
                                              "pattern": "^-?[0-9]+$",
                                              "type": "string"
                                            },
                                            {
                                              "type": "null"
                                            }
                                          ]
                                        }
                                      },
                                      "type": "object"
                                    },
                                    "position": {
                                      "properties": {
                                        "amount": {
                                          "properties": {
                                            "asset": {
                                              "type": "string"
                                            },
                                            "scale": {
                                              "type": "integer"
                                            },
                                            "units": {
                                              "anyOf": [
                                                {
                                                  "description": "Exact decimal integer units.",
                                                  "pattern": "^-?[0-9]+$",
                                                  "type": "string"
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            }
                                          },
                                          "type": "object"
                                        },
                                        "creditor": {
                                          "type": "string"
                                        },
                                        "debtor": {
                                          "type": "string"
                                        },
                                        "id": {
                                          "type": "string"
                                        }
                                      },
                                      "type": "object"
                                    },
                                    "segments": {
                                      "anyOf": [
                                        {
                                          "items": {
                                            "properties": {
                                              "days": {
                                                "type": "integer"
                                              },
                                              "from_date": {
                                                "type": "string"
                                              },
                                              "policy_version": {
                                                "type": "integer"
                                              },
                                              "principal": {
                                                "properties": {
                                                  "asset": {
                                                    "type": "string"
                                                  },
                                                  "scale": {
                                                    "type": "integer"
                                                  },
                                                  "units": {
                                                    "anyOf": [
                                                      {
                                                        "description": "Exact decimal integer units.",
                                                        "pattern": "^-?[0-9]+$",
                                                        "type": "string"
                                                      },
                                                      {
                                                        "type": "null"
                                                      }
                                                    ]
                                                  }
                                                },
                                                "type": "object"
                                              },
                                              "rate": {
                                                "properties": {
                                                  "asset": {
                                                    "type": "string"
                                                  },
                                                  "day_count": {
                                                    "type": "string"
                                                  },
                                                  "scale": {
                                                    "type": "integer"
                                                  },
                                                  "units": {
                                                    "anyOf": [
                                                      {
                                                        "description": "Exact decimal integer units.",
                                                        "pattern": "^-?[0-9]+$",
                                                        "type": "string"
                                                      },
                                                      {
                                                        "type": "null"
                                                      }
                                                    ]
                                                  }
                                                },
                                                "type": "object"
                                              },
                                              "source_ref": {
                                                "type": "string"
                                              },
                                              "to_date": {
                                                "type": "string"
                                              }
                                            },
                                            "type": "object"
                                          },
                                          "type": "array"
                                        },
                                        {
                                          "type": "null"
                                        }
                                      ]
                                    }
                                  },
                                  "type": "object"
                                },
                                "type": "array"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "type": "object"
                      },
                      "type": "array"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "loans": {
                  "anyOf": [
                    {
                      "items": {
                        "properties": {
                          "accrual": {
                            "properties": {
                              "accrued": {
                                "properties": {
                                  "asset": {
                                    "type": "string"
                                  },
                                  "scale": {
                                    "type": "integer"
                                  },
                                  "units": {
                                    "anyOf": [
                                      {
                                        "description": "Exact decimal integer units.",
                                        "pattern": "^-?[0-9]+$",
                                        "type": "string"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  }
                                },
                                "type": "object"
                              },
                              "carried_after": {
                                "properties": {
                                  "denominator": {
                                    "anyOf": [
                                      {
                                        "description": "Exact decimal integer units.",
                                        "pattern": "^-?[0-9]+$",
                                        "type": "string"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "numerator": {
                                    "anyOf": [
                                      {
                                        "description": "Exact decimal integer units.",
                                        "pattern": "^-?[0-9]+$",
                                        "type": "string"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  }
                                },
                                "type": "object"
                              },
                              "carried_before": {
                                "properties": {
                                  "denominator": {
                                    "anyOf": [
                                      {
                                        "description": "Exact decimal integer units.",
                                        "pattern": "^-?[0-9]+$",
                                        "type": "string"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "numerator": {
                                    "anyOf": [
                                      {
                                        "description": "Exact decimal integer units.",
                                        "pattern": "^-?[0-9]+$",
                                        "type": "string"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  }
                                },
                                "type": "object"
                              },
                              "position": {
                                "properties": {
                                  "amount": {
                                    "properties": {
                                      "asset": {
                                        "type": "string"
                                      },
                                      "scale": {
                                        "type": "integer"
                                      },
                                      "units": {
                                        "anyOf": [
                                          {
                                            "description": "Exact decimal integer units.",
                                            "pattern": "^-?[0-9]+$",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      }
                                    },
                                    "type": "object"
                                  },
                                  "creditor": {
                                    "type": "string"
                                  },
                                  "debtor": {
                                    "type": "string"
                                  },
                                  "id": {
                                    "type": "string"
                                  }
                                },
                                "type": "object"
                              },
                              "segments": {
                                "anyOf": [
                                  {
                                    "items": {
                                      "properties": {
                                        "days": {
                                          "type": "integer"
                                        },
                                        "from_date": {
                                          "type": "string"
                                        },
                                        "policy_version": {
                                          "type": "integer"
                                        },
                                        "principal": {
                                          "properties": {
                                            "asset": {
                                              "type": "string"
                                            },
                                            "scale": {
                                              "type": "integer"
                                            },
                                            "units": {
                                              "anyOf": [
                                                {
                                                  "description": "Exact decimal integer units.",
                                                  "pattern": "^-?[0-9]+$",
                                                  "type": "string"
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            }
                                          },
                                          "type": "object"
                                        },
                                        "rate": {
                                          "properties": {
                                            "asset": {
                                              "type": "string"
                                            },
                                            "day_count": {
                                              "type": "string"
                                            },
                                            "scale": {
                                              "type": "integer"
                                            },
                                            "units": {
                                              "anyOf": [
                                                {
                                                  "description": "Exact decimal integer units.",
                                                  "pattern": "^-?[0-9]+$",
                                                  "type": "string"
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            }
                                          },
                                          "type": "object"
                                        },
                                        "source_ref": {
                                          "type": "string"
                                        },
                                        "to_date": {
                                          "type": "string"
                                        }
                                      },
                                      "type": "object"
                                    },
                                    "type": "array"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              }
                            },
                            "type": "object"
                          },
                          "observed_obligations": {
                            "anyOf": [
                              {
                                "items": {
                                  "properties": {
                                    "character": {
                                      "type": "string"
                                    },
                                    "confirmed_gross_principal": {
                                      "properties": {
                                        "asset": {
                                          "type": "string"
                                        },
                                        "scale": {
                                          "type": "integer"
                                        },
                                        "units": {
                                          "anyOf": [
                                            {
                                              "description": "Exact decimal integer units.",
                                              "pattern": "^-?[0-9]+$",
                                              "type": "string"
                                            },
                                            {
                                              "type": "null"
                                            }
                                          ]
                                        }
                                      },
                                      "type": "object"
                                    },
                                    "confirmed_recipient_principal": {
                                      "properties": {
                                        "asset": {
                                          "type": "string"
                                        },
                                        "scale": {
                                          "type": "integer"
                                        },
                                        "units": {
                                          "anyOf": [
                                            {
                                              "description": "Exact decimal integer units.",
                                              "pattern": "^-?[0-9]+$",
                                              "type": "string"
                                            },
                                            {
                                              "type": "null"
                                            }
                                          ]
                                        }
                                      },
                                      "type": "object"
                                    },
                                    "confirmed_tax_payment": {
                                      "properties": {
                                        "asset": {
                                          "type": "string"
                                        },
                                        "scale": {
                                          "type": "integer"
                                        },
                                        "units": {
                                          "anyOf": [
                                            {
                                              "description": "Exact decimal integer units.",
                                              "pattern": "^-?[0-9]+$",
                                              "type": "string"
                                            },
                                            {
                                              "type": "null"
                                            }
                                          ]
                                        }
                                      },
                                      "type": "object"
                                    },
                                    "effective_set_off": {
                                      "type": "integer"
                                    },
                                    "obligation_id": {
                                      "type": "string"
                                    },
                                    "original": {
                                      "properties": {
                                        "asset": {
                                          "type": "string"
                                        },
                                        "scale": {
                                          "type": "integer"
                                        },
                                        "units": {
                                          "anyOf": [
                                            {
                                              "description": "Exact decimal integer units.",
                                              "pattern": "^-?[0-9]+$",
                                              "type": "string"
                                            },
                                            {
                                              "type": "null"
                                            }
                                          ]
                                        }
                                      },
                                      "type": "object"
                                    }
                                  },
                                  "type": "object"
                                },
                                "type": "array"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "type": "object"
                      },
                      "type": "array"
                    },
                    {
                      "type": "null"
                    }
                  ]
                }
              },
              "type": "object"
            }
          },
          "type": "object"
        }
      }
    },
    "description": "Successful response. Get a historical close report."
  },
  "400": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Invalid request, malformed identifier, or unmet input requirement."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  },
  "404": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Resource not found in the caller scope."
  },
  "409": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "State conflict; inspect the error before retrying."
  }
}
curl --fail-with-body -sS "$FRAME_URL/v1/treasury/close-report?group_id=${FRAME_GROUP_ID}" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT"

GET /v1/treasury/groups

List treasury report groups

Bank session · read capability

Returns a JSON array of configured group IDs for the selected tenant. Select a group_id for the report, close report and evidence endpoints.

Parameters

NameTypeDescription
tenantquery · stringOptional explicit tenant UUID; membership checked. Defaults to active tenant.
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.
Responses
{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      }
    },
    "description": "Successful response. List treasury report groups."
  },
  "400": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Invalid request, malformed identifier, or unmet input requirement."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  },
  "500": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Internal failure."
  }
}
curl --fail-with-body -sS "$FRAME_URL/v1/treasury/groups" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT"

GET /v1/treasury/pack

Download treasury verification evidence

Bank session · read capability

Returns CBOR evidence for the group, including execution evidence where required. Returns 404 if no treasury evidence exists, and 409 when the evidence cannot be reconstructed or verified.

Parameters

NameTypeDescription
tenantquery · stringOptional explicit tenant UUID; membership checked. Defaults to active tenant.
group_id
required
query · stringConfigured treasury group identifier. Discover with GET /v1/treasury/groups.
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.
Responses
{
  "200": {
    "content": {
      "application/cbor": {
        "schema": {
          "description": "Binary Frame verify-pack. Save the bytes; do not JSON-decode.",
          "format": "binary",
          "type": "string"
        }
      }
    },
    "description": "Successful response. Download treasury verification evidence."
  },
  "400": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Invalid request, malformed identifier, or unmet input requirement."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  },
  "404": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Resource not found in the caller scope."
  },
  "409": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "State conflict; inspect the error before retrying."
  }
}
curl --fail-with-body -sS "$FRAME_URL/v1/treasury/pack?group_id=${FRAME_GROUP_ID}" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT" --output evidence.cbor

GET /v1/treasury/report

Query a treasury report or CSV export

Bank session · read capability

Verifies source evidence before replaying the requested checkpoint. JSON returns report, journal, journal_date_basis and withholding_reviews without a success/data envelope. Journal dates use the agreement timezone. csv selects a downloadable report. as_of must be in the past; it is not a date-only filter.

Parameters

NameTypeDescription
tenantquery · stringOptional explicit tenant UUID; membership checked. Defaults to active tenant.
group_id
required
query · stringConfigured treasury group identifier. Discover with GET /v1/treasury/groups.
as_ofquery · stringPast RFC3339 timestamp; defaults to now.
fromquery · stringInclusive YYYY-MM-DD report window start.
toquery · stringInclusive YYYY-MM-DD report window end.
entityquery · stringFilter by entity identifier.
characterquery · stringExact payment character.
dispositionquery · stringExact disposition.
idquery · stringObligation identifier.
cycle_idquery · stringCycle identifier.
uncharacterisedquery · stringUse 1 to include only obligations missing character.
csvquery · stringCSV report kind; omit for JSON.
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.
Responses
{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "properties": {
            "journal": {
              "items": {
                "properties": {
                  "accounting_date": {
                    "type": "string"
                  },
                  "amount": {
                    "properties": {
                      "asset": {
                        "type": "string"
                      },
                      "scale": {
                        "type": "integer"
                      },
                      "units": {
                        "anyOf": [
                          {
                            "description": "Exact decimal integer units.",
                            "pattern": "^-?[0-9]+$",
                            "type": "string"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      }
                    },
                    "type": "object"
                  },
                  "bank_reference": {
                    "type": "string"
                  },
                  "basis": {
                    "type": "string"
                  },
                  "command_id": {
                    "type": "string"
                  },
                  "credit_account": {
                    "type": "string"
                  },
                  "credit_role": {
                    "type": "string"
                  },
                  "cycle_id": {
                    "type": "string"
                  },
                  "debit_account": {
                    "type": "string"
                  },
                  "debit_role": {
                    "type": "string"
                  },
                  "effective_at": {
                    "type": "integer"
                  },
                  "mapping_version": {
                    "type": "integer"
                  },
                  "obligation_id": {
                    "type": "string"
                  },
                  "party": {
                    "type": "string"
                  },
                  "payment_id": {
                    "type": "string"
                  },
                  "recorded_at": {
                    "type": "integer"
                  },
                  "source_ref": {
                    "type": "string"
                  },
                  "value_date": {
                    "type": "string"
                  },
                  "withholding_settlement_id": {
                    "type": "string"
                  }
                },
                "type": "object"
              },
              "type": "array"
            },
            "journal_date_basis": {
              "type": "string"
            },
            "report": {
              "properties": {
                "appearances": {
                  "anyOf": [
                    {
                      "items": {
                        "properties": {
                          "creditor_jurisdiction": {
                            "type": "string"
                          },
                          "cycle_id": {
                            "type": "string"
                          },
                          "debtor_jurisdiction": {
                            "type": "string"
                          },
                          "disposition": {
                            "type": "string"
                          },
                          "effective_set_off": {
                            "type": "integer"
                          },
                          "missing_character": {
                            "type": "boolean"
                          },
                          "obligation": {
                            "properties": {
                              "correction_reason": {
                                "type": "string"
                              },
                              "correction_ref": {
                                "type": "string"
                              },
                              "credit_note_for": {
                                "type": "string"
                              },
                              "due_date": {
                                "type": "string"
                              },
                              "external_payee_ref": {
                                "type": "string"
                              },
                              "first_seen": {
                                "type": "integer"
                              },
                              "invoice_date": {
                                "type": "string"
                              },
                              "leg": {
                                "properties": {
                                  "amount": {
                                    "properties": {
                                      "asset": {
                                        "type": "string"
                                      },
                                      "scale": {
                                        "type": "integer"
                                      },
                                      "units": {
                                        "anyOf": [
                                          {
                                            "description": "Exact decimal integer units.",
                                            "pattern": "^-?[0-9]+$",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      }
                                    },
                                    "type": "object"
                                  },
                                  "creditor": {
                                    "type": "string"
                                  },
                                  "debtor": {
                                    "type": "string"
                                  },
                                  "id": {
                                    "type": "string"
                                  },
                                  "priority": {
                                    "type": "integer"
                                  },
                                  "tax": {
                                    "anyOf": [
                                      {
                                        "properties": {
                                          "character": {
                                            "type": "string"
                                          },
                                          "character_ref": {
                                            "type": "string"
                                          },
                                          "character_src": {
                                            "type": "string"
                                          },
                                          "invoice_ref": {
                                            "type": "string"
                                          }
                                        },
                                        "type": "object"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  }
                                },
                                "type": "object"
                              },
                              "revision": {
                                "type": "integer"
                              },
                              "source": {
                                "type": "string"
                              },
                              "source_id": {
                                "type": "string"
                              }
                            },
                            "type": "object"
                          },
                          "policy_hash": {
                            "description": "Hex-encoded bytes.",
                            "pattern": "^[0-9a-f]*$",
                            "type": "string"
                          },
                          "policy_source": {
                            "type": "string"
                          },
                          "policy_version": {
                            "type": "integer"
                          },
                          "rule": {
                            "type": "integer"
                          }
                        },
                        "type": "object"
                      },
                      "type": "array"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "coverage": {
                  "anyOf": [
                    {
                      "items": {
                        "properties": {
                          "amount": {
                            "properties": {
                              "asset": {
                                "type": "string"
                              },
                              "scale": {
                                "type": "integer"
                              },
                              "units": {
                                "anyOf": [
                                  {
                                    "description": "Exact decimal integer units.",
                                    "pattern": "^-?[0-9]+$",
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              }
                            },
                            "type": "object"
                          },
                          "character": {
                            "type": "string"
                          },
                          "count": {
                            "type": "integer"
                          },
                          "credit": {
                            "type": "boolean"
                          },
                          "creditor_jurisdiction": {
                            "type": "string"
                          },
                          "debtor_jurisdiction": {
                            "type": "string"
                          },
                          "disposition": {
                            "type": "string"
                          },
                          "source": {
                            "type": "string"
                          }
                        },
                        "type": "object"
                      },
                      "type": "array"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "cycles": {
                  "anyOf": [
                    {
                      "items": {
                        "properties": {
                          "accepted_rates": {
                            "anyOf": [
                              {
                                "items": {
                                  "properties": {
                                    "base": {
                                      "type": "string"
                                    },
                                    "contributors": {
                                      "anyOf": [
                                        {
                                          "items": {
                                            "type": "integer"
                                          },
                                          "type": "array"
                                        },
                                        {
                                          "type": "null"
                                        }
                                      ]
                                    },
                                    "quote": {
                                      "type": "string"
                                    },
                                    "rate": {
                                      "properties": {
                                        "scale": {
                                          "type": "integer"
                                        },
                                        "units": {
                                          "anyOf": [
                                            {
                                              "description": "Exact decimal integer units.",
                                              "pattern": "^-?[0-9]+$",
                                              "type": "string"
                                            },
                                            {
                                              "type": "null"
                                            }
                                          ]
                                        }
                                      },
                                      "type": "object"
                                    }
                                  },
                                  "type": "object"
                                },
                                "type": "array"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "balances": {
                            "anyOf": [
                              {
                                "items": {
                                  "properties": {
                                    "asset": {
                                      "type": "string"
                                    },
                                    "closing": {
                                      "anyOf": [
                                        {
                                          "description": "Exact decimal integer units.",
                                          "pattern": "^-?[0-9]+$",
                                          "type": "string"
                                        },
                                        {
                                          "type": "null"
                                        }
                                      ]
                                    },
                                    "net": {
                                      "anyOf": [
                                        {
                                          "description": "Exact decimal integer units.",
                                          "pattern": "^-?[0-9]+$",
                                          "type": "string"
                                        },
                                        {
                                          "type": "null"
                                        }
                                      ]
                                    },
                                    "opening": {
                                      "anyOf": [
                                        {
                                          "description": "Exact decimal integer units.",
                                          "pattern": "^-?[0-9]+$",
                                          "type": "string"
                                        },
                                        {
                                          "type": "null"
                                        }
                                      ]
                                    },
                                    "party": {
                                      "type": "string"
                                    },
                                    "scale": {
                                      "type": "integer"
                                    }
                                  },
                                  "type": "object"
                                },
                                "type": "array"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "blocked": {
                            "anyOf": [
                              {
                                "items": {
                                  "properties": {
                                    "amount": {
                                      "properties": {
                                        "asset": {
                                          "type": "string"
                                        },
                                        "scale": {
                                          "type": "integer"
                                        },
                                        "units": {
                                          "anyOf": [
                                            {
                                              "description": "Exact decimal integer units.",
                                              "pattern": "^-?[0-9]+$",
                                              "type": "string"
                                            },
                                            {
                                              "type": "null"
                                            }
                                          ]
                                        }
                                      },
                                      "type": "object"
                                    },
                                    "creditor": {
                                      "type": "string"
                                    },
                                    "debtor": {
                                      "type": "string"
                                    },
                                    "id": {
                                      "type": "string"
                                    },
                                    "priority": {
                                      "type": "integer"
                                    },
                                    "tax": {
                                      "anyOf": [
                                        {
                                          "properties": {
                                            "character": {
                                              "type": "string"
                                            },
                                            "character_ref": {
                                              "type": "string"
                                            },
                                            "character_src": {
                                              "type": "string"
                                            },
                                            "invoice_ref": {
                                              "type": "string"
                                            }
                                          },
                                          "type": "object"
                                        },
                                        {
                                          "type": "null"
                                        }
                                      ]
                                    }
                                  },
                                  "type": "object"
                                },
                                "type": "array"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "checks": {
                            "anyOf": [
                              {
                                "items": {
                                  "properties": {
                                    "detail": {
                                      "type": "string"
                                    },
                                    "label": {
                                      "type": "string"
                                    },
                                    "passed": {
                                      "type": "boolean"
                                    }
                                  },
                                  "type": "object"
                                },
                                "type": "array"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "conversions": {
                            "anyOf": [
                              {
                                "items": {
                                  "properties": {
                                    "from": {
                                      "properties": {
                                        "asset": {
                                          "type": "string"
                                        },
                                        "scale": {
                                          "type": "integer"
                                        },
                                        "units": {
                                          "anyOf": [
                                            {
                                              "description": "Exact decimal integer units.",
                                              "pattern": "^-?[0-9]+$",
                                              "type": "string"
                                            },
                                            {
                                              "type": "null"
                                            }
                                          ]
                                        }
                                      },
                                      "type": "object"
                                    },
                                    "obligation_id": {
                                      "type": "string"
                                    },
                                    "rate_index": {
                                      "type": "integer"
                                    },
                                    "to": {
                                      "properties": {
                                        "asset": {
                                          "type": "string"
                                        },
                                        "scale": {
                                          "type": "integer"
                                        },
                                        "units": {
                                          "anyOf": [
                                            {
                                              "description": "Exact decimal integer units.",
                                              "pattern": "^-?[0-9]+$",
                                              "type": "string"
                                            },
                                            {
                                              "type": "null"
                                            }
                                          ]
                                        }
                                      },
                                      "type": "object"
                                    }
                                  },
                                  "type": "object"
                                },
                                "type": "array"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "converted_opening": {
                            "anyOf": [
                              {
                                "items": {
                                  "properties": {
                                    "amount": {
                                      "properties": {
                                        "asset": {
                                          "type": "string"
                                        },
                                        "scale": {
                                          "type": "integer"
                                        },
                                        "units": {
                                          "anyOf": [
                                            {
                                              "description": "Exact decimal integer units.",
                                              "pattern": "^-?[0-9]+$",
                                              "type": "string"
                                            },
                                            {
                                              "type": "null"
                                            }
                                          ]
                                        }
                                      },
                                      "type": "object"
                                    },
                                    "party": {
                                      "type": "string"
                                    }
                                  },
                                  "type": "object"
                                },
                                "type": "array"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "cycle_id": {
                            "type": "string"
                          },
                          "deferred": {
                            "anyOf": [
                              {
                                "items": {
                                  "properties": {
                                    "amount": {
                                      "properties": {
                                        "asset": {
                                          "type": "string"
                                        },
                                        "scale": {
                                          "type": "integer"
                                        },
                                        "units": {
                                          "anyOf": [
                                            {
                                              "description": "Exact decimal integer units.",
                                              "pattern": "^-?[0-9]+$",
                                              "type": "string"
                                            },
                                            {
                                              "type": "null"
                                            }
                                          ]
                                        }
                                      },
                                      "type": "object"
                                    },
                                    "creditor": {
                                      "type": "string"
                                    },
                                    "debtor": {
                                      "type": "string"
                                    },
                                    "id": {
                                      "type": "string"
                                    },
                                    "priority": {
                                      "type": "integer"
                                    },
                                    "tax": {
                                      "anyOf": [
                                        {
                                          "properties": {
                                            "character": {
                                              "type": "string"
                                            },
                                            "character_ref": {
                                              "type": "string"
                                            },
                                            "character_src": {
                                              "type": "string"
                                            },
                                            "invoice_ref": {
                                              "type": "string"
                                            }
                                          },
                                          "type": "object"
                                        },
                                        {
                                          "type": "null"
                                        }
                                      ]
                                    }
                                  },
                                  "type": "object"
                                },
                                "type": "array"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "deferred_cnt": {
                            "type": "integer"
                          },
                          "exact": {
                            "type": "boolean"
                          },
                          "group_id": {
                            "type": "string"
                          },
                          "jurisdiction": {
                            "type": "string"
                          },
                          "legal_basis": {
                            "type": "string"
                          },
                          "members": {
                            "anyOf": [
                              {
                                "items": {
                                  "properties": {
                                    "currencies": {
                                      "anyOf": [
                                        {
                                          "items": {
                                            "type": "string"
                                          },
                                          "type": "array"
                                        },
                                        {
                                          "type": "null"
                                        }
                                      ]
                                    },
                                    "lei": {
                                      "type": "string"
                                    },
                                    "party": {
                                      "type": "string"
                                    },
                                    "tax_id": {
                                      "type": "string"
                                    },
                                    "tax_jurisdiction": {
                                      "type": "string"
                                    }
                                  },
                                  "type": "object"
                                },
                                "type": "array"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "method": {
                            "type": "string"
                          },
                          "netting_agreement_ref": {
                            "type": "string"
                          },
                          "obligations": {
                            "anyOf": [
                              {
                                "items": {
                                  "properties": {
                                    "amount": {
                                      "properties": {
                                        "asset": {
                                          "type": "string"
                                        },
                                        "scale": {
                                          "type": "integer"
                                        },
                                        "units": {
                                          "anyOf": [
                                            {
                                              "description": "Exact decimal integer units.",
                                              "pattern": "^-?[0-9]+$",
                                              "type": "string"
                                            },
                                            {
                                              "type": "null"
                                            }
                                          ]
                                        }
                                      },
                                      "type": "object"
                                    },
                                    "creditor": {
                                      "type": "string"
                                    },
                                    "debtor": {
                                      "type": "string"
                                    },
                                    "id": {
                                      "type": "string"
                                    },
                                    "priority": {
                                      "type": "integer"
                                    },
                                    "tax": {
                                      "anyOf": [
                                        {
                                          "properties": {
                                            "character": {
                                              "type": "string"
                                            },
                                            "character_ref": {
                                              "type": "string"
                                            },
                                            "character_src": {
                                              "type": "string"
                                            },
                                            "invoice_ref": {
                                              "type": "string"
                                            }
                                          },
                                          "type": "object"
                                        },
                                        {
                                          "type": "null"
                                        }
                                      ]
                                    }
                                  },
                                  "type": "object"
                                },
                                "type": "array"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "opening": {
                            "anyOf": [
                              {
                                "items": {
                                  "properties": {
                                    "amount": {
                                      "properties": {
                                        "asset": {
                                          "type": "string"
                                        },
                                        "scale": {
                                          "type": "integer"
                                        },
                                        "units": {
                                          "anyOf": [
                                            {
                                              "description": "Exact decimal integer units.",
                                              "pattern": "^-?[0-9]+$",
                                              "type": "string"
                                            },
                                            {
                                              "type": "null"
                                            }
                                          ]
                                        }
                                      },
                                      "type": "object"
                                    },
                                    "party": {
                                      "type": "string"
                                    }
                                  },
                                  "type": "object"
                                },
                                "type": "array"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "positions": {
                            "anyOf": [
                              {
                                "items": {
                                  "properties": {
                                    "asset": {
                                      "type": "string"
                                    },
                                    "party": {
                                      "type": "string"
                                    },
                                    "scale": {
                                      "type": "integer"
                                    },
                                    "units": {
                                      "anyOf": [
                                        {
                                          "description": "Exact decimal integer units.",
                                          "pattern": "^-?[0-9]+$",
                                          "type": "string"
                                        },
                                        {
                                          "type": "null"
                                        }
                                      ]
                                    }
                                  },
                                  "type": "object"
                                },
                                "type": "array"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "prev_cycle_leaf_ref": {
                            "anyOf": [
                              {
                                "description": "Hex-encoded bytes.",
                                "pattern": "^[0-9a-f]*$",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "rate_policy": {
                            "anyOf": [
                              {
                                "properties": {
                                  "aggregation": {
                                    "type": "string"
                                  },
                                  "author": {
                                    "type": "string"
                                  },
                                  "band_bps": {
                                    "type": "integer"
                                  },
                                  "convert_currencies": {
                                    "anyOf": [
                                      {
                                        "items": {
                                          "type": "string"
                                        },
                                        "type": "array"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "fx_bearer": {
                                    "type": "string"
                                  },
                                  "group_id": {
                                    "type": "string"
                                  },
                                  "k": {
                                    "type": "integer"
                                  },
                                  "sources": {
                                    "anyOf": [
                                      {
                                        "items": {
                                          "type": "string"
                                        },
                                        "type": "array"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "target_asset": {
                                    "type": "string"
                                  },
                                  "target_scale": {
                                    "type": "integer"
                                  },
                                  "version": {
                                    "type": "integer"
                                  },
                                  "window_ms": {
                                    "type": "integer"
                                  }
                                },
                                "type": "object"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "rate_set": {
                            "anyOf": [
                              {
                                "items": {
                                  "properties": {
                                    "rate_assertion_body": {
                                      "properties": {
                                        "as_of": {
                                          "type": "integer"
                                        },
                                        "base": {
                                          "type": "string"
                                        },
                                        "quote": {
                                          "type": "string"
                                        },
                                        "rate": {
                                          "properties": {
                                            "scale": {
                                              "type": "integer"
                                            },
                                            "units": {
                                              "anyOf": [
                                                {
                                                  "description": "Exact decimal integer units.",
                                                  "pattern": "^-?[0-9]+$",
                                                  "type": "string"
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            }
                                          },
                                          "type": "object"
                                        },
                                        "rate_source": {
                                          "type": "string"
                                        }
                                      },
                                      "type": "object"
                                    },
                                    "sig": {
                                      "description": "Hex-encoded bytes.",
                                      "pattern": "^[0-9a-f]*$",
                                      "type": "string"
                                    }
                                  },
                                  "type": "object"
                                },
                                "type": "array"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "request_hash": {
                            "description": "Hex-encoded bytes.",
                            "pattern": "^[0-9a-f]*$",
                            "type": "string"
                          },
                          "residuals": {
                            "anyOf": [
                              {
                                "items": {
                                  "properties": {
                                    "carried": {
                                      "anyOf": [
                                        {
                                          "description": "Exact decimal integer units.",
                                          "pattern": "^-?[0-9]+$",
                                          "type": "string"
                                        },
                                        {
                                          "type": "null"
                                        }
                                      ]
                                    },
                                    "currency": {
                                      "type": "string"
                                    },
                                    "cycle": {
                                      "anyOf": [
                                        {
                                          "description": "Exact decimal integer units.",
                                          "pattern": "^-?[0-9]+$",
                                          "type": "string"
                                        },
                                        {
                                          "type": "null"
                                        }
                                      ]
                                    },
                                    "scale": {
                                      "type": "integer"
                                    },
                                    "target_asset": {
                                      "type": "string"
                                    }
                                  },
                                  "type": "object"
                                },
                                "type": "array"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "resolved_at": {
                            "type": "integer"
                          },
                          "routed_gross": {
                            "anyOf": [
                              {
                                "items": {
                                  "properties": {
                                    "amount": {
                                      "properties": {
                                        "asset": {
                                          "type": "string"
                                        },
                                        "scale": {
                                          "type": "integer"
                                        },
                                        "units": {
                                          "anyOf": [
                                            {
                                              "description": "Exact decimal integer units.",
                                              "pattern": "^-?[0-9]+$",
                                              "type": "string"
                                            },
                                            {
                                              "type": "null"
                                            }
                                          ]
                                        }
                                      },
                                      "type": "object"
                                    },
                                    "creditor": {
                                      "type": "string"
                                    },
                                    "debtor": {
                                      "type": "string"
                                    },
                                    "id": {
                                      "type": "string"
                                    },
                                    "priority": {
                                      "type": "integer"
                                    },
                                    "tax": {
                                      "anyOf": [
                                        {
                                          "properties": {
                                            "character": {
                                              "type": "string"
                                            },
                                            "character_ref": {
                                              "type": "string"
                                            },
                                            "character_src": {
                                              "type": "string"
                                            },
                                            "invoice_ref": {
                                              "type": "string"
                                            }
                                          },
                                          "type": "object"
                                        },
                                        {
                                          "type": "null"
                                        }
                                      ]
                                    }
                                  },
                                  "type": "object"
                                },
                                "type": "array"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "savings": {
                            "anyOf": [
                              {
                                "items": {
                                  "properties": {
                                    "asset": {
                                      "type": "string"
                                    },
                                    "gross": {
                                      "anyOf": [
                                        {
                                          "description": "Exact decimal integer units.",
                                          "pattern": "^-?[0-9]+$",
                                          "type": "string"
                                        },
                                        {
                                          "type": "null"
                                        }
                                      ]
                                    },
                                    "net_funding": {
                                      "anyOf": [
                                        {
                                          "description": "Exact decimal integer units.",
                                          "pattern": "^-?[0-9]+$",
                                          "type": "string"
                                        },
                                        {
                                          "type": "null"
                                        }
                                      ]
                                    },
                                    "scale": {
                                      "type": "integer"
                                    }
                                  },
                                  "type": "object"
                                },
                                "type": "array"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "settled": {
                            "anyOf": [
                              {
                                "items": {
                                  "properties": {
                                    "amount": {
                                      "properties": {
                                        "asset": {
                                          "type": "string"
                                        },
                                        "scale": {
                                          "type": "integer"
                                        },
                                        "units": {
                                          "anyOf": [
                                            {
                                              "description": "Exact decimal integer units.",
                                              "pattern": "^-?[0-9]+$",
                                              "type": "string"
                                            },
                                            {
                                              "type": "null"
                                            }
                                          ]
                                        }
                                      },
                                      "type": "object"
                                    },
                                    "creditor": {
                                      "type": "string"
                                    },
                                    "debtor": {
                                      "type": "string"
                                    },
                                    "id": {
                                      "type": "string"
                                    },
                                    "priority": {
                                      "type": "integer"
                                    },
                                    "tax": {
                                      "anyOf": [
                                        {
                                          "properties": {
                                            "character": {
                                              "type": "string"
                                            },
                                            "character_ref": {
                                              "type": "string"
                                            },
                                            "character_src": {
                                              "type": "string"
                                            },
                                            "invoice_ref": {
                                              "type": "string"
                                            }
                                          },
                                          "type": "object"
                                        },
                                        {
                                          "type": "null"
                                        }
                                      ]
                                    }
                                  },
                                  "type": "object"
                                },
                                "type": "array"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "settled_cnt": {
                            "type": "integer"
                          },
                          "tax_policy": {
                            "anyOf": [
                              {
                                "properties": {
                                  "author": {
                                    "type": "string"
                                  },
                                  "default": {
                                    "type": "string"
                                  },
                                  "group_id": {
                                    "type": "string"
                                  },
                                  "rules": {
                                    "anyOf": [
                                      {
                                        "items": {
                                          "properties": {
                                            "character": {
                                              "type": "string"
                                            },
                                            "creditor_jur": {
                                              "type": "string"
                                            },
                                            "debtor_jur": {
                                              "type": "string"
                                            },
                                            "disposition": {
                                              "type": "string"
                                            }
                                          },
                                          "type": "object"
                                        },
                                        "type": "array"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "version": {
                                    "type": "integer"
                                  }
                                },
                                "type": "object"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "treasury": {
                            "anyOf": [
                              {
                                "properties": {
                                  "dispositions": {
                                    "anyOf": [
                                      {
                                        "items": {
                                          "properties": {
                                            "disposition": {
                                              "type": "string"
                                            },
                                            "id": {
                                              "type": "string"
                                            },
                                            "limits": {
                                              "anyOf": [
                                                {
                                                  "items": {
                                                    "type": "integer"
                                                  },
                                                  "type": "array"
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "revision": {
                                              "type": "integer"
                                            },
                                            "rule": {
                                              "type": "integer"
                                            }
                                          },
                                          "type": "object"
                                        },
                                        "type": "array"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "input": {
                                    "properties": {
                                      "agreement": {
                                        "properties": {
                                          "allow_early": {
                                            "type": "boolean"
                                          },
                                          "author": {
                                            "type": "string"
                                          },
                                          "calendar": {
                                            "anyOf": [
                                              {
                                                "properties": {
                                                  "cutoff_time": {
                                                    "type": "string"
                                                  },
                                                  "holidays": {
                                                    "anyOf": [
                                                      {
                                                        "items": {
                                                          "type": "string"
                                                        },
                                                        "type": "array"
                                                      },
                                                      {
                                                        "type": "null"
                                                      }
                                                    ]
                                                  },
                                                  "run_time": {
                                                    "type": "string"
                                                  },
                                                  "source_ref": {
                                                    "type": "string"
                                                  },
                                                  "weekdays": {
                                                    "description": "Hex-encoded bytes.",
                                                    "pattern": "^[0-9a-f]*$",
                                                    "type": "string"
                                                  }
                                                },
                                                "type": "object"
                                              },
                                              {
                                                "type": "null"
                                              }
                                            ]
                                          },
                                          "group_id": {
                                            "type": "string"
                                          },
                                          "mode": {
                                            "type": "string"
                                          },
                                          "rate_policy": {
                                            "anyOf": [
                                              {
                                                "properties": {
                                                  "aggregation": {
                                                    "type": "string"
                                                  },
                                                  "author": {
                                                    "type": "string"
                                                  },
                                                  "band_bps": {
                                                    "type": "integer"
                                                  },
                                                  "convert_currencies": {
                                                    "anyOf": [
                                                      {
                                                        "items": {
                                                          "type": "string"
                                                        },
                                                        "type": "array"
                                                      },
                                                      {
                                                        "type": "null"
                                                      }
                                                    ]
                                                  },
                                                  "fx_bearer": {
                                                    "type": "string"
                                                  },
                                                  "group_id": {
                                                    "type": "string"
                                                  },
                                                  "k": {
                                                    "type": "integer"
                                                  },
                                                  "sources": {
                                                    "anyOf": [
                                                      {
                                                        "items": {
                                                          "type": "string"
                                                        },
                                                        "type": "array"
                                                      },
                                                      {
                                                        "type": "null"
                                                      }
                                                    ]
                                                  },
                                                  "target_asset": {
                                                    "type": "string"
                                                  },
                                                  "target_scale": {
                                                    "type": "integer"
                                                  },
                                                  "version": {
                                                    "type": "integer"
                                                  },
                                                  "window_ms": {
                                                    "type": "integer"
                                                  }
                                                },
                                                "type": "object"
                                              },
                                              {
                                                "type": "null"
                                              }
                                            ]
                                          },
                                          "rate_sources": {
                                            "anyOf": [
                                              {
                                                "items": {
                                                  "properties": {
                                                    "id": {
                                                      "type": "string"
                                                    },
                                                    "public_key": {
                                                      "description": "Hex-encoded bytes.",
                                                      "pattern": "^[0-9a-f]*$",
                                                      "type": "string"
                                                    },
                                                    "source_ref": {
                                                      "type": "string"
                                                    }
                                                  },
                                                  "type": "object"
                                                },
                                                "type": "array"
                                              },
                                              {
                                                "type": "null"
                                              }
                                            ]
                                          },
                                          "reference": {
                                            "type": "string"
                                          },
                                          "timezone": {
                                            "type": "string"
                                          },
                                          "version": {
                                            "type": "integer"
                                          }
                                        },
                                        "type": "object"
                                      },
                                      "candidates": {
                                        "anyOf": [
                                          {
                                            "items": {
                                              "properties": {
                                                "correction_reason": {
                                                  "type": "string"
                                                },
                                                "correction_ref": {
                                                  "type": "string"
                                                },
                                                "credit_note_for": {
                                                  "type": "string"
                                                },
                                                "due_date": {
                                                  "type": "string"
                                                },
                                                "external_payee_ref": {
                                                  "type": "string"
                                                },
                                                "first_seen": {
                                                  "type": "integer"
                                                },
                                                "invoice_date": {
                                                  "type": "string"
                                                },
                                                "leg": {
                                                  "properties": {
                                                    "amount": {
                                                      "properties": {
                                                        "asset": {
                                                          "type": "string"
                                                        },
                                                        "scale": {
                                                          "type": "integer"
                                                        },
                                                        "units": {
                                                          "anyOf": [
                                                            {
                                                              "description": "Exact decimal integer units.",
                                                              "pattern": "^-?[0-9]+$",
                                                              "type": "string"
                                                            },
                                                            {
                                                              "type": "null"
                                                            }
                                                          ]
                                                        }
                                                      },
                                                      "type": "object"
                                                    },
                                                    "creditor": {
                                                      "type": "string"
                                                    },
                                                    "debtor": {
                                                      "type": "string"
                                                    },
                                                    "id": {
                                                      "type": "string"
                                                    },
                                                    "priority": {
                                                      "type": "integer"
                                                    },
                                                    "tax": {
                                                      "anyOf": [
                                                        {
                                                          "properties": {
                                                            "character": {
                                                              "type": "string"
                                                            },
                                                            "character_ref": {
                                                              "type": "string"
                                                            },
                                                            "character_src": {
                                                              "type": "string"
                                                            },
                                                            "invoice_ref": {
                                                              "type": "string"
                                                            }
                                                          },
                                                          "type": "object"
                                                        },
                                                        {
                                                          "type": "null"
                                                        }
                                                      ]
                                                    }
                                                  },
                                                  "type": "object"
                                                },
                                                "revision": {
                                                  "type": "integer"
                                                },
                                                "source": {
                                                  "type": "string"
                                                },
                                                "source_id": {
                                                  "type": "string"
                                                }
                                              },
                                              "type": "object"
                                            },
                                            "type": "array"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "cutoff_override_ref": {
                                        "type": "string"
                                      },
                                      "cycle_id": {
                                        "type": "string"
                                      },
                                      "evaluated_at": {
                                        "type": "integer"
                                      },
                                      "funding_as_of": {
                                        "type": "integer"
                                      },
                                      "funding_ref": {
                                        "type": "string"
                                      },
                                      "limits": {
                                        "anyOf": [
                                          {
                                            "properties": {
                                              "author": {
                                                "type": "string"
                                              },
                                              "rules": {
                                                "anyOf": [
                                                  {
                                                    "items": {
                                                      "properties": {
                                                        "ceiling": {
                                                          "properties": {
                                                            "asset": {
                                                              "type": "string"
                                                            },
                                                            "scale": {
                                                              "type": "integer"
                                                            },
                                                            "units": {
                                                              "anyOf": [
                                                                {
                                                                  "description": "Exact decimal integer units.",
                                                                  "pattern": "^-?[0-9]+$",
                                                                  "type": "string"
                                                                },
                                                                {
                                                                  "type": "null"
                                                                }
                                                              ]
                                                            }
                                                          },
                                                          "type": "object"
                                                        },
                                                        "on_breach": {
                                                          "type": "string"
                                                        },
                                                        "party_a": {
                                                          "type": "string"
                                                        },
                                                        "party_b": {
                                                          "type": "string"
                                                        },
                                                        "scope": {
                                                          "type": "string"
                                                        }
                                                      },
                                                      "type": "object"
                                                    },
                                                    "type": "array"
                                                  },
                                                  {
                                                    "type": "null"
                                                  }
                                                ]
                                              },
                                              "source_ref": {
                                                "type": "string"
                                              },
                                              "version": {
                                                "type": "integer"
                                              }
                                            },
                                            "type": "object"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "members": {
                                        "anyOf": [
                                          {
                                            "items": {
                                              "properties": {
                                                "currencies": {
                                                  "anyOf": [
                                                    {
                                                      "items": {
                                                        "type": "string"
                                                      },
                                                      "type": "array"
                                                    },
                                                    {
                                                      "type": "null"
                                                    }
                                                  ]
                                                },
                                                "lei": {
                                                  "type": "string"
                                                },
                                                "party": {
                                                  "type": "string"
                                                },
                                                "tax_id": {
                                                  "type": "string"
                                                },
                                                "tax_jurisdiction": {
                                                  "type": "string"
                                                }
                                              },
                                              "type": "object"
                                            },
                                            "type": "array"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "opening": {
                                        "anyOf": [
                                          {
                                            "items": {
                                              "properties": {
                                                "amount": {
                                                  "properties": {
                                                    "asset": {
                                                      "type": "string"
                                                    },
                                                    "scale": {
                                                      "type": "integer"
                                                    },
                                                    "units": {
                                                      "anyOf": [
                                                        {
                                                          "description": "Exact decimal integer units.",
                                                          "pattern": "^-?[0-9]+$",
                                                          "type": "string"
                                                        },
                                                        {
                                                          "type": "null"
                                                        }
                                                      ]
                                                    }
                                                  },
                                                  "type": "object"
                                                },
                                                "party": {
                                                  "type": "string"
                                                }
                                              },
                                              "type": "object"
                                            },
                                            "type": "array"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "outstanding_checkpoint": {
                                        "description": "Hex-encoded bytes.",
                                        "pattern": "^[0-9a-f]*$",
                                        "type": "string"
                                      },
                                      "prior_residuals": {
                                        "anyOf": [
                                          {
                                            "items": {
                                              "properties": {
                                                "carried": {
                                                  "anyOf": [
                                                    {
                                                      "description": "Exact decimal integer units.",
                                                      "pattern": "^-?[0-9]+$",
                                                      "type": "string"
                                                    },
                                                    {
                                                      "type": "null"
                                                    }
                                                  ]
                                                },
                                                "currency": {
                                                  "type": "string"
                                                },
                                                "cycle": {
                                                  "anyOf": [
                                                    {
                                                      "description": "Exact decimal integer units.",
                                                      "pattern": "^-?[0-9]+$",
                                                      "type": "string"
                                                    },
                                                    {
                                                      "type": "null"
                                                    }
                                                  ]
                                                },
                                                "scale": {
                                                  "type": "integer"
                                                },
                                                "target_asset": {
                                                  "type": "string"
                                                }
                                              },
                                              "type": "object"
                                            },
                                            "type": "array"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "rates": {
                                        "anyOf": [
                                          {
                                            "items": {
                                              "properties": {
                                                "rate_assertion_body": {
                                                  "properties": {
                                                    "as_of": {
                                                      "type": "integer"
                                                    },
                                                    "base": {
                                                      "type": "string"
                                                    },
                                                    "quote": {
                                                      "type": "string"
                                                    },
                                                    "rate": {
                                                      "properties": {
                                                        "scale": {
                                                          "type": "integer"
                                                        },
                                                        "units": {
                                                          "anyOf": [
                                                            {
                                                              "description": "Exact decimal integer units.",
                                                              "pattern": "^-?[0-9]+$",
                                                              "type": "string"
                                                            },
                                                            {
                                                              "type": "null"
                                                            }
                                                          ]
                                                        }
                                                      },
                                                      "type": "object"
                                                    },
                                                    "rate_source": {
                                                      "type": "string"
                                                    }
                                                  },
                                                  "type": "object"
                                                },
                                                "sig": {
                                                  "description": "Hex-encoded bytes.",
                                                  "pattern": "^[0-9a-f]*$",
                                                  "type": "string"
                                                }
                                              },
                                              "type": "object"
                                            },
                                            "type": "array"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "tax_policy": {
                                        "properties": {
                                          "author": {
                                            "type": "string"
                                          },
                                          "characters": {
                                            "anyOf": [
                                              {
                                                "items": {
                                                  "type": "string"
                                                },
                                                "type": "array"
                                              },
                                              {
                                                "type": "null"
                                              }
                                            ]
                                          },
                                          "default": {
                                            "type": "string"
                                          },
                                          "rules": {
                                            "anyOf": [
                                              {
                                                "items": {
                                                  "properties": {
                                                    "character": {
                                                      "type": "string"
                                                    },
                                                    "creditor": {
                                                      "type": "string"
                                                    },
                                                    "creditor_jur": {
                                                      "type": "string"
                                                    },
                                                    "debtor": {
                                                      "type": "string"
                                                    },
                                                    "debtor_jur": {
                                                      "type": "string"
                                                    },
                                                    "disposition": {
                                                      "type": "string"
                                                    }
                                                  },
                                                  "type": "object"
                                                },
                                                "type": "array"
                                              },
                                              {
                                                "type": "null"
                                              }
                                            ]
                                          },
                                          "source_ref": {
                                            "type": "string"
                                          },
                                          "sources": {
                                            "anyOf": [
                                              {
                                                "items": {
                                                  "type": "string"
                                                },
                                                "type": "array"
                                              },
                                              {
                                                "type": "null"
                                              }
                                            ]
                                          },
                                          "version": {
                                            "type": "integer"
                                          }
                                        },
                                        "type": "object"
                                      },
                                      "tenant": {
                                        "description": "Hex-encoded bytes.",
                                        "pattern": "^[0-9a-f]*$",
                                        "type": "string"
                                      },
                                      "value_date": {
                                        "type": "string"
                                      },
                                      "version": {
                                        "type": "integer"
                                      }
                                    },
                                    "type": "object"
                                  },
                                  "position_conversions": {
                                    "anyOf": [
                                      {
                                        "items": {
                                          "properties": {
                                            "amount": {
                                              "properties": {
                                                "asset": {
                                                  "type": "string"
                                                },
                                                "scale": {
                                                  "type": "integer"
                                                },
                                                "units": {
                                                  "anyOf": [
                                                    {
                                                      "description": "Exact decimal integer units.",
                                                      "pattern": "^-?[0-9]+$",
                                                      "type": "string"
                                                    },
                                                    {
                                                      "type": "null"
                                                    }
                                                  ]
                                                }
                                              },
                                              "type": "object"
                                            },
                                            "position": {
                                              "properties": {
                                                "asset": {
                                                  "type": "string"
                                                },
                                                "party": {
                                                  "type": "string"
                                                },
                                                "scale": {
                                                  "type": "integer"
                                                },
                                                "units": {
                                                  "anyOf": [
                                                    {
                                                      "description": "Exact decimal integer units.",
                                                      "pattern": "^-?[0-9]+$",
                                                      "type": "string"
                                                    },
                                                    {
                                                      "type": "null"
                                                    }
                                                  ]
                                                }
                                              },
                                              "type": "object"
                                            },
                                            "rate_index": {
                                              "type": "integer"
                                            },
                                            "remainder_numerator": {
                                              "anyOf": [
                                                {
                                                  "description": "Exact decimal integer units.",
                                                  "pattern": "^-?[0-9]+$",
                                                  "type": "string"
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "remainder_scale": {
                                              "type": "integer"
                                            }
                                          },
                                          "type": "object"
                                        },
                                        "type": "array"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "rounding_transfers": {
                                    "anyOf": [
                                      {
                                        "items": {
                                          "properties": {
                                            "currency": {
                                              "type": "string"
                                            },
                                            "position": {
                                              "properties": {
                                                "asset": {
                                                  "type": "string"
                                                },
                                                "party": {
                                                  "type": "string"
                                                },
                                                "scale": {
                                                  "type": "integer"
                                                },
                                                "units": {
                                                  "anyOf": [
                                                    {
                                                      "description": "Exact decimal integer units.",
                                                      "pattern": "^-?[0-9]+$",
                                                      "type": "string"
                                                    },
                                                    {
                                                      "type": "null"
                                                    }
                                                  ]
                                                }
                                              },
                                              "type": "object"
                                            }
                                          },
                                          "type": "object"
                                        },
                                        "type": "array"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  }
                                },
                                "type": "object"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "type": "object"
                      },
                      "type": "array"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "exceptions": {
                  "anyOf": [
                    {
                      "items": {
                        "properties": {
                          "cancelled_at": {
                            "type": "integer"
                          },
                          "cycle_id": {
                            "type": "string"
                          },
                          "disposition": {
                            "type": "string"
                          },
                          "obligation": {
                            "properties": {
                              "correction_reason": {
                                "type": "string"
                              },
                              "correction_ref": {
                                "type": "string"
                              },
                              "credit_note_for": {
                                "type": "string"
                              },
                              "due_date": {
                                "type": "string"
                              },
                              "external_payee_ref": {
                                "type": "string"
                              },
                              "first_seen": {
                                "type": "integer"
                              },
                              "invoice_date": {
                                "type": "string"
                              },
                              "leg": {
                                "properties": {
                                  "amount": {
                                    "properties": {
                                      "asset": {
                                        "type": "string"
                                      },
                                      "scale": {
                                        "type": "integer"
                                      },
                                      "units": {
                                        "anyOf": [
                                          {
                                            "description": "Exact decimal integer units.",
                                            "pattern": "^-?[0-9]+$",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      }
                                    },
                                    "type": "object"
                                  },
                                  "creditor": {
                                    "type": "string"
                                  },
                                  "debtor": {
                                    "type": "string"
                                  },
                                  "id": {
                                    "type": "string"
                                  },
                                  "priority": {
                                    "type": "integer"
                                  },
                                  "tax": {
                                    "anyOf": [
                                      {
                                        "properties": {
                                          "character": {
                                            "type": "string"
                                          },
                                          "character_ref": {
                                            "type": "string"
                                          },
                                          "character_src": {
                                            "type": "string"
                                          },
                                          "invoice_ref": {
                                            "type": "string"
                                          }
                                        },
                                        "type": "object"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  }
                                },
                                "type": "object"
                              },
                              "revision": {
                                "type": "integer"
                              },
                              "source": {
                                "type": "string"
                              },
                              "source_id": {
                                "type": "string"
                              }
                            },
                            "type": "object"
                          },
                          "policy_version": {
                            "type": "integer"
                          },
                          "review": {
                            "anyOf": [
                              {
                                "properties": {
                                  "next_action": {
                                    "type": "string"
                                  },
                                  "obligation_id": {
                                    "type": "string"
                                  },
                                  "owner": {
                                    "type": "string"
                                  },
                                  "reason": {
                                    "type": "string"
                                  },
                                  "revision": {
                                    "type": "integer"
                                  }
                                },
                                "type": "object"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "rule": {
                            "type": "integer"
                          },
                          "set_off_at": {
                            "type": "integer"
                          },
                          "withholding_settlement_id": {
                            "type": "string"
                          }
                        },
                        "type": "object"
                      },
                      "type": "array"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "gross_register": {
                  "anyOf": [
                    {
                      "items": {
                        "properties": {
                          "amount": {
                            "properties": {
                              "asset": {
                                "type": "string"
                              },
                              "scale": {
                                "type": "integer"
                              },
                              "units": {
                                "anyOf": [
                                  {
                                    "description": "Exact decimal integer units.",
                                    "pattern": "^-?[0-9]+$",
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              }
                            },
                            "type": "object"
                          },
                          "character": {
                            "type": "string"
                          },
                          "count": {
                            "type": "integer"
                          },
                          "credit": {
                            "type": "boolean"
                          },
                          "creditor_jurisdiction": {
                            "type": "string"
                          },
                          "debtor_jurisdiction": {
                            "type": "string"
                          },
                          "disposition": {
                            "type": "string"
                          },
                          "source": {
                            "type": "string"
                          }
                        },
                        "type": "object"
                      },
                      "type": "array"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "head": {
                  "description": "Hex-encoded bytes.",
                  "pattern": "^[0-9a-f]*$",
                  "type": "string"
                },
                "original_credits": {
                  "anyOf": [
                    {
                      "items": {
                        "properties": {
                          "asset": {
                            "type": "string"
                          },
                          "count": {
                            "type": "integer"
                          },
                          "scale": {
                            "type": "integer"
                          },
                          "units": {
                            "anyOf": [
                              {
                                "description": "Exact decimal integer units.",
                                "pattern": "^-?[0-9]+$",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "type": "object"
                      },
                      "type": "array"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "original_gross": {
                  "anyOf": [
                    {
                      "items": {
                        "properties": {
                          "asset": {
                            "type": "string"
                          },
                          "count": {
                            "type": "integer"
                          },
                          "scale": {
                            "type": "integer"
                          },
                          "units": {
                            "anyOf": [
                              {
                                "description": "Exact decimal integer units.",
                                "pattern": "^-?[0-9]+$",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "type": "object"
                      },
                      "type": "array"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "outstanding": {
                  "anyOf": [
                    {
                      "items": {
                        "properties": {
                          "amount": {
                            "properties": {
                              "asset": {
                                "type": "string"
                              },
                              "scale": {
                                "type": "integer"
                              },
                              "units": {
                                "anyOf": [
                                  {
                                    "description": "Exact decimal integer units.",
                                    "pattern": "^-?[0-9]+$",
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              }
                            },
                            "type": "object"
                          },
                          "component": {
                            "type": "string"
                          },
                          "creditor": {
                            "type": "string"
                          },
                          "cycle_id": {
                            "type": "string"
                          },
                          "debtor": {
                            "type": "string"
                          },
                          "due_date": {
                            "type": "string"
                          },
                          "id": {
                            "type": "string"
                          },
                          "obligation_id": {
                            "type": "string"
                          },
                          "paid": {
                            "anyOf": [
                              {
                                "description": "Exact decimal integer units.",
                                "pattern": "^-?[0-9]+$",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "source_asset": {
                            "type": "string"
                          },
                          "withholding_settlement_id": {
                            "type": "string"
                          }
                        },
                        "type": "object"
                      },
                      "type": "array"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "policies": {
                  "anyOf": [
                    {
                      "additionalProperties": {
                        "properties": {
                          "author": {
                            "type": "string"
                          },
                          "characters": {
                            "anyOf": [
                              {
                                "items": {
                                  "type": "string"
                                },
                                "type": "array"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "default": {
                            "type": "string"
                          },
                          "rules": {
                            "anyOf": [
                              {
                                "items": {
                                  "properties": {
                                    "character": {
                                      "type": "string"
                                    },
                                    "creditor": {
                                      "type": "string"
                                    },
                                    "creditor_jur": {
                                      "type": "string"
                                    },
                                    "debtor": {
                                      "type": "string"
                                    },
                                    "debtor_jur": {
                                      "type": "string"
                                    },
                                    "disposition": {
                                      "type": "string"
                                    }
                                  },
                                  "type": "object"
                                },
                                "type": "array"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "source_ref": {
                            "type": "string"
                          },
                          "sources": {
                            "anyOf": [
                              {
                                "items": {
                                  "type": "string"
                                },
                                "type": "array"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "version": {
                            "type": "integer"
                          }
                        },
                        "type": "object"
                      },
                      "type": "object"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "query": {
                  "properties": {
                    "as_of": {
                      "type": "integer"
                    },
                    "character": {
                      "type": "string"
                    },
                    "cycle_id": {
                      "type": "string"
                    },
                    "disposition": {
                      "type": "string"
                    },
                    "entity": {
                      "type": "string"
                    },
                    "from": {
                      "type": "string"
                    },
                    "missing_character": {
                      "type": "boolean"
                    },
                    "obligation_id": {
                      "type": "string"
                    },
                    "to": {
                      "type": "string"
                    }
                  },
                  "type": "object"
                },
                "selected_original_credits": {
                  "anyOf": [
                    {
                      "items": {
                        "properties": {
                          "asset": {
                            "type": "string"
                          },
                          "count": {
                            "type": "integer"
                          },
                          "scale": {
                            "type": "integer"
                          },
                          "units": {
                            "anyOf": [
                              {
                                "description": "Exact decimal integer units.",
                                "pattern": "^-?[0-9]+$",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "type": "object"
                      },
                      "type": "array"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "selected_original_gross": {
                  "anyOf": [
                    {
                      "items": {
                        "properties": {
                          "asset": {
                            "type": "string"
                          },
                          "count": {
                            "type": "integer"
                          },
                          "scale": {
                            "type": "integer"
                          },
                          "units": {
                            "anyOf": [
                              {
                                "description": "Exact decimal integer units.",
                                "pattern": "^-?[0-9]+$",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "type": "object"
                      },
                      "type": "array"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "statement_entries": {
                  "anyOf": [
                    {
                      "items": {
                        "properties": {
                          "account": {
                            "properties": {
                              "currency": {
                                "type": "string"
                              },
                              "iban": {
                                "type": "string"
                              },
                              "name": {
                                "type": "string"
                              },
                              "other_id": {
                                "type": "string"
                              }
                            },
                            "type": "object"
                          },
                          "decision": {
                            "anyOf": [
                              {
                                "properties": {
                                  "decision": {
                                    "type": "string"
                                  },
                                  "entry_index": {
                                    "type": "integer"
                                  },
                                  "payment_id": {
                                    "type": "string"
                                  },
                                  "reason": {
                                    "type": "string"
                                  },
                                  "reverses": {
                                    "type": "string"
                                  },
                                  "statement_id": {
                                    "type": "string"
                                  },
                                  "statement_index": {
                                    "type": "integer"
                                  }
                                },
                                "type": "object"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "entry": {
                            "properties": {
                              "acct_svcr_ref": {
                                "type": "string"
                              },
                              "addtl_info": {
                                "type": "string"
                              },
                              "amount": {
                                "type": "string"
                              },
                              "asset": {
                                "type": "string"
                              },
                              "booking_date": {
                                "type": "string"
                              },
                              "direction": {
                                "type": "string"
                              },
                              "entry_ref": {
                                "type": "string"
                              },
                              "references": {
                                "anyOf": [
                                  {
                                    "items": {
                                      "type": "string"
                                    },
                                    "type": "array"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "reversal": {
                                "type": "boolean"
                              },
                              "status": {
                                "type": "string"
                              },
                              "tx_count": {
                                "type": "integer"
                              },
                              "value_date": {
                                "type": "string"
                              }
                            },
                            "type": "object"
                          },
                          "entry_index": {
                            "type": "integer"
                          },
                          "reference": {
                            "type": "string"
                          },
                          "statement_id": {
                            "type": "string"
                          },
                          "statement_index": {
                            "type": "integer"
                          },
                          "suggested_payment_i_ds": {
                            "anyOf": [
                              {
                                "items": {
                                  "type": "string"
                                },
                                "type": "array"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "type": "object"
                      },
                      "type": "array"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "tax_legs": {
                  "anyOf": [
                    {
                      "items": {
                        "properties": {
                          "creditor_jurisdiction": {
                            "type": "string"
                          },
                          "cycle_id": {
                            "type": "string"
                          },
                          "debtor_jurisdiction": {
                            "type": "string"
                          },
                          "disposition": {
                            "type": "string"
                          },
                          "effective_set_off": {
                            "type": "integer"
                          },
                          "missing_character": {
                            "type": "boolean"
                          },
                          "obligation": {
                            "properties": {
                              "correction_reason": {
                                "type": "string"
                              },
                              "correction_ref": {
                                "type": "string"
                              },
                              "credit_note_for": {
                                "type": "string"
                              },
                              "due_date": {
                                "type": "string"
                              },
                              "external_payee_ref": {
                                "type": "string"
                              },
                              "first_seen": {
                                "type": "integer"
                              },
                              "invoice_date": {
                                "type": "string"
                              },
                              "leg": {
                                "properties": {
                                  "amount": {
                                    "properties": {
                                      "asset": {
                                        "type": "string"
                                      },
                                      "scale": {
                                        "type": "integer"
                                      },
                                      "units": {
                                        "anyOf": [
                                          {
                                            "description": "Exact decimal integer units.",
                                            "pattern": "^-?[0-9]+$",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      }
                                    },
                                    "type": "object"
                                  },
                                  "creditor": {
                                    "type": "string"
                                  },
                                  "debtor": {
                                    "type": "string"
                                  },
                                  "id": {
                                    "type": "string"
                                  },
                                  "priority": {
                                    "type": "integer"
                                  },
                                  "tax": {
                                    "anyOf": [
                                      {
                                        "properties": {
                                          "character": {
                                            "type": "string"
                                          },
                                          "character_ref": {
                                            "type": "string"
                                          },
                                          "character_src": {
                                            "type": "string"
                                          },
                                          "invoice_ref": {
                                            "type": "string"
                                          }
                                        },
                                        "type": "object"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  }
                                },
                                "type": "object"
                              },
                              "revision": {
                                "type": "integer"
                              },
                              "source": {
                                "type": "string"
                              },
                              "source_id": {
                                "type": "string"
                              }
                            },
                            "type": "object"
                          },
                          "policy_hash": {
                            "description": "Hex-encoded bytes.",
                            "pattern": "^[0-9a-f]*$",
                            "type": "string"
                          },
                          "policy_source": {
                            "type": "string"
                          },
                          "policy_version": {
                            "type": "integer"
                          },
                          "rule": {
                            "type": "integer"
                          }
                        },
                        "type": "object"
                      },
                      "type": "array"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "withholding": {
                  "anyOf": [
                    {
                      "items": {
                        "properties": {
                          "assessment": {
                            "anyOf": [
                              {
                                "properties": {
                                  "calculation": {
                                    "properties": {
                                      "gross_up": {
                                        "anyOf": [
                                          {
                                            "properties": {
                                              "asset": {
                                                "type": "string"
                                              },
                                              "scale": {
                                                "type": "integer"
                                              },
                                              "units": {
                                                "anyOf": [
                                                  {
                                                    "description": "Exact decimal integer units.",
                                                    "pattern": "^-?[0-9]+$",
                                                    "type": "string"
                                                  },
                                                  {
                                                    "type": "null"
                                                  }
                                                ]
                                              }
                                            },
                                            "type": "object"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "missing": {
                                        "anyOf": [
                                          {
                                            "items": {
                                              "type": "string"
                                            },
                                            "type": "array"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "original": {
                                        "properties": {
                                          "asset": {
                                            "type": "string"
                                          },
                                          "scale": {
                                            "type": "integer"
                                          },
                                          "units": {
                                            "anyOf": [
                                              {
                                                "description": "Exact decimal integer units.",
                                                "pattern": "^-?[0-9]+$",
                                                "type": "string"
                                              },
                                              {
                                                "type": "null"
                                              }
                                            ]
                                          }
                                        },
                                        "type": "object"
                                      },
                                      "payer_funding": {
                                        "anyOf": [
                                          {
                                            "properties": {
                                              "asset": {
                                                "type": "string"
                                              },
                                              "scale": {
                                                "type": "integer"
                                              },
                                              "units": {
                                                "anyOf": [
                                                  {
                                                    "description": "Exact decimal integer units.",
                                                    "pattern": "^-?[0-9]+$",
                                                    "type": "string"
                                                  },
                                                  {
                                                    "type": "null"
                                                  }
                                                ]
                                              }
                                            },
                                            "type": "object"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "recipient": {
                                        "anyOf": [
                                          {
                                            "properties": {
                                              "asset": {
                                                "type": "string"
                                              },
                                              "scale": {
                                                "type": "integer"
                                              },
                                              "units": {
                                                "anyOf": [
                                                  {
                                                    "description": "Exact decimal integer units.",
                                                    "pattern": "^-?[0-9]+$",
                                                    "type": "string"
                                                  },
                                                  {
                                                    "type": "null"
                                                  }
                                                ]
                                              }
                                            },
                                            "type": "object"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "remainder_denominator": {
                                        "anyOf": [
                                          {
                                            "description": "Exact decimal integer units.",
                                            "pattern": "^-?[0-9]+$",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "remainder_numerator": {
                                        "anyOf": [
                                          {
                                            "description": "Exact decimal integer units.",
                                            "pattern": "^-?[0-9]+$",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "status": {
                                        "type": "string"
                                      },
                                      "taxable_base": {
                                        "anyOf": [
                                          {
                                            "properties": {
                                              "asset": {
                                                "type": "string"
                                              },
                                              "scale": {
                                                "type": "integer"
                                              },
                                              "units": {
                                                "anyOf": [
                                                  {
                                                    "description": "Exact decimal integer units.",
                                                    "pattern": "^-?[0-9]+$",
                                                    "type": "string"
                                                  },
                                                  {
                                                    "type": "null"
                                                  }
                                                ]
                                              }
                                            },
                                            "type": "object"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "withheld": {
                                        "anyOf": [
                                          {
                                            "properties": {
                                              "asset": {
                                                "type": "string"
                                              },
                                              "scale": {
                                                "type": "integer"
                                              },
                                              "units": {
                                                "anyOf": [
                                                  {
                                                    "description": "Exact decimal integer units.",
                                                    "pattern": "^-?[0-9]+$",
                                                    "type": "string"
                                                  },
                                                  {
                                                    "type": "null"
                                                  }
                                                ]
                                              }
                                            },
                                            "type": "object"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      }
                                    },
                                    "type": "object"
                                  },
                                  "determination": {
                                    "properties": {
                                      "beneficial_owner_ref": {
                                        "type": "string"
                                      },
                                      "determination_ref": {
                                        "type": "string"
                                      },
                                      "determined_by": {
                                        "type": "string"
                                      },
                                      "eligibility_ref": {
                                        "type": "string"
                                      },
                                      "method": {
                                        "type": "string"
                                      },
                                      "obligation_id": {
                                        "type": "string"
                                      },
                                      "rate": {
                                        "anyOf": [
                                          {
                                            "properties": {
                                              "scale": {
                                                "type": "integer"
                                              },
                                              "units": {
                                                "anyOf": [
                                                  {
                                                    "description": "Exact decimal integer units.",
                                                    "pattern": "^-?[0-9]+$",
                                                    "type": "string"
                                                  },
                                                  {
                                                    "type": "null"
                                                  }
                                                ]
                                              }
                                            },
                                            "type": "object"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "rate_basis": {
                                        "type": "string"
                                      },
                                      "recipient_residence": {
                                        "type": "string"
                                      },
                                      "residence_ref": {
                                        "type": "string"
                                      },
                                      "revision": {
                                        "type": "integer"
                                      },
                                      "rounding": {
                                        "type": "string"
                                      },
                                      "rule_ref": {
                                        "type": "string"
                                      },
                                      "source_jurisdiction": {
                                        "type": "string"
                                      },
                                      "tax_authority_ref": {
                                        "type": "string"
                                      },
                                      "tax_date": {
                                        "type": "string"
                                      },
                                      "tax_point": {
                                        "type": "string"
                                      },
                                      "taxable_base": {
                                        "anyOf": [
                                          {
                                            "properties": {
                                              "asset": {
                                                "type": "string"
                                              },
                                              "scale": {
                                                "type": "integer"
                                              },
                                              "units": {
                                                "anyOf": [
                                                  {
                                                    "description": "Exact decimal integer units.",
                                                    "pattern": "^-?[0-9]+$",
                                                    "type": "string"
                                                  },
                                                  {
                                                    "type": "null"
                                                  }
                                                ]
                                              }
                                            },
                                            "type": "object"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "valid_from": {
                                        "type": "string"
                                      },
                                      "valid_through": {
                                        "type": "string"
                                      }
                                    },
                                    "type": "object"
                                  },
                                  "id": {
                                    "type": "string"
                                  },
                                  "obligation": {
                                    "properties": {
                                      "correction_reason": {
                                        "type": "string"
                                      },
                                      "correction_ref": {
                                        "type": "string"
                                      },
                                      "credit_note_for": {
                                        "type": "string"
                                      },
                                      "due_date": {
                                        "type": "string"
                                      },
                                      "external_payee_ref": {
                                        "type": "string"
                                      },
                                      "first_seen": {
                                        "type": "integer"
                                      },
                                      "invoice_date": {
                                        "type": "string"
                                      },
                                      "leg": {
                                        "properties": {
                                          "amount": {
                                            "properties": {
                                              "asset": {
                                                "type": "string"
                                              },
                                              "scale": {
                                                "type": "integer"
                                              },
                                              "units": {
                                                "anyOf": [
                                                  {
                                                    "description": "Exact decimal integer units.",
                                                    "pattern": "^-?[0-9]+$",
                                                    "type": "string"
                                                  },
                                                  {
                                                    "type": "null"
                                                  }
                                                ]
                                              }
                                            },
                                            "type": "object"
                                          },
                                          "creditor": {
                                            "type": "string"
                                          },
                                          "debtor": {
                                            "type": "string"
                                          },
                                          "id": {
                                            "type": "string"
                                          },
                                          "priority": {
                                            "type": "integer"
                                          },
                                          "tax": {
                                            "anyOf": [
                                              {
                                                "properties": {
                                                  "character": {
                                                    "type": "string"
                                                  },
                                                  "character_ref": {
                                                    "type": "string"
                                                  },
                                                  "character_src": {
                                                    "type": "string"
                                                  },
                                                  "invoice_ref": {
                                                    "type": "string"
                                                  }
                                                },
                                                "type": "object"
                                              },
                                              {
                                                "type": "null"
                                              }
                                            ]
                                          }
                                        },
                                        "type": "object"
                                      },
                                      "revision": {
                                        "type": "integer"
                                      },
                                      "source": {
                                        "type": "string"
                                      },
                                      "source_id": {
                                        "type": "string"
                                      }
                                    },
                                    "type": "object"
                                  },
                                  "recorded_at": {
                                    "type": "integer"
                                  },
                                  "requester": {
                                    "description": "Hex-encoded bytes.",
                                    "pattern": "^[0-9a-f]*$",
                                    "type": "string"
                                  },
                                  "reviewer": {
                                    "description": "Hex-encoded bytes.",
                                    "pattern": "^[0-9a-f]*$",
                                    "type": "string"
                                  }
                                },
                                "type": "object"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "calculation": {
                            "properties": {
                              "gross_up": {
                                "anyOf": [
                                  {
                                    "properties": {
                                      "asset": {
                                        "type": "string"
                                      },
                                      "scale": {
                                        "type": "integer"
                                      },
                                      "units": {
                                        "anyOf": [
                                          {
                                            "description": "Exact decimal integer units.",
                                            "pattern": "^-?[0-9]+$",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      }
                                    },
                                    "type": "object"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "missing": {
                                "anyOf": [
                                  {
                                    "items": {
                                      "type": "string"
                                    },
                                    "type": "array"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "original": {
                                "properties": {
                                  "asset": {
                                    "type": "string"
                                  },
                                  "scale": {
                                    "type": "integer"
                                  },
                                  "units": {
                                    "anyOf": [
                                      {
                                        "description": "Exact decimal integer units.",
                                        "pattern": "^-?[0-9]+$",
                                        "type": "string"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  }
                                },
                                "type": "object"
                              },
                              "payer_funding": {
                                "anyOf": [
                                  {
                                    "properties": {
                                      "asset": {
                                        "type": "string"
                                      },
                                      "scale": {
                                        "type": "integer"
                                      },
                                      "units": {
                                        "anyOf": [
                                          {
                                            "description": "Exact decimal integer units.",
                                            "pattern": "^-?[0-9]+$",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      }
                                    },
                                    "type": "object"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "recipient": {
                                "anyOf": [
                                  {
                                    "properties": {
                                      "asset": {
                                        "type": "string"
                                      },
                                      "scale": {
                                        "type": "integer"
                                      },
                                      "units": {
                                        "anyOf": [
                                          {
                                            "description": "Exact decimal integer units.",
                                            "pattern": "^-?[0-9]+$",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      }
                                    },
                                    "type": "object"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "remainder_denominator": {
                                "anyOf": [
                                  {
                                    "description": "Exact decimal integer units.",
                                    "pattern": "^-?[0-9]+$",
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "remainder_numerator": {
                                "anyOf": [
                                  {
                                    "description": "Exact decimal integer units.",
                                    "pattern": "^-?[0-9]+$",
                                    "type": "string"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "status": {
                                "type": "string"
                              },
                              "taxable_base": {
                                "anyOf": [
                                  {
                                    "properties": {
                                      "asset": {
                                        "type": "string"
                                      },
                                      "scale": {
                                        "type": "integer"
                                      },
                                      "units": {
                                        "anyOf": [
                                          {
                                            "description": "Exact decimal integer units.",
                                            "pattern": "^-?[0-9]+$",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      }
                                    },
                                    "type": "object"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "withheld": {
                                "anyOf": [
                                  {
                                    "properties": {
                                      "asset": {
                                        "type": "string"
                                      },
                                      "scale": {
                                        "type": "integer"
                                      },
                                      "units": {
                                        "anyOf": [
                                          {
                                            "description": "Exact decimal integer units.",
                                            "pattern": "^-?[0-9]+$",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      }
                                    },
                                    "type": "object"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              }
                            },
                            "type": "object"
                          },
                          "disposition": {
                            "type": "string"
                          },
                          "obligation": {
                            "properties": {
                              "correction_reason": {
                                "type": "string"
                              },
                              "correction_ref": {
                                "type": "string"
                              },
                              "credit_note_for": {
                                "type": "string"
                              },
                              "due_date": {
                                "type": "string"
                              },
                              "external_payee_ref": {
                                "type": "string"
                              },
                              "first_seen": {
                                "type": "integer"
                              },
                              "invoice_date": {
                                "type": "string"
                              },
                              "leg": {
                                "properties": {
                                  "amount": {
                                    "properties": {
                                      "asset": {
                                        "type": "string"
                                      },
                                      "scale": {
                                        "type": "integer"
                                      },
                                      "units": {
                                        "anyOf": [
                                          {
                                            "description": "Exact decimal integer units.",
                                            "pattern": "^-?[0-9]+$",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      }
                                    },
                                    "type": "object"
                                  },
                                  "creditor": {
                                    "type": "string"
                                  },
                                  "debtor": {
                                    "type": "string"
                                  },
                                  "id": {
                                    "type": "string"
                                  },
                                  "priority": {
                                    "type": "integer"
                                  },
                                  "tax": {
                                    "anyOf": [
                                      {
                                        "properties": {
                                          "character": {
                                            "type": "string"
                                          },
                                          "character_ref": {
                                            "type": "string"
                                          },
                                          "character_src": {
                                            "type": "string"
                                          },
                                          "invoice_ref": {
                                            "type": "string"
                                          }
                                        },
                                        "type": "object"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  }
                                },
                                "type": "object"
                              },
                              "revision": {
                                "type": "integer"
                              },
                              "source": {
                                "type": "string"
                              },
                              "source_id": {
                                "type": "string"
                              }
                            },
                            "type": "object"
                          }
                        },
                        "type": "object"
                      },
                      "type": "array"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "withholding_settlements": {
                  "anyOf": [
                    {
                      "items": {
                        "properties": {
                          "recipient": {
                            "anyOf": [
                              {
                                "properties": {
                                  "confirmations": {
                                    "anyOf": [
                                      {
                                        "items": {
                                          "properties": {
                                            "amount": {
                                              "properties": {
                                                "asset": {
                                                  "type": "string"
                                                },
                                                "scale": {
                                                  "type": "integer"
                                                },
                                                "units": {
                                                  "anyOf": [
                                                    {
                                                      "description": "Exact decimal integer units.",
                                                      "pattern": "^-?[0-9]+$",
                                                      "type": "string"
                                                    },
                                                    {
                                                      "type": "null"
                                                    }
                                                  ]
                                                }
                                              },
                                              "type": "object"
                                            },
                                            "payment_id": {
                                              "type": "string"
                                            },
                                            "reference": {
                                              "type": "string"
                                            },
                                            "reverses": {
                                              "type": "string"
                                            },
                                            "source_ref": {
                                              "type": "string"
                                            },
                                            "value_date": {
                                              "type": "string"
                                            }
                                          },
                                          "type": "object"
                                        },
                                        "type": "array"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "instructions": {
                                    "anyOf": [
                                      {
                                        "items": {
                                          "properties": {
                                            "cancellation": {
                                              "anyOf": [
                                                {
                                                  "properties": {
                                                    "payment_id": {
                                                      "type": "string"
                                                    },
                                                    "reason": {
                                                      "type": "string"
                                                    },
                                                    "source_ref": {
                                                      "type": "string"
                                                    }
                                                  },
                                                  "type": "object"
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "confirmed": {
                                              "anyOf": [
                                                {
                                                  "description": "Exact decimal integer units.",
                                                  "pattern": "^-?[0-9]+$",
                                                  "type": "string"
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "execution": {
                                              "anyOf": [
                                                {
                                                  "properties": {
                                                    "funding_hold": {
                                                      "anyOf": [
                                                        {
                                                          "properties": {
                                                            "account": {
                                                              "type": "string"
                                                            },
                                                            "amount": {
                                                              "properties": {
                                                                "asset": {
                                                                  "type": "string"
                                                                },
                                                                "scale": {
                                                                  "type": "integer"
                                                                },
                                                                "units": {
                                                                  "anyOf": [
                                                                    {
                                                                      "description": "Exact decimal integer units.",
                                                                      "pattern": "^-?[0-9]+$",
                                                                      "type": "string"
                                                                    },
                                                                    {
                                                                      "type": "null"
                                                                    }
                                                                  ]
                                                                }
                                                              },
                                                              "type": "object"
                                                            },
                                                            "bank_request_id": {
                                                              "type": "string"
                                                            },
                                                            "expiry": {
                                                              "type": "integer"
                                                            },
                                                            "hold_id": {
                                                              "description": "Hex-encoded bytes.",
                                                              "pattern": "^[0-9a-f]*$",
                                                              "type": "string"
                                                            },
                                                            "obligor": {
                                                              "anyOf": [
                                                                {
                                                                  "description": "Hex-encoded bytes.",
                                                                  "pattern": "^[0-9a-f]*$",
                                                                  "type": "string"
                                                                },
                                                                {
                                                                  "type": "null"
                                                                }
                                                              ]
                                                            },
                                                            "sig": {
                                                              "description": "Hex-encoded bytes.",
                                                              "pattern": "^[0-9a-f]*$",
                                                              "type": "string"
                                                            }
                                                          },
                                                          "type": "object"
                                                        },
                                                        {
                                                          "type": "null"
                                                        }
                                                      ]
                                                    },
                                                    "funding_ref": {
                                                      "type": "string"
                                                    },
                                                    "instruction": {
                                                      "anyOf": [
                                                        {
                                                          "properties": {
                                                            "atomicity": {
                                                              "type": "string"
                                                            },
                                                            "bank_request_id": {
                                                              "type": "string"
                                                            },
                                                            "conversion_leaf_ref": {
                                                              "anyOf": [
                                                                {
                                                                  "description": "Hex-encoded bytes.",
                                                                  "pattern": "^[0-9a-f]*$",
                                                                  "type": "string"
                                                                },
                                                                {
                                                                  "type": "null"
                                                                }
                                                              ]
                                                            },
                                                            "cycle_id": {
                                                              "type": "string"
                                                            },
                                                            "cycle_leaf_ref": {
                                                              "anyOf": [
                                                                {
                                                                  "description": "Hex-encoded bytes.",
                                                                  "pattern": "^[0-9a-f]*$",
                                                                  "type": "string"
                                                                },
                                                                {
                                                                  "type": "null"
                                                                }
                                                              ]
                                                            },
                                                            "invoice_ref": {
                                                              "type": "string"
                                                            },
                                                            "legs": {
                                                              "anyOf": [
                                                                {
                                                                  "items": {
                                                                    "properties": {
                                                                      "amount": {
                                                                        "properties": {
                                                                          "asset": {
                                                                            "type": "string"
                                                                          },
                                                                          "scale": {
                                                                            "type": "integer"
                                                                          },
                                                                          "units": {
                                                                            "anyOf": [
                                                                              {
                                                                                "description": "Exact decimal integer units.",
                                                                                "pattern": "^-?[0-9]+$",
                                                                                "type": "string"
                                                                              },
                                                                              {
                                                                                "type": "null"
                                                                              }
                                                                            ]
                                                                          }
                                                                        },
                                                                        "type": "object"
                                                                      },
                                                                      "detail": {
                                                                        "anyOf": [
                                                                          {
                                                                            "properties": {
                                                                              "account": {
                                                                                "type": "string"
                                                                              },
                                                                              "counterparty": {
                                                                                "type": "string"
                                                                              },
                                                                              "rail": {
                                                                                "type": "string"
                                                                              },
                                                                              "recipient_account": {
                                                                                "type": "string"
                                                                              },
                                                                              "token": {
                                                                                "type": "string"
                                                                              },
                                                                              "token_chain_id": {
                                                                                "type": "integer"
                                                                              },
                                                                              "token_symbol": {
                                                                                "type": "string"
                                                                              },
                                                                              "venue": {
                                                                                "type": "string"
                                                                              }
                                                                            },
                                                                            "type": "object"
                                                                          },
                                                                          {
                                                                            "type": "null"
                                                                          }
                                                                        ]
                                                                      },
                                                                      "finality_class": {
                                                                        "type": "string"
                                                                      },
                                                                      "form": {
                                                                        "type": "string"
                                                                      },
                                                                      "id": {
                                                                        "description": "Hex-encoded bytes.",
                                                                        "pattern": "^[0-9a-f]*$",
                                                                        "type": "string"
                                                                      },
                                                                      "locked_rate": {
                                                                        "anyOf": [
                                                                          {
                                                                            "properties": {
                                                                              "scale": {
                                                                                "type": "integer"
                                                                              },
                                                                              "units": {
                                                                                "anyOf": [
                                                                                  {
                                                                                    "description": "Exact decimal integer units.",
                                                                                    "pattern": "^-?[0-9]+$",
                                                                                    "type": "string"
                                                                                  },
                                                                                  {
                                                                                    "type": "null"
                                                                                  }
                                                                                ]
                                                                              }
                                                                            },
                                                                            "type": "object"
                                                                          },
                                                                          {
                                                                            "type": "null"
                                                                          }
                                                                        ]
                                                                      },
                                                                      "obligor": {
                                                                        "description": "Hex-encoded bytes.",
                                                                        "pattern": "^[0-9a-f]*$",
                                                                        "type": "string"
                                                                      },
                                                                      "rate_source": {
                                                                        "type": "string"
                                                                      },
                                                                      "role": {
                                                                        "type": "string"
                                                                      },
                                                                      "seq": {
                                                                        "type": "integer"
                                                                      }
                                                                    },
                                                                    "type": "object"
                                                                  },
                                                                  "type": "array"
                                                                },
                                                                {
                                                                  "type": "null"
                                                                }
                                                              ]
                                                            },
                                                            "settlement_kind": {
                                                              "type": "string"
                                                            },
                                                            "tenant": {
                                                              "description": "Hex-encoded bytes.",
                                                              "pattern": "^[0-9a-f]*$",
                                                              "type": "string"
                                                            }
                                                          },
                                                          "type": "object"
                                                        },
                                                        {
                                                          "type": "null"
                                                        }
                                                      ]
                                                    },
                                                    "payment_id": {
                                                      "type": "string"
                                                    },
                                                    "route": {
                                                      "type": "string"
                                                    },
                                                    "settlement_id": {
                                                      "anyOf": [
                                                        {
                                                          "description": "Hex-encoded bytes.",
                                                          "pattern": "^[0-9a-f]*$",
                                                          "type": "string"
                                                        },
                                                        {
                                                          "type": "null"
                                                        }
                                                      ]
                                                    }
                                                  },
                                                  "type": "object"
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "execution_at": {
                                              "type": "integer"
                                            },
                                            "instruction": {
                                              "properties": {
                                                "amount": {
                                                  "properties": {
                                                    "asset": {
                                                      "type": "string"
                                                    },
                                                    "scale": {
                                                      "type": "integer"
                                                    },
                                                    "units": {
                                                      "anyOf": [
                                                        {
                                                          "description": "Exact decimal integer units.",
                                                          "pattern": "^-?[0-9]+$",
                                                          "type": "string"
                                                        },
                                                        {
                                                          "type": "null"
                                                        }
                                                      ]
                                                    }
                                                  },
                                                  "type": "object"
                                                },
                                                "creditor_account": {
                                                  "properties": {
                                                    "asset": {
                                                      "type": "string"
                                                    },
                                                    "bic": {
                                                      "type": "string"
                                                    },
                                                    "finality_class": {
                                                      "type": "string"
                                                    },
                                                    "frame_party_id": {
                                                      "description": "Hex-encoded bytes.",
                                                      "pattern": "^[0-9a-f]*$",
                                                      "type": "string"
                                                    },
                                                    "iban": {
                                                      "type": "string"
                                                    },
                                                    "name": {
                                                      "type": "string"
                                                    },
                                                    "other_id": {
                                                      "type": "string"
                                                    },
                                                    "party": {
                                                      "type": "string"
                                                    },
                                                    "rail": {
                                                      "type": "string"
                                                    },
                                                    "source_ref": {
                                                      "type": "string"
                                                    }
                                                  },
                                                  "type": "object"
                                                },
                                                "debtor_account": {
                                                  "properties": {
                                                    "asset": {
                                                      "type": "string"
                                                    },
                                                    "bic": {
                                                      "type": "string"
                                                    },
                                                    "finality_class": {
                                                      "type": "string"
                                                    },
                                                    "frame_party_id": {
                                                      "description": "Hex-encoded bytes.",
                                                      "pattern": "^[0-9a-f]*$",
                                                      "type": "string"
                                                    },
                                                    "iban": {
                                                      "type": "string"
                                                    },
                                                    "name": {
                                                      "type": "string"
                                                    },
                                                    "other_id": {
                                                      "type": "string"
                                                    },
                                                    "party": {
                                                      "type": "string"
                                                    },
                                                    "rail": {
                                                      "type": "string"
                                                    },
                                                    "source_ref": {
                                                      "type": "string"
                                                    }
                                                  },
                                                  "type": "object"
                                                },
                                                "execution_date": {
                                                  "type": "string"
                                                },
                                                "id": {
                                                  "type": "string"
                                                },
                                                "payable_id": {
                                                  "type": "string"
                                                }
                                              },
                                              "type": "object"
                                            },
                                            "route": {
                                              "type": "string"
                                            }
                                          },
                                          "type": "object"
                                        },
                                        "type": "array"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "payable": {
                                    "properties": {
                                      "amount": {
                                        "properties": {
                                          "asset": {
                                            "type": "string"
                                          },
                                          "scale": {
                                            "type": "integer"
                                          },
                                          "units": {
                                            "anyOf": [
                                              {
                                                "description": "Exact decimal integer units.",
                                                "pattern": "^-?[0-9]+$",
                                                "type": "string"
                                              },
                                              {
                                                "type": "null"
                                              }
                                            ]
                                          }
                                        },
                                        "type": "object"
                                      },
                                      "component": {
                                        "type": "string"
                                      },
                                      "creditor": {
                                        "type": "string"
                                      },
                                      "cycle_id": {
                                        "type": "string"
                                      },
                                      "debtor": {
                                        "type": "string"
                                      },
                                      "due_date": {
                                        "type": "string"
                                      },
                                      "id": {
                                        "type": "string"
                                      },
                                      "obligation_id": {
                                        "type": "string"
                                      },
                                      "paid": {
                                        "anyOf": [
                                          {
                                            "description": "Exact decimal integer units.",
                                            "pattern": "^-?[0-9]+$",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "source_asset": {
                                        "type": "string"
                                      },
                                      "withholding_settlement_id": {
                                        "type": "string"
                                      }
                                    },
                                    "type": "object"
                                  },
                                  "remaining": {
                                    "properties": {
                                      "asset": {
                                        "type": "string"
                                      },
                                      "scale": {
                                        "type": "integer"
                                      },
                                      "units": {
                                        "anyOf": [
                                          {
                                            "description": "Exact decimal integer units.",
                                            "pattern": "^-?[0-9]+$",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      }
                                    },
                                    "type": "object"
                                  }
                                },
                                "type": "object"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "settlement": {
                            "properties": {
                              "assessment": {
                                "properties": {
                                  "calculation": {
                                    "properties": {
                                      "gross_up": {
                                        "anyOf": [
                                          {
                                            "properties": {
                                              "asset": {
                                                "type": "string"
                                              },
                                              "scale": {
                                                "type": "integer"
                                              },
                                              "units": {
                                                "anyOf": [
                                                  {
                                                    "description": "Exact decimal integer units.",
                                                    "pattern": "^-?[0-9]+$",
                                                    "type": "string"
                                                  },
                                                  {
                                                    "type": "null"
                                                  }
                                                ]
                                              }
                                            },
                                            "type": "object"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "missing": {
                                        "anyOf": [
                                          {
                                            "items": {
                                              "type": "string"
                                            },
                                            "type": "array"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "original": {
                                        "properties": {
                                          "asset": {
                                            "type": "string"
                                          },
                                          "scale": {
                                            "type": "integer"
                                          },
                                          "units": {
                                            "anyOf": [
                                              {
                                                "description": "Exact decimal integer units.",
                                                "pattern": "^-?[0-9]+$",
                                                "type": "string"
                                              },
                                              {
                                                "type": "null"
                                              }
                                            ]
                                          }
                                        },
                                        "type": "object"
                                      },
                                      "payer_funding": {
                                        "anyOf": [
                                          {
                                            "properties": {
                                              "asset": {
                                                "type": "string"
                                              },
                                              "scale": {
                                                "type": "integer"
                                              },
                                              "units": {
                                                "anyOf": [
                                                  {
                                                    "description": "Exact decimal integer units.",
                                                    "pattern": "^-?[0-9]+$",
                                                    "type": "string"
                                                  },
                                                  {
                                                    "type": "null"
                                                  }
                                                ]
                                              }
                                            },
                                            "type": "object"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "recipient": {
                                        "anyOf": [
                                          {
                                            "properties": {
                                              "asset": {
                                                "type": "string"
                                              },
                                              "scale": {
                                                "type": "integer"
                                              },
                                              "units": {
                                                "anyOf": [
                                                  {
                                                    "description": "Exact decimal integer units.",
                                                    "pattern": "^-?[0-9]+$",
                                                    "type": "string"
                                                  },
                                                  {
                                                    "type": "null"
                                                  }
                                                ]
                                              }
                                            },
                                            "type": "object"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "remainder_denominator": {
                                        "anyOf": [
                                          {
                                            "description": "Exact decimal integer units.",
                                            "pattern": "^-?[0-9]+$",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "remainder_numerator": {
                                        "anyOf": [
                                          {
                                            "description": "Exact decimal integer units.",
                                            "pattern": "^-?[0-9]+$",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "status": {
                                        "type": "string"
                                      },
                                      "taxable_base": {
                                        "anyOf": [
                                          {
                                            "properties": {
                                              "asset": {
                                                "type": "string"
                                              },
                                              "scale": {
                                                "type": "integer"
                                              },
                                              "units": {
                                                "anyOf": [
                                                  {
                                                    "description": "Exact decimal integer units.",
                                                    "pattern": "^-?[0-9]+$",
                                                    "type": "string"
                                                  },
                                                  {
                                                    "type": "null"
                                                  }
                                                ]
                                              }
                                            },
                                            "type": "object"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "withheld": {
                                        "anyOf": [
                                          {
                                            "properties": {
                                              "asset": {
                                                "type": "string"
                                              },
                                              "scale": {
                                                "type": "integer"
                                              },
                                              "units": {
                                                "anyOf": [
                                                  {
                                                    "description": "Exact decimal integer units.",
                                                    "pattern": "^-?[0-9]+$",
                                                    "type": "string"
                                                  },
                                                  {
                                                    "type": "null"
                                                  }
                                                ]
                                              }
                                            },
                                            "type": "object"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      }
                                    },
                                    "type": "object"
                                  },
                                  "determination": {
                                    "properties": {
                                      "beneficial_owner_ref": {
                                        "type": "string"
                                      },
                                      "determination_ref": {
                                        "type": "string"
                                      },
                                      "determined_by": {
                                        "type": "string"
                                      },
                                      "eligibility_ref": {
                                        "type": "string"
                                      },
                                      "method": {
                                        "type": "string"
                                      },
                                      "obligation_id": {
                                        "type": "string"
                                      },
                                      "rate": {
                                        "anyOf": [
                                          {
                                            "properties": {
                                              "scale": {
                                                "type": "integer"
                                              },
                                              "units": {
                                                "anyOf": [
                                                  {
                                                    "description": "Exact decimal integer units.",
                                                    "pattern": "^-?[0-9]+$",
                                                    "type": "string"
                                                  },
                                                  {
                                                    "type": "null"
                                                  }
                                                ]
                                              }
                                            },
                                            "type": "object"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "rate_basis": {
                                        "type": "string"
                                      },
                                      "recipient_residence": {
                                        "type": "string"
                                      },
                                      "residence_ref": {
                                        "type": "string"
                                      },
                                      "revision": {
                                        "type": "integer"
                                      },
                                      "rounding": {
                                        "type": "string"
                                      },
                                      "rule_ref": {
                                        "type": "string"
                                      },
                                      "source_jurisdiction": {
                                        "type": "string"
                                      },
                                      "tax_authority_ref": {
                                        "type": "string"
                                      },
                                      "tax_date": {
                                        "type": "string"
                                      },
                                      "tax_point": {
                                        "type": "string"
                                      },
                                      "taxable_base": {
                                        "anyOf": [
                                          {
                                            "properties": {
                                              "asset": {
                                                "type": "string"
                                              },
                                              "scale": {
                                                "type": "integer"
                                              },
                                              "units": {
                                                "anyOf": [
                                                  {
                                                    "description": "Exact decimal integer units.",
                                                    "pattern": "^-?[0-9]+$",
                                                    "type": "string"
                                                  },
                                                  {
                                                    "type": "null"
                                                  }
                                                ]
                                              }
                                            },
                                            "type": "object"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "valid_from": {
                                        "type": "string"
                                      },
                                      "valid_through": {
                                        "type": "string"
                                      }
                                    },
                                    "type": "object"
                                  },
                                  "id": {
                                    "type": "string"
                                  },
                                  "obligation": {
                                    "properties": {
                                      "correction_reason": {
                                        "type": "string"
                                      },
                                      "correction_ref": {
                                        "type": "string"
                                      },
                                      "credit_note_for": {
                                        "type": "string"
                                      },
                                      "due_date": {
                                        "type": "string"
                                      },
                                      "external_payee_ref": {
                                        "type": "string"
                                      },
                                      "first_seen": {
                                        "type": "integer"
                                      },
                                      "invoice_date": {
                                        "type": "string"
                                      },
                                      "leg": {
                                        "properties": {
                                          "amount": {
                                            "properties": {
                                              "asset": {
                                                "type": "string"
                                              },
                                              "scale": {
                                                "type": "integer"
                                              },
                                              "units": {
                                                "anyOf": [
                                                  {
                                                    "description": "Exact decimal integer units.",
                                                    "pattern": "^-?[0-9]+$",
                                                    "type": "string"
                                                  },
                                                  {
                                                    "type": "null"
                                                  }
                                                ]
                                              }
                                            },
                                            "type": "object"
                                          },
                                          "creditor": {
                                            "type": "string"
                                          },
                                          "debtor": {
                                            "type": "string"
                                          },
                                          "id": {
                                            "type": "string"
                                          },
                                          "priority": {
                                            "type": "integer"
                                          },
                                          "tax": {
                                            "anyOf": [
                                              {
                                                "properties": {
                                                  "character": {
                                                    "type": "string"
                                                  },
                                                  "character_ref": {
                                                    "type": "string"
                                                  },
                                                  "character_src": {
                                                    "type": "string"
                                                  },
                                                  "invoice_ref": {
                                                    "type": "string"
                                                  }
                                                },
                                                "type": "object"
                                              },
                                              {
                                                "type": "null"
                                              }
                                            ]
                                          }
                                        },
                                        "type": "object"
                                      },
                                      "revision": {
                                        "type": "integer"
                                      },
                                      "source": {
                                        "type": "string"
                                      },
                                      "source_id": {
                                        "type": "string"
                                      }
                                    },
                                    "type": "object"
                                  },
                                  "recorded_at": {
                                    "type": "integer"
                                  },
                                  "requester": {
                                    "description": "Hex-encoded bytes.",
                                    "pattern": "^[0-9a-f]*$",
                                    "type": "string"
                                  },
                                  "reviewer": {
                                    "description": "Hex-encoded bytes.",
                                    "pattern": "^[0-9a-f]*$",
                                    "type": "string"
                                  }
                                },
                                "type": "object"
                              },
                              "cancellation": {
                                "anyOf": [
                                  {
                                    "properties": {
                                      "accounting_date": {
                                        "type": "string"
                                      },
                                      "reason": {
                                        "type": "string"
                                      },
                                      "settlement_id": {
                                        "type": "string"
                                      },
                                      "source_ref": {
                                        "type": "string"
                                      }
                                    },
                                    "type": "object"
                                  },
                                  {
                                    "type": "null"
                                  }
                                ]
                              },
                              "cancelled_at": {
                                "type": "integer"
                              },
                              "id": {
                                "type": "string"
                              },
                              "original_payable": {
                                "properties": {
                                  "amount": {
                                    "properties": {
                                      "asset": {
                                        "type": "string"
                                      },
                                      "scale": {
                                        "type": "integer"
                                      },
                                      "units": {
                                        "anyOf": [
                                          {
                                            "description": "Exact decimal integer units.",
                                            "pattern": "^-?[0-9]+$",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      }
                                    },
                                    "type": "object"
                                  },
                                  "component": {
                                    "type": "string"
                                  },
                                  "creditor": {
                                    "type": "string"
                                  },
                                  "cycle_id": {
                                    "type": "string"
                                  },
                                  "debtor": {
                                    "type": "string"
                                  },
                                  "due_date": {
                                    "type": "string"
                                  },
                                  "id": {
                                    "type": "string"
                                  },
                                  "obligation_id": {
                                    "type": "string"
                                  },
                                  "paid": {
                                    "anyOf": [
                                      {
                                        "description": "Exact decimal integer units.",
                                        "pattern": "^-?[0-9]+$",
                                        "type": "string"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "source_asset": {
                                    "type": "string"
                                  },
                                  "withholding_settlement_id": {
                                    "type": "string"
                                  }
                                },
                                "type": "object"
                              },
                              "plan": {
                                "properties": {
                                  "accounting": {
                                    "properties": {
                                      "date": {
                                        "type": "string"
                                      },
                                      "payer_cash": {
                                        "type": "string"
                                      },
                                      "payer_gross_up_expense": {
                                        "type": "string"
                                      },
                                      "payer_payable": {
                                        "type": "string"
                                      },
                                      "payer_tax_payable": {
                                        "type": "string"
                                      },
                                      "recipient_cash": {
                                        "type": "string"
                                      },
                                      "recipient_gross_up_income": {
                                        "type": "string"
                                      },
                                      "recipient_receivable": {
                                        "type": "string"
                                      },
                                      "recipient_withheld_tax": {
                                        "type": "string"
                                      },
                                      "source_ref": {
                                        "type": "string"
                                      }
                                    },
                                    "type": "object"
                                  },
                                  "assessment_id": {
                                    "type": "string"
                                  },
                                  "debtor_account": {
                                    "properties": {
                                      "asset": {
                                        "type": "string"
                                      },
                                      "bic": {
                                        "type": "string"
                                      },
                                      "finality_class": {
                                        "type": "string"
                                      },
                                      "frame_party_id": {
                                        "description": "Hex-encoded bytes.",
                                        "pattern": "^[0-9a-f]*$",
                                        "type": "string"
                                      },
                                      "iban": {
                                        "type": "string"
                                      },
                                      "name": {
                                        "type": "string"
                                      },
                                      "other_id": {
                                        "type": "string"
                                      },
                                      "party": {
                                        "type": "string"
                                      },
                                      "rail": {
                                        "type": "string"
                                      },
                                      "source_ref": {
                                        "type": "string"
                                      }
                                    },
                                    "type": "object"
                                  },
                                  "recipient_account": {
                                    "properties": {
                                      "asset": {
                                        "type": "string"
                                      },
                                      "bic": {
                                        "type": "string"
                                      },
                                      "finality_class": {
                                        "type": "string"
                                      },
                                      "frame_party_id": {
                                        "description": "Hex-encoded bytes.",
                                        "pattern": "^[0-9a-f]*$",
                                        "type": "string"
                                      },
                                      "iban": {
                                        "type": "string"
                                      },
                                      "name": {
                                        "type": "string"
                                      },
                                      "other_id": {
                                        "type": "string"
                                      },
                                      "party": {
                                        "type": "string"
                                      },
                                      "rail": {
                                        "type": "string"
                                      },
                                      "source_ref": {
                                        "type": "string"
                                      }
                                    },
                                    "type": "object"
                                  },
                                  "recipient_due_date": {
                                    "type": "string"
                                  },
                                  "tax_authority_account": {
                                    "properties": {
                                      "asset": {
                                        "type": "string"
                                      },
                                      "bic": {
                                        "type": "string"
                                      },
                                      "finality_class": {
                                        "type": "string"
                                      },
                                      "frame_party_id": {
                                        "description": "Hex-encoded bytes.",
                                        "pattern": "^[0-9a-f]*$",
                                        "type": "string"
                                      },
                                      "iban": {
                                        "type": "string"
                                      },
                                      "name": {
                                        "type": "string"
                                      },
                                      "other_id": {
                                        "type": "string"
                                      },
                                      "party": {
                                        "type": "string"
                                      },
                                      "rail": {
                                        "type": "string"
                                      },
                                      "source_ref": {
                                        "type": "string"
                                      }
                                    },
                                    "type": "object"
                                  },
                                  "tax_due_date": {
                                    "type": "string"
                                  },
                                  "tax_payment_reference": {
                                    "type": "string"
                                  }
                                },
                                "type": "object"
                              },
                              "recipient_payable_id": {
                                "type": "string"
                              },
                              "recorded_at": {
                                "type": "integer"
                              },
                              "requester": {
                                "description": "Hex-encoded bytes.",
                                "pattern": "^[0-9a-f]*$",
                                "type": "string"
                              },
                              "reviewer": {
                                "description": "Hex-encoded bytes.",
                                "pattern": "^[0-9a-f]*$",
                                "type": "string"
                              },
                              "tax_payable_id": {
                                "type": "string"
                              }
                            },
                            "type": "object"
                          },
                          "status": {
                            "type": "string"
                          },
                          "tax": {
                            "anyOf": [
                              {
                                "properties": {
                                  "confirmations": {
                                    "anyOf": [
                                      {
                                        "items": {
                                          "properties": {
                                            "amount": {
                                              "properties": {
                                                "asset": {
                                                  "type": "string"
                                                },
                                                "scale": {
                                                  "type": "integer"
                                                },
                                                "units": {
                                                  "anyOf": [
                                                    {
                                                      "description": "Exact decimal integer units.",
                                                      "pattern": "^-?[0-9]+$",
                                                      "type": "string"
                                                    },
                                                    {
                                                      "type": "null"
                                                    }
                                                  ]
                                                }
                                              },
                                              "type": "object"
                                            },
                                            "payment_id": {
                                              "type": "string"
                                            },
                                            "reference": {
                                              "type": "string"
                                            },
                                            "reverses": {
                                              "type": "string"
                                            },
                                            "source_ref": {
                                              "type": "string"
                                            },
                                            "value_date": {
                                              "type": "string"
                                            }
                                          },
                                          "type": "object"
                                        },
                                        "type": "array"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "instructions": {
                                    "anyOf": [
                                      {
                                        "items": {
                                          "properties": {
                                            "cancellation": {
                                              "anyOf": [
                                                {
                                                  "properties": {
                                                    "payment_id": {
                                                      "type": "string"
                                                    },
                                                    "reason": {
                                                      "type": "string"
                                                    },
                                                    "source_ref": {
                                                      "type": "string"
                                                    }
                                                  },
                                                  "type": "object"
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "confirmed": {
                                              "anyOf": [
                                                {
                                                  "description": "Exact decimal integer units.",
                                                  "pattern": "^-?[0-9]+$",
                                                  "type": "string"
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "execution": {
                                              "anyOf": [
                                                {
                                                  "properties": {
                                                    "funding_hold": {
                                                      "anyOf": [
                                                        {
                                                          "properties": {
                                                            "account": {
                                                              "type": "string"
                                                            },
                                                            "amount": {
                                                              "properties": {
                                                                "asset": {
                                                                  "type": "string"
                                                                },
                                                                "scale": {
                                                                  "type": "integer"
                                                                },
                                                                "units": {
                                                                  "anyOf": [
                                                                    {
                                                                      "description": "Exact decimal integer units.",
                                                                      "pattern": "^-?[0-9]+$",
                                                                      "type": "string"
                                                                    },
                                                                    {
                                                                      "type": "null"
                                                                    }
                                                                  ]
                                                                }
                                                              },
                                                              "type": "object"
                                                            },
                                                            "bank_request_id": {
                                                              "type": "string"
                                                            },
                                                            "expiry": {
                                                              "type": "integer"
                                                            },
                                                            "hold_id": {
                                                              "description": "Hex-encoded bytes.",
                                                              "pattern": "^[0-9a-f]*$",
                                                              "type": "string"
                                                            },
                                                            "obligor": {
                                                              "anyOf": [
                                                                {
                                                                  "description": "Hex-encoded bytes.",
                                                                  "pattern": "^[0-9a-f]*$",
                                                                  "type": "string"
                                                                },
                                                                {
                                                                  "type": "null"
                                                                }
                                                              ]
                                                            },
                                                            "sig": {
                                                              "description": "Hex-encoded bytes.",
                                                              "pattern": "^[0-9a-f]*$",
                                                              "type": "string"
                                                            }
                                                          },
                                                          "type": "object"
                                                        },
                                                        {
                                                          "type": "null"
                                                        }
                                                      ]
                                                    },
                                                    "funding_ref": {
                                                      "type": "string"
                                                    },
                                                    "instruction": {
                                                      "anyOf": [
                                                        {
                                                          "properties": {
                                                            "atomicity": {
                                                              "type": "string"
                                                            },
                                                            "bank_request_id": {
                                                              "type": "string"
                                                            },
                                                            "conversion_leaf_ref": {
                                                              "anyOf": [
                                                                {
                                                                  "description": "Hex-encoded bytes.",
                                                                  "pattern": "^[0-9a-f]*$",
                                                                  "type": "string"
                                                                },
                                                                {
                                                                  "type": "null"
                                                                }
                                                              ]
                                                            },
                                                            "cycle_id": {
                                                              "type": "string"
                                                            },
                                                            "cycle_leaf_ref": {
                                                              "anyOf": [
                                                                {
                                                                  "description": "Hex-encoded bytes.",
                                                                  "pattern": "^[0-9a-f]*$",
                                                                  "type": "string"
                                                                },
                                                                {
                                                                  "type": "null"
                                                                }
                                                              ]
                                                            },
                                                            "invoice_ref": {
                                                              "type": "string"
                                                            },
                                                            "legs": {
                                                              "anyOf": [
                                                                {
                                                                  "items": {
                                                                    "properties": {
                                                                      "amount": {
                                                                        "properties": {
                                                                          "asset": {
                                                                            "type": "string"
                                                                          },
                                                                          "scale": {
                                                                            "type": "integer"
                                                                          },
                                                                          "units": {
                                                                            "anyOf": [
                                                                              {
                                                                                "description": "Exact decimal integer units.",
                                                                                "pattern": "^-?[0-9]+$",
                                                                                "type": "string"
                                                                              },
                                                                              {
                                                                                "type": "null"
                                                                              }
                                                                            ]
                                                                          }
                                                                        },
                                                                        "type": "object"
                                                                      },
                                                                      "detail": {
                                                                        "anyOf": [
                                                                          {
                                                                            "properties": {
                                                                              "account": {
                                                                                "type": "string"
                                                                              },
                                                                              "counterparty": {
                                                                                "type": "string"
                                                                              },
                                                                              "rail": {
                                                                                "type": "string"
                                                                              },
                                                                              "recipient_account": {
                                                                                "type": "string"
                                                                              },
                                                                              "token": {
                                                                                "type": "string"
                                                                              },
                                                                              "token_chain_id": {
                                                                                "type": "integer"
                                                                              },
                                                                              "token_symbol": {
                                                                                "type": "string"
                                                                              },
                                                                              "venue": {
                                                                                "type": "string"
                                                                              }
                                                                            },
                                                                            "type": "object"
                                                                          },
                                                                          {
                                                                            "type": "null"
                                                                          }
                                                                        ]
                                                                      },
                                                                      "finality_class": {
                                                                        "type": "string"
                                                                      },
                                                                      "form": {
                                                                        "type": "string"
                                                                      },
                                                                      "id": {
                                                                        "description": "Hex-encoded bytes.",
                                                                        "pattern": "^[0-9a-f]*$",
                                                                        "type": "string"
                                                                      },
                                                                      "locked_rate": {
                                                                        "anyOf": [
                                                                          {
                                                                            "properties": {
                                                                              "scale": {
                                                                                "type": "integer"
                                                                              },
                                                                              "units": {
                                                                                "anyOf": [
                                                                                  {
                                                                                    "description": "Exact decimal integer units.",
                                                                                    "pattern": "^-?[0-9]+$",
                                                                                    "type": "string"
                                                                                  },
                                                                                  {
                                                                                    "type": "null"
                                                                                  }
                                                                                ]
                                                                              }
                                                                            },
                                                                            "type": "object"
                                                                          },
                                                                          {
                                                                            "type": "null"
                                                                          }
                                                                        ]
                                                                      },
                                                                      "obligor": {
                                                                        "description": "Hex-encoded bytes.",
                                                                        "pattern": "^[0-9a-f]*$",
                                                                        "type": "string"
                                                                      },
                                                                      "rate_source": {
                                                                        "type": "string"
                                                                      },
                                                                      "role": {
                                                                        "type": "string"
                                                                      },
                                                                      "seq": {
                                                                        "type": "integer"
                                                                      }
                                                                    },
                                                                    "type": "object"
                                                                  },
                                                                  "type": "array"
                                                                },
                                                                {
                                                                  "type": "null"
                                                                }
                                                              ]
                                                            },
                                                            "settlement_kind": {
                                                              "type": "string"
                                                            },
                                                            "tenant": {
                                                              "description": "Hex-encoded bytes.",
                                                              "pattern": "^[0-9a-f]*$",
                                                              "type": "string"
                                                            }
                                                          },
                                                          "type": "object"
                                                        },
                                                        {
                                                          "type": "null"
                                                        }
                                                      ]
                                                    },
                                                    "payment_id": {
                                                      "type": "string"
                                                    },
                                                    "route": {
                                                      "type": "string"
                                                    },
                                                    "settlement_id": {
                                                      "anyOf": [
                                                        {
                                                          "description": "Hex-encoded bytes.",
                                                          "pattern": "^[0-9a-f]*$",
                                                          "type": "string"
                                                        },
                                                        {
                                                          "type": "null"
                                                        }
                                                      ]
                                                    }
                                                  },
                                                  "type": "object"
                                                },
                                                {
                                                  "type": "null"
                                                }
                                              ]
                                            },
                                            "execution_at": {
                                              "type": "integer"
                                            },
                                            "instruction": {
                                              "properties": {
                                                "amount": {
                                                  "properties": {
                                                    "asset": {
                                                      "type": "string"
                                                    },
                                                    "scale": {
                                                      "type": "integer"
                                                    },
                                                    "units": {
                                                      "anyOf": [
                                                        {
                                                          "description": "Exact decimal integer units.",
                                                          "pattern": "^-?[0-9]+$",
                                                          "type": "string"
                                                        },
                                                        {
                                                          "type": "null"
                                                        }
                                                      ]
                                                    }
                                                  },
                                                  "type": "object"
                                                },
                                                "creditor_account": {
                                                  "properties": {
                                                    "asset": {
                                                      "type": "string"
                                                    },
                                                    "bic": {
                                                      "type": "string"
                                                    },
                                                    "finality_class": {
                                                      "type": "string"
                                                    },
                                                    "frame_party_id": {
                                                      "description": "Hex-encoded bytes.",
                                                      "pattern": "^[0-9a-f]*$",
                                                      "type": "string"
                                                    },
                                                    "iban": {
                                                      "type": "string"
                                                    },
                                                    "name": {
                                                      "type": "string"
                                                    },
                                                    "other_id": {
                                                      "type": "string"
                                                    },
                                                    "party": {
                                                      "type": "string"
                                                    },
                                                    "rail": {
                                                      "type": "string"
                                                    },
                                                    "source_ref": {
                                                      "type": "string"
                                                    }
                                                  },
                                                  "type": "object"
                                                },
                                                "debtor_account": {
                                                  "properties": {
                                                    "asset": {
                                                      "type": "string"
                                                    },
                                                    "bic": {
                                                      "type": "string"
                                                    },
                                                    "finality_class": {
                                                      "type": "string"
                                                    },
                                                    "frame_party_id": {
                                                      "description": "Hex-encoded bytes.",
                                                      "pattern": "^[0-9a-f]*$",
                                                      "type": "string"
                                                    },
                                                    "iban": {
                                                      "type": "string"
                                                    },
                                                    "name": {
                                                      "type": "string"
                                                    },
                                                    "other_id": {
                                                      "type": "string"
                                                    },
                                                    "party": {
                                                      "type": "string"
                                                    },
                                                    "rail": {
                                                      "type": "string"
                                                    },
                                                    "source_ref": {
                                                      "type": "string"
                                                    }
                                                  },
                                                  "type": "object"
                                                },
                                                "execution_date": {
                                                  "type": "string"
                                                },
                                                "id": {
                                                  "type": "string"
                                                },
                                                "payable_id": {
                                                  "type": "string"
                                                }
                                              },
                                              "type": "object"
                                            },
                                            "route": {
                                              "type": "string"
                                            }
                                          },
                                          "type": "object"
                                        },
                                        "type": "array"
                                      },
                                      {
                                        "type": "null"
                                      }
                                    ]
                                  },
                                  "payable": {
                                    "properties": {
                                      "amount": {
                                        "properties": {
                                          "asset": {
                                            "type": "string"
                                          },
                                          "scale": {
                                            "type": "integer"
                                          },
                                          "units": {
                                            "anyOf": [
                                              {
                                                "description": "Exact decimal integer units.",
                                                "pattern": "^-?[0-9]+$",
                                                "type": "string"
                                              },
                                              {
                                                "type": "null"
                                              }
                                            ]
                                          }
                                        },
                                        "type": "object"
                                      },
                                      "component": {
                                        "type": "string"
                                      },
                                      "creditor": {
                                        "type": "string"
                                      },
                                      "cycle_id": {
                                        "type": "string"
                                      },
                                      "debtor": {
                                        "type": "string"
                                      },
                                      "due_date": {
                                        "type": "string"
                                      },
                                      "id": {
                                        "type": "string"
                                      },
                                      "obligation_id": {
                                        "type": "string"
                                      },
                                      "paid": {
                                        "anyOf": [
                                          {
                                            "description": "Exact decimal integer units.",
                                            "pattern": "^-?[0-9]+$",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      },
                                      "source_asset": {
                                        "type": "string"
                                      },
                                      "withholding_settlement_id": {
                                        "type": "string"
                                      }
                                    },
                                    "type": "object"
                                  },
                                  "remaining": {
                                    "properties": {
                                      "asset": {
                                        "type": "string"
                                      },
                                      "scale": {
                                        "type": "integer"
                                      },
                                      "units": {
                                        "anyOf": [
                                          {
                                            "description": "Exact decimal integer units.",
                                            "pattern": "^-?[0-9]+$",
                                            "type": "string"
                                          },
                                          {
                                            "type": "null"
                                          }
                                        ]
                                      }
                                    },
                                    "type": "object"
                                  }
                                },
                                "type": "object"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          },
                          "tax_date_review_required": {
                            "type": "boolean"
                          }
                        },
                        "type": "object"
                      },
                      "type": "array"
                    },
                    {
                      "type": "null"
                    }
                  ]
                }
              },
              "type": "object"
            },
            "withholding_reviews": {
              "items": {
                "properties": {
                  "assessment_id": {
                    "type": "string"
                  },
                  "can_close": {
                    "type": "boolean"
                  },
                  "facts_hash": {
                    "description": "Hex-encoded bytes.",
                    "pattern": "^[0-9a-f]*$",
                    "type": "string"
                  },
                  "history": {
                    "anyOf": [
                      {
                        "items": {
                          "properties": {
                            "declaration": {
                              "properties": {
                                "assessment_id": {
                                  "type": "string"
                                },
                                "decision": {
                                  "type": "string"
                                },
                                "facts_hash": {
                                  "description": "Hex-encoded bytes.",
                                  "pattern": "^[0-9a-f]*$",
                                  "type": "string"
                                },
                                "follow_up_date": {
                                  "type": "string"
                                },
                                "owner": {
                                  "type": "string"
                                },
                                "reason": {
                                  "type": "string"
                                },
                                "settlement_id": {
                                  "type": "string"
                                },
                                "source_ref": {
                                  "type": "string"
                                }
                              },
                              "type": "object"
                            },
                            "id": {
                              "type": "string"
                            },
                            "recorded_at": {
                              "type": "integer"
                            },
                            "requester": {
                              "description": "Hex-encoded bytes.",
                              "pattern": "^[0-9a-f]*$",
                              "type": "string"
                            },
                            "reviewer": {
                              "description": "Hex-encoded bytes.",
                              "pattern": "^[0-9a-f]*$",
                              "type": "string"
                            }
                          },
                          "type": "object"
                        },
                        "type": "array"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "obligation_id": {
                    "type": "string"
                  },
                  "reasons": {
                    "anyOf": [
                      {
                        "items": {
                          "type": "string"
                        },
                        "type": "array"
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "settlement_id": {
                    "type": "string"
                  },
                  "status": {
                    "type": "string"
                  }
                },
                "type": "object"
              },
              "type": "array"
            }
          },
          "required": [
            "report",
            "journal",
            "journal_date_basis",
            "withholding_reviews"
          ],
          "type": "object"
        }
      },
      "text/csv": {
        "schema": {
          "description": "CSV attachment selected by csv query parameter.",
          "type": "string"
        }
      }
    },
    "description": "Successful response. Query a treasury report or CSV export."
  },
  "400": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Invalid request, malformed identifier, or unmet input requirement."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  },
  "404": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Resource not found in the caller scope."
  },
  "409": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "State conflict; inspect the error before retrying."
  }
}
curl --fail-with-body -sS "$FRAME_URL/v1/treasury/report?group_id=${FRAME_GROUP_ID}" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT"

GET /v1/treasury/tax-worklist

Query tax review work or export CSV

Bank session · read capability

Verifies each selected group before reporting current balances against review_date. This is not an as-of ledger query. Unknown query parameters and csv values other than 1 return 400. Omit group_id to aggregate the tenant groups.

Parameters

NameTypeDescription
tenantquery · stringOptional explicit tenant UUID; membership checked. Defaults to active tenant.
group_idquery · stringOptional group; absent selects all tenant groups.
review_date
required
query · stringRequired YYYY-MM-DD comparison date for review scheduling.
csvquery · stringSet to 1 for CSV; omit for JSON.
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.
Responses
{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "properties": {
            "checkpoints": {
              "anyOf": [
                {
                  "items": {
                    "properties": {
                      "group_id": {
                        "type": "string"
                      },
                      "head": {
                        "description": "Hex-encoded bytes.",
                        "pattern": "^[0-9a-f]*$",
                        "type": "string"
                      },
                      "recorded_at": {
                        "type": "integer"
                      },
                      "timezone": {
                        "type": "string"
                      }
                    },
                    "type": "object"
                  },
                  "type": "array"
                },
                {
                  "type": "null"
                }
              ]
            },
            "exceptions": {
              "anyOf": [
                {
                  "items": {
                    "properties": {
                      "assessment_id": {
                        "type": "string"
                      },
                      "debtor": {
                        "type": "string"
                      },
                      "follow_up_date": {
                        "type": "string"
                      },
                      "group_id": {
                        "type": "string"
                      },
                      "next_action": {
                        "type": "string"
                      },
                      "obligation_id": {
                        "type": "string"
                      },
                      "owner": {
                        "type": "string"
                      },
                      "reason": {
                        "type": "string"
                      },
                      "review_id": {
                        "type": "string"
                      },
                      "settlement_id": {
                        "type": "string"
                      }
                    },
                    "type": "object"
                  },
                  "type": "array"
                },
                {
                  "type": "null"
                }
              ]
            },
            "payments": {
              "anyOf": [
                {
                  "items": {
                    "properties": {
                      "alerts": {
                        "anyOf": [
                          {
                            "items": {
                              "type": "string"
                            },
                            "type": "array"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "assessment_id": {
                        "type": "string"
                      },
                      "authority": {
                        "type": "string"
                      },
                      "debtor": {
                        "type": "string"
                      },
                      "due_date": {
                        "type": "string"
                      },
                      "due_status": {
                        "type": "string"
                      },
                      "group_id": {
                        "type": "string"
                      },
                      "next_action": {
                        "type": "string"
                      },
                      "obligation_id": {
                        "type": "string"
                      },
                      "paid": {
                        "properties": {
                          "asset": {
                            "type": "string"
                          },
                          "scale": {
                            "type": "integer"
                          },
                          "units": {
                            "anyOf": [
                              {
                                "description": "Exact decimal integer units.",
                                "pattern": "^-?[0-9]+$",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "type": "object"
                      },
                      "payment_ids": {
                        "anyOf": [
                          {
                            "items": {
                              "type": "string"
                            },
                            "type": "array"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "recipient": {
                        "type": "string"
                      },
                      "remaining": {
                        "properties": {
                          "asset": {
                            "type": "string"
                          },
                          "scale": {
                            "type": "integer"
                          },
                          "units": {
                            "anyOf": [
                              {
                                "description": "Exact decimal integer units.",
                                "pattern": "^-?[0-9]+$",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "type": "object"
                      },
                      "review_follow_up_date": {
                        "type": "string"
                      },
                      "review_id": {
                        "type": "string"
                      },
                      "review_owner": {
                        "type": "string"
                      },
                      "review_status": {
                        "type": "string"
                      },
                      "settlement_id": {
                        "type": "string"
                      },
                      "tax": {
                        "properties": {
                          "asset": {
                            "type": "string"
                          },
                          "scale": {
                            "type": "integer"
                          },
                          "units": {
                            "anyOf": [
                              {
                                "description": "Exact decimal integer units.",
                                "pattern": "^-?[0-9]+$",
                                "type": "string"
                              },
                              {
                                "type": "null"
                              }
                            ]
                          }
                        },
                        "type": "object"
                      },
                      "tax_payment_reference": {
                        "type": "string"
                      }
                    },
                    "type": "object"
                  },
                  "type": "array"
                },
                {
                  "type": "null"
                }
              ]
            },
            "review_date": {
              "type": "string"
            },
            "totals": {
              "anyOf": [
                {
                  "items": {
                    "properties": {
                      "asset": {
                        "type": "string"
                      },
                      "due_today": {
                        "anyOf": [
                          {
                            "description": "Exact decimal integer units.",
                            "pattern": "^-?[0-9]+$",
                            "type": "string"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "later": {
                        "anyOf": [
                          {
                            "description": "Exact decimal integer units.",
                            "pattern": "^-?[0-9]+$",
                            "type": "string"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "next_seven_days": {
                        "anyOf": [
                          {
                            "description": "Exact decimal integer units.",
                            "pattern": "^-?[0-9]+$",
                            "type": "string"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "outstanding": {
                        "anyOf": [
                          {
                            "description": "Exact decimal integer units.",
                            "pattern": "^-?[0-9]+$",
                            "type": "string"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "overdue": {
                        "anyOf": [
                          {
                            "description": "Exact decimal integer units.",
                            "pattern": "^-?[0-9]+$",
                            "type": "string"
                          },
                          {
                            "type": "null"
                          }
                        ]
                      },
                      "scale": {
                        "type": "integer"
                      }
                    },
                    "type": "object"
                  },
                  "type": "array"
                },
                {
                  "type": "null"
                }
              ]
            }
          },
          "type": "object"
        }
      },
      "text/csv": {
        "schema": {
          "type": "string"
        }
      }
    },
    "description": "Successful response. Query tax review work or export CSV."
  },
  "400": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Invalid request, malformed identifier, or unmet input requirement."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  },
  "404": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Resource not found in the caller scope."
  },
  "409": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "State conflict; inspect the error before retrying."
  },
  "500": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Internal failure."
  }
}
curl --fail-with-body -sS "$FRAME_URL/v1/treasury/tax-worklist?review_date=${FRAME_REVIEW_DATE}" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT"

Settlements

POST /settlements/{id}/confirm

Confirm a leg after finality

Bank session · settle capability

Requires settle capability. For observed rails, a corresponding sealed rail fact must exist. A non-confirmable leg or missing observed finality returns 409. This endpoint does not replace a bank or rail finality attestation.

Parameters

NameTypeDescription
id
required
path · stringResource identifier from the corresponding response.
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.

JSON request fields

FieldTypeDescription
leg_id
required
stringUUID of the leg being confirmed. Observed rails require sealed finality evidence before this call can succeed.
Request body
{
  "content": {
    "application/json": {
      "schema": {
        "properties": {
          "leg_id": {
            "description": "UUID of the leg being confirmed. Observed rails require sealed finality evidence before this call can succeed.",
            "type": "string"
          }
        },
        "required": [
          "leg_id"
        ],
        "type": "object"
      }
    }
  },
  "required": true
}
Responses
{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "properties": {
            "atomicity": {
              "type": "string"
            },
            "bank_request_id": {
              "type": "string"
            },
            "id": {
              "type": "string"
            },
            "invoice_ref": {
              "type": "string"
            },
            "legs": {
              "items": {
                "properties": {
                  "amount": {
                    "properties": {
                      "asset": {
                        "description": "Asset or currency identifier understood by the installed policy and rail.",
                        "examples": [
                          "USD"
                        ],
                        "type": "string"
                      },
                      "scale": {
                        "description": "Decimal exponent. USD minor units conventionally use 2.",
                        "maximum": 255,
                        "minimum": 0,
                        "type": "integer"
                      },
                      "units": {
                        "description": "Exact integer minor units as a decimal string; never a JSON floating-point amount.",
                        "examples": [
                          "12345"
                        ],
                        "pattern": "^-?[0-9]+$",
                        "type": "string"
                      }
                    },
                    "required": [
                      "asset",
                      "scale",
                      "units"
                    ],
                    "type": "object"
                  },
                  "finality_class": {
                    "type": "string"
                  },
                  "form": {
                    "type": "string"
                  },
                  "id": {
                    "type": "string"
                  },
                  "obligor": {
                    "type": "string"
                  },
                  "role": {
                    "type": "string"
                  },
                  "status": {
                    "type": "string"
                  },
                  "token": {
                    "type": "string"
                  },
                  "token_chain_id": {
                    "type": "integer"
                  },
                  "token_symbol": {
                    "type": "string"
                  },
                  "wave": {
                    "type": "integer"
                  }
                },
                "type": "object"
              },
              "type": "array"
            },
            "settlement_kind": {
              "type": "string"
            },
            "status": {
              "description": "Persisted saga status. HTTP success does not imply settlement success.",
              "enum": [
                "accepted",
                "authorised",
                "sealed",
                "dispatched",
                "confirmed",
                "denied",
                "reversed",
                "stuck",
                "resolved_manual"
              ],
              "type": "string"
            },
            "stuck_deadline_ms": {
              "type": "integer"
            },
            "tenant": {
              "type": "string"
            }
          },
          "required": [
            "id",
            "tenant",
            "bank_request_id",
            "settlement_kind",
            "status",
            "legs"
          ],
          "type": "object"
        }
      }
    },
    "description": "Successful response. Read the returned settlement status; this is not a guarantee of completed value movement."
  },
  "400": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Invalid request, malformed identifier, or unmet input requirement."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  },
  "404": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Resource not found in the caller scope."
  },
  "409": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "State conflict; inspect the error before retrying."
  },
  "500": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Internal failure."
  }
}
curl --fail-with-body -sS -X POST "$FRAME_URL/settlements/${FRAME_ID}/confirm" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT" \
  -H 'Content-Type: application/json' --data-binary @request.json

GET /settlements/{id}/pack

Download settlement verification evidence

Bank session · read capability

Returns a binary CBOR verify-pack for either a sealed authorization or a sealed denial. 409 means not sealed yet (Retry-After: 1); 410 means admission rejection with no sealed verdict ever available. Verify trust and attestation against independent pins. Anchor reference strings alone do not establish finality.

Parameters

NameTypeDescription
id
required
path · stringResource identifier from the corresponding response.
anchor_txquery · stringOptional anchor reference bytes carried in the pack. Supplying a value does not prove chain finality; omission uses a development reference.
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.
Responses
{
  "200": {
    "content": {
      "application/cbor": {
        "schema": {
          "description": "Binary Frame verify-pack. Save the bytes; do not JSON-decode.",
          "format": "binary",
          "type": "string"
        }
      }
    },
    "description": "Successful response. Download settlement verification evidence."
  },
  "400": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Invalid request, malformed identifier, or unmet input requirement."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  },
  "404": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Resource not found in the caller scope."
  },
  "409": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "State conflict; inspect the error before retrying.",
    "headers": {
      "Retry-After": {
        "description": "Seconds before another evidence request.",
        "schema": {
          "const": 1,
          "type": "integer"
        }
      }
    }
  },
  "410": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "No sealed verdict can exist for this admission-rejected settlement."
  },
  "500": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Internal failure."
  }
}
curl --fail-with-body -sS "$FRAME_URL/settlements/${FRAME_ID}/pack" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT" --output evidence.cbor

GET /settlements/{id}/railobs

Read corroborating rail observations

Bank session · read capability

Returns settlement and observations, including source URL, peer certificate fingerprint, observation time and trust class. Observations are not themselves settlement authorization.

Parameters

NameTypeDescription
id
required
path · stringResource identifier from the corresponding response.
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.
Responses
{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "properties": {
            "observations": {
              "items": {
                "properties": {
                  "observation_id": {
                    "type": "string"
                  },
                  "observed_at_ms": {
                    "type": "integer"
                  },
                  "peer_spki_sha256": {
                    "type": "string"
                  },
                  "source_url": {
                    "type": "string"
                  },
                  "trust_class": {
                    "type": "string"
                  }
                },
                "type": "object"
              },
              "type": "array"
            },
            "settlement": {
              "type": "string"
            }
          },
          "type": "object"
        }
      }
    },
    "description": "Successful response. Read corroborating rail observations."
  },
  "400": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Invalid request, malformed identifier, or unmet input requirement."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  },
  "404": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Resource not found in the caller scope."
  }
}
curl --fail-with-body -sS "$FRAME_URL/settlements/${FRAME_ID}/railobs" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT"

GET /settlements/{id}

Read authoritative settlement status

Bank session · read capability

Returns the core status and leg progress for a known ID. Resources outside the active tenant are hidden as not found. Track IDs from submission; the recent-settlement listing is bounded.

Parameters

NameTypeDescription
id
required
path · stringResource identifier from the corresponding response.
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.
Responses
{
  "200": {
    "content": {
      "application/json": {
        "example": {
          "bank_request_id": "bank-payment-20260928-001",
          "id": "00000000-0000-0000-0000-0000000000a1",
          "legs": [
            {
              "amount": {
                "asset": "USD",
                "scale": 2,
                "units": "12345"
              },
              "finality_class": "instant",
              "form": "fiat",
              "id": "00000000-0000-0000-0000-0000000000b1",
              "obligor": "",
              "role": "source",
              "status": "pending",
              "wave": 0
            },
            {
              "amount": {
                "asset": "USD",
                "scale": 2,
                "units": "12345"
              },
              "finality_class": "instant",
              "form": "fiat",
              "id": "00000000-0000-0000-0000-0000000000b2",
              "obligor": "",
              "role": "destination",
              "status": "pending",
              "wave": 1
            }
          ],
          "settlement_kind": "payment",
          "status": "denied",
          "tenant": "00000000-0000-0000-0000-000000000101"
        },
        "schema": {
          "properties": {
            "atomicity": {
              "type": "string"
            },
            "bank_request_id": {
              "type": "string"
            },
            "id": {
              "type": "string"
            },
            "invoice_ref": {
              "type": "string"
            },
            "legs": {
              "items": {
                "properties": {
                  "amount": {
                    "properties": {
                      "asset": {
                        "description": "Asset or currency identifier understood by the installed policy and rail.",
                        "examples": [
                          "USD"
                        ],
                        "type": "string"
                      },
                      "scale": {
                        "description": "Decimal exponent. USD minor units conventionally use 2.",
                        "maximum": 255,
                        "minimum": 0,
                        "type": "integer"
                      },
                      "units": {
                        "description": "Exact integer minor units as a decimal string; never a JSON floating-point amount.",
                        "examples": [
                          "12345"
                        ],
                        "pattern": "^-?[0-9]+$",
                        "type": "string"
                      }
                    },
                    "required": [
                      "asset",
                      "scale",
                      "units"
                    ],
                    "type": "object"
                  },
                  "finality_class": {
                    "type": "string"
                  },
                  "form": {
                    "type": "string"
                  },
                  "id": {
                    "type": "string"
                  },
                  "obligor": {
                    "type": "string"
                  },
                  "role": {
                    "type": "string"
                  },
                  "status": {
                    "type": "string"
                  },
                  "token": {
                    "type": "string"
                  },
                  "token_chain_id": {
                    "type": "integer"
                  },
                  "token_symbol": {
                    "type": "string"
                  },
                  "wave": {
                    "type": "integer"
                  }
                },
                "type": "object"
              },
              "type": "array"
            },
            "settlement_kind": {
              "type": "string"
            },
            "status": {
              "description": "Persisted saga status. HTTP success does not imply settlement success.",
              "enum": [
                "accepted",
                "authorised",
                "sealed",
                "dispatched",
                "confirmed",
                "denied",
                "reversed",
                "stuck",
                "resolved_manual"
              ],
              "type": "string"
            },
            "stuck_deadline_ms": {
              "type": "integer"
            },
            "tenant": {
              "type": "string"
            }
          },
          "required": [
            "id",
            "tenant",
            "bank_request_id",
            "settlement_kind",
            "status",
            "legs"
          ],
          "type": "object"
        }
      }
    },
    "description": "Successful response. Read the returned settlement status; this is not a guarantee of completed value movement."
  },
  "400": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Invalid request, malformed identifier, or unmet input requirement."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  },
  "404": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Resource not found in the caller scope."
  },
  "500": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Internal failure."
  }
}
curl --fail-with-body -sS "$FRAME_URL/settlements/${FRAME_ID}" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT"

POST /settlements

Submit a settlement instruction

Bank session · settle capability

Requires an ACTIVE policy. Intake is exactly-once for (tenant, bank_request_id). On timeout retry the identical instruction with the same explicit tenant and request ID. The response is the current settlement record after running the saga. A denied record can return HTTP 200. Pre-intake validation failures may return only an error, with no settlement ID or sealed verdict.

Parameters

NameTypeDescription
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.

JSON request fields

FieldTypeDescription
atomicitystringDeclared atomicity requirement, evaluated against the available settlement mechanism.
bank_request_id
required
stringBank-assigned stable instruction ID. Exactly-once intake key together with tenant. Reuse for a retry of the same instruction. The treasury/v2/ prefix is reserved.
inputsarrayAttested facts required by the installed policy and configured trust roots. A valid JSON shape is not sufficient: signatures and binding to this instruction are checked.
invoice_refstringOptional bank-side invoice or receivable reference.
legs
required
arrayOrdered movement legs. Waves must satisfy the declared form and reversibility constraints.
party_refstringRegistered customer reference used to join signed compliance inputs. It must name a party in this instruction.
settlement_kindstringDeclared kind, checked against the leg shape. Omit to use the server inference.
tenantstringBank tenant UUID. Send explicitly on every submission and retry; it must be an authorized tenant.
Request body
{
  "content": {
    "application/json": {
      "schema": {
        "description": "Wire-format example only: replace identifiers and supply the real attested inputs required by your policy and rail. The empty inputs array is not a recipe for an authorized bank payment.",
        "examples": [
          {
            "bank_request_id": "bank-payment-20260928-001",
            "inputs": [],
            "legs": [
              {
                "amount": {
                  "asset": "USD",
                  "scale": 2,
                  "units": "12345"
                },
                "detail": {
                  "account": "BANK-USD-OPERATING"
                },
                "form": "fiat",
                "role": "source",
                "seq": 0
              },
              {
                "amount": {
                  "asset": "USD",
                  "scale": 2,
                  "units": "12345"
                },
                "detail": {
                  "counterparty": "REGISTERED-PAYEE"
                },
                "form": "fiat",
                "role": "destination",
                "seq": 1
              }
            ],
            "tenant": "00000000000000000000000000000101"
          }
        ],
        "properties": {
          "atomicity": {
            "description": "Declared atomicity requirement, evaluated against the available settlement mechanism.",
            "type": "string"
          },
          "bank_request_id": {
            "description": "Bank-assigned stable instruction ID. Exactly-once intake key together with tenant. Reuse for a retry of the same instruction. The treasury/v2/ prefix is reserved.",
            "type": "string"
          },
          "inputs": {
            "description": "Attested facts required by the installed policy and configured trust roots. A valid JSON shape is not sufficient: signatures and binding to this instruction are checked.",
            "items": {
              "properties": {
                "account": {
                  "type": "string"
                },
                "amount": {
                  "properties": {
                    "asset": {
                      "type": "string"
                    },
                    "scale": {
                      "type": "integer"
                    },
                    "units": {
                      "type": "string"
                    }
                  },
                  "type": "object"
                },
                "approver": {
                  "type": "string"
                },
                "as_of": {
                  "description": "Rate or screening observation time in Unix milliseconds.",
                  "type": "integer"
                },
                "bank_request_id": {
                  "description": "Funds input request ID; must bind to the source leg reservation as required by the hold protocol.",
                  "type": "string"
                },
                "base": {
                  "type": "string"
                },
                "clear": {
                  "type": "boolean"
                },
                "expiry": {
                  "description": "Funds fact expiry in Unix milliseconds.",
                  "type": "integer"
                },
                "hold_id": {
                  "type": "string"
                },
                "kind": {
                  "description": "Fact kind: screening, clock, approval, funds, rate, or kyc. Fields are conditional on kind.",
                  "type": "string"
                },
                "level": {
                  "type": "string"
                },
                "now": {
                  "type": "integer"
                },
                "obligor": {
                  "description": "Party UUID for a funds hold. Required when the instruction has multiple obligors.",
                  "type": "string"
                },
                "quote": {
                  "type": "string"
                },
                "rate": {
                  "properties": {
                    "scale": {
                      "type": "integer"
                    },
                    "units": {
                      "type": "string"
                    }
                  },
                  "type": "object"
                },
                "rate_source": {
                  "type": "string"
                },
                "sig": {
                  "description": "Externally produced Ed25519 signature, 64 bytes as hex. Required when the configured trust root requires an external attester. Never copy development self-attestation into a bank integration.",
                  "type": "string"
                },
                "subject": {
                  "description": "Party reference bound by a screening or KYC fact.",
                  "type": "string"
                },
                "tenant": {
                  "description": "Tenant bound by an externally signed screening or KYC fact.",
                  "type": "string"
                },
                "verified": {
                  "type": "boolean"
                }
              },
              "type": "object"
            },
            "type": "array"
          },
          "invoice_ref": {
            "description": "Optional bank-side invoice or receivable reference.",
            "type": "string"
          },
          "legs": {
            "description": "Ordered movement legs. Waves must satisfy the declared form and reversibility constraints.",
            "items": {
              "properties": {
                "amount": {
                  "properties": {
                    "asset": {
                      "description": "Asset or currency identifier understood by the installed policy and rail.",
                      "examples": [
                        "USD"
                      ],
                      "type": "string"
                    },
                    "scale": {
                      "description": "Decimal exponent. USD minor units conventionally use 2.",
                      "maximum": 255,
                      "minimum": 0,
                      "type": "integer"
                    },
                    "units": {
                      "description": "Exact integer minor units as a decimal string; never a JSON floating-point amount.",
                      "examples": [
                        "12345"
                      ],
                      "pattern": "^-?[0-9]+$",
                      "type": "string"
                    }
                  },
                  "required": [
                    "asset",
                    "scale",
                    "units"
                  ],
                  "type": "object"
                },
                "detail": {
                  "properties": {
                    "account": {
                      "type": "string"
                    },
                    "counterparty": {
                      "type": "string"
                    },
                    "rail": {
                      "type": "string"
                    },
                    "recipient_account": {
                      "type": "string"
                    },
                    "venue": {
                      "type": "string"
                    }
                  },
                  "type": "object"
                },
                "finality_class": {
                  "description": "Finality classification checked by the intake floor.",
                  "type": "string"
                },
                "form": {
                  "description": "Settlement form supported by the configured rail and policy.",
                  "type": "string"
                },
                "id": {
                  "description": "Optional leg UUID. When omitted, deterministically derived from tenant, bank_request_id and leg index.",
                  "type": "string"
                },
                "locked_rate": {
                  "description": "Required locked conversion rate on cross-asset destination legs. Exact decimal integer units at scale.",
                  "properties": {
                    "scale": {
                      "type": "integer"
                    },
                    "units": {
                      "type": "string"
                    }
                  },
                  "type": "object"
                },
                "obligor": {
                  "description": "Party UUID whose obligation this leg represents. Required where the declared settlement shape needs it.",
                  "type": "string"
                },
                "rate_source": {
                  "description": "Must match the signed rate input used for this leg.",
                  "type": "string"
                },
                "role": {
                  "description": "Leg role: source, destination, or residual.",
                  "type": "string"
                },
                "seq": {
                  "description": "Wave index. Lower waves fire before higher waves.",
                  "type": "integer"
                }
              },
              "required": [
                "role",
                "form",
                "amount"
              ],
              "type": "object"
            },
            "type": "array"
          },
          "party_ref": {
            "description": "Registered customer reference used to join signed compliance inputs. It must name a party in this instruction.",
            "type": "string"
          },
          "settlement_kind": {
            "description": "Declared kind, checked against the leg shape. Omit to use the server inference.",
            "type": "string"
          },
          "tenant": {
            "description": "Bank tenant UUID. Send explicitly on every submission and retry; it must be an authorized tenant.",
            "type": "string"
          }
        },
        "required": [
          "bank_request_id",
          "legs"
        ],
        "type": "object"
      }
    }
  },
  "required": true
}
Responses
{
  "200": {
    "content": {
      "application/json": {
        "example": {
          "bank_request_id": "bank-payment-20260928-001",
          "id": "00000000-0000-0000-0000-0000000000a1",
          "legs": [
            {
              "amount": {
                "asset": "USD",
                "scale": 2,
                "units": "12345"
              },
              "finality_class": "instant",
              "form": "fiat",
              "id": "00000000-0000-0000-0000-0000000000b1",
              "obligor": "",
              "role": "source",
              "status": "pending",
              "wave": 0
            },
            {
              "amount": {
                "asset": "USD",
                "scale": 2,
                "units": "12345"
              },
              "finality_class": "instant",
              "form": "fiat",
              "id": "00000000-0000-0000-0000-0000000000b2",
              "obligor": "",
              "role": "destination",
              "status": "pending",
              "wave": 1
            }
          ],
          "settlement_kind": "payment",
          "status": "denied",
          "tenant": "00000000-0000-0000-0000-000000000101"
        },
        "schema": {
          "properties": {
            "atomicity": {
              "type": "string"
            },
            "bank_request_id": {
              "type": "string"
            },
            "id": {
              "type": "string"
            },
            "invoice_ref": {
              "type": "string"
            },
            "legs": {
              "items": {
                "properties": {
                  "amount": {
                    "properties": {
                      "asset": {
                        "description": "Asset or currency identifier understood by the installed policy and rail.",
                        "examples": [
                          "USD"
                        ],
                        "type": "string"
                      },
                      "scale": {
                        "description": "Decimal exponent. USD minor units conventionally use 2.",
                        "maximum": 255,
                        "minimum": 0,
                        "type": "integer"
                      },
                      "units": {
                        "description": "Exact integer minor units as a decimal string; never a JSON floating-point amount.",
                        "examples": [
                          "12345"
                        ],
                        "pattern": "^-?[0-9]+$",
                        "type": "string"
                      }
                    },
                    "required": [
                      "asset",
                      "scale",
                      "units"
                    ],
                    "type": "object"
                  },
                  "finality_class": {
                    "type": "string"
                  },
                  "form": {
                    "type": "string"
                  },
                  "id": {
                    "type": "string"
                  },
                  "obligor": {
                    "type": "string"
                  },
                  "role": {
                    "type": "string"
                  },
                  "status": {
                    "type": "string"
                  },
                  "token": {
                    "type": "string"
                  },
                  "token_chain_id": {
                    "type": "integer"
                  },
                  "token_symbol": {
                    "type": "string"
                  },
                  "wave": {
                    "type": "integer"
                  }
                },
                "type": "object"
              },
              "type": "array"
            },
            "settlement_kind": {
              "type": "string"
            },
            "status": {
              "description": "Persisted saga status. HTTP success does not imply settlement success.",
              "enum": [
                "accepted",
                "authorised",
                "sealed",
                "dispatched",
                "confirmed",
                "denied",
                "reversed",
                "stuck",
                "resolved_manual"
              ],
              "type": "string"
            },
            "stuck_deadline_ms": {
              "type": "integer"
            },
            "tenant": {
              "type": "string"
            }
          },
          "required": [
            "id",
            "tenant",
            "bank_request_id",
            "settlement_kind",
            "status",
            "legs"
          ],
          "type": "object"
        }
      }
    },
    "description": "Successful response. Read the returned settlement status; this is not a guarantee of completed value movement."
  },
  "400": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Invalid request, malformed identifier, or unmet input requirement."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  },
  "409": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "State conflict; inspect the error before retrying."
  },
  "500": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Internal failure."
  },
  "503": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Required service or evidence input is unavailable."
  }
}
curl --fail-with-body -sS -X POST "$FRAME_URL/settlements" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT" \
  -H 'Content-Type: application/json' --data-binary @instruction.json

GET /v1/settlements/{id}/receipt

Read a settlement receipt

Bank session · read capability

Returns success.data with the human-readable settlement narrative, finality and evidence links. Use the CBOR pack for independent cryptographic verification; a rendered receipt is a view.

Parameters

NameTypeDescription
id
required
path · stringResource identifier from the corresponding response.
X-Frame-Tenantheader · stringActive tenant membership UUID. Send explicitly for deterministic tenancy.
Responses
{
  "200": {
    "content": {
      "application/json": {
        "schema": {
          "properties": {
            "data": {
              "properties": {
                "enclave": {
                  "properties": {},
                  "type": "object"
                },
                "headline": {
                  "properties": {},
                  "type": "object"
                },
                "inputs": {},
                "instruction": {
                  "properties": {},
                  "type": "object"
                },
                "lifecycle": {
                  "items": {
                    "properties": {},
                    "type": "object"
                  },
                  "type": "array"
                },
                "lifecycle_truncated": {
                  "type": "boolean"
                },
                "not_claimed": {
                  "items": {
                    "type": "string"
                  },
                  "type": "array"
                },
                "pack": {
                  "properties": {},
                  "type": "object"
                },
                "seal": {
                  "type": [
                    "object",
                    "null"
                  ]
                },
                "settlement": {
                  "properties": {},
                  "type": "object"
                },
                "verdict": {
                  "type": [
                    "object",
                    "null"
                  ]
                },
                "verification": {
                  "properties": {},
                  "type": "object"
                },
                "witness": {
                  "properties": {},
                  "type": "object"
                }
              },
              "type": "object"
            },
            "success": {
              "type": "boolean"
            }
          },
          "type": "object"
        }
      }
    },
    "description": "Successful response. Read a settlement receipt."
  },
  "400": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Invalid request, malformed identifier, or unmet input requirement."
  },
  "401": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Missing, expired, or revoked session."
  },
  "403": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Tenant or capability does not authorize this operation."
  },
  "404": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Resource not found in the caller scope."
  },
  "500": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Internal failure."
  },
  "503": {
    "content": {
      "application/json": {
        "schema": {
          "example": {
            "error": "evidence not sealed yet — retry shortly"
          },
          "properties": {
            "error": {
              "description": "Human-readable explanation. Do not parse as a stable error code.",
              "type": "string"
            }
          },
          "required": [
            "error"
          ],
          "type": "object"
        }
      }
    },
    "description": "Required service or evidence input is unavailable."
  }
}
curl --fail-with-body -sS "$FRAME_URL/v1/settlements/${FRAME_ID}/receipt" \
  -H "Authorization: Bearer $FRAME_TOKEN" \
  -H "X-Frame-Tenant: $FRAME_TENANT"