HYBRID-CHAINDEVELOPERS
DOCUMENTATIONv2
POST

Funding & settlement

Cancel settlement intent

/api/v2/funding/settlement-intents/{intent_uuid}/cancellations
AUTHENTICATIONBearer token · funding:writeAUTHORITATIVE OWNERfunding-serviceCONTRACT AUTHORITYGenerated Rust OpenAPISTATUSSource ready · production listed

PURPOSE + BUSINESS CONTEXT

Atomically cancel an owner-scoped pre-broadcast settlement intent and release any held collateral; signing, broadcast, and terminal states remain outside customer cancellation authority.

WHEN THIS CALL IS USEFUL

Use to cancel an owner-scoped intent only while it is still pre-broadcast and therefore recoverable without contradicting an external transaction.

OUTCOME · Create or advance

What changes

Atomically changes an eligible intent to CANCELLED, releases its collateral reservation if present, and appends evidence; it never reverses a broadcast transaction or changes another balance.

WHY IT MATTERS

  • Gives people and agents a contract-backed way to advance settlement intent.
  • Connects funding observations to exact owner, instrument, wallet, rail, and settlement context without making the gateway the owner of value.

ISOLATION + AUTHORITY

Owner, workspace, network, instrument, wallet, rail, custody, collateral, compliance, and settlement authorities remain separate. A prepared route, observed deposit, accepted intent, completed consent, reservation, broadcast, or Explorer record does not itself prove final settlement or authorize value movement.

BEFORE YOU CALL

  • Authenticate at the documented boundary: bearer+scope.
  • Supply the required intent_uuid (path), network_id (body), expected_request_commitment (body), reason_code (body) exactly as defined by the live contract.
  • Use one Idempotency-Key only for retries of the same byte-equivalent logical mutation.
  • Resolve the owner, network, instrument or wallet, rail, and settlement context before relying on this result.

WHAT TO DO NEXT

  • Re-read settlement intent using the canonical identifier returned by this operation.
  • Reconcile an ambiguous response with the same idempotency key before attempting another mutation.
  • Reconcile the returned state against the authoritative wallet, rail, and settlement record before advancing or retrying.

AGENT GUIDANCE

  • Use settlement intent only for the purpose and lifecycle stage described by this operation; do not treat it as authority for an adjacent action.
  • Supply the required intent_uuid (path), network_id (body), expected_request_commitment (body), reason_code (body) exactly as defined by the live contract.
  • Preserve amounts and fees as exact decimal strings and distinguish observed, accepted, authorized, reserved, broadcast, confirmed, settled, reversed, and reconciled states.
  • After a timeout or conflict, read authoritative state before deciding whether an equivalent retry is safe.
MACHINE CONTRACT

The exact deployed parameters, schemas, responses, security requirements, and Hybrid-Chain agent metadata are authoritative at this operation's production OpenAPI JSON Pointer. The readable tables below add integration guidance; the deployed OpenAPI controls if guidance and the machine contract ever differ.

Open the authoritative production contract

EXTENDED INTEGRATION GUIDANCE

Readable request and response reference

Examples illustrate integration intent; the referenced OpenAPI operation and component schemas define the executable shape.

PARAMETERS

Headers, path, query, and body

NAMELOCATIONPRESENCETYPE / RULES / PURPOSE
AuthorizationheaderRequired

Bearer tokenCredential containing the funding:write scope.EXAMPLEBearer hc_live_…

Idempotency-KeyheaderRequired

ASCII string · 1–128Caller-generated key reused for every retry of the same logical mutation.EXAMPLElaunch-treasury-v1-001

Content-TypeheaderRequired

application/jsonSigned mutations accept canonical JSON only.EXAMPLEapplication/json

Content-DigestheaderRequired

RFC 9530 SHA-256 digestDigest of the exact transmitted body bytes.EXAMPLEsha-256=:47DEQpj8HBSa+/TImW+5JCeuQeRkm5NMpJWZG3hSuFU=:

Signature-InputheaderRequired

RFC 9421 signature parametersCovers @method, @path, content-digest, content-type, and idempotency-key; includes keyid, nonce, created, and expires.EXAMPLEsig1=("@method" "@path" "content-digest" "content-type" "idempotency-key");created=1786582800;expires=1786583100;nonce="01J…";keyid="machine-prod"

SignatureheaderRequired

Ed25519 HTTP Message SignatureSignature made by an active public key registered to the authenticated client.EXAMPLEsig1=:base64-signature:

intent_uuidpathRequired

identifierOwner-scoped pre-broadcast intent to cancel.EXAMPLEintent-01

network_idbodyRequired

hybrid-devnet | hybrid-testnet | hybrid-mainnetMust match the authenticated owner and intent.EXAMPLEhybrid-testnet

expected_request_commitmentbodyRequired

64-character hexadecimal SHA-256 digestLatest intent commitment; prevents cancellation after stale or substituted state.EXAMPLE3333333333333333333333333333333333333333333333333333333333333333

reason_codebodyRequired

OWNER_CANCELLEDOnly customer-controlled cancellation reason; machine and administrative failures use separate authorities.EXAMPLEOWNER_CANCELLED

REQUEST

JSON body example

{
  "network_id": "hybrid-testnet",
  "expected_request_commitment": "3333333333333333333333333333333333333333333333333333333333333333",
  "reason_code": "OWNER_CANCELLED"
}

RESPONSES

Status and payload examples

200Eligible intent cancelled and any collateral released atomically.Mutation completed · JSON RESPONSE+
{
  "intent_uuid": "intent-01",
  "state": "CANCELLED",
  "failure_code": "OWNER_CANCELLED",
  "collateral_released": true,
  "collateral_release_entry_hash": "4444444444444444444444444444444444444444444444444444444444444444",
  "funds_moved": false,
  "idempotent": false
}
INTEGRATION DECISION
CALLER ACTION
Accept the returned representation or receipt, then re-read settlement intent using the canonical identifier returned by this operation.
RETRY SAFETY
Do not repeat a successful mutation merely to confirm it. For one logical mutation, retain the same Idempotency-Key and byte-equivalent request. Never reuse that key for changed instructions.
STATE RECONCILIATION
Persist returned identifiers, versions, commitments, and receipts. Refresh the funding method and transfer or deposit lifecycle; compare amount, asset, network, destination, provider reference, and terminal settlement evidence.
400The network, expected commitment, reason, signed headers, or idempotency key is malformed.Request must change · JSON RESPONSE+
{
  "code": "invalid_settlement_cancellation",
  "message": "The network, expected commitment, reason, signed headers, or idempotency key is malformed."
}
INTEGRATION DECISIONinvalid_settlement_cancellation
CALLER ACTION
Rebuild the request from the live OpenAPI operation and correct the rejected method, media type, header, parameter, or body field.
RETRY SAFETY
Do not retry the same invalid request. For one logical mutation, retain the same Idempotency-Key and byte-equivalent request. Never reuse that key for changed instructions.
STATE RECONCILIATION
Compare the submitted values with the documented constraints before another call. Refresh the funding method and transfer or deposit lifecycle; compare amount, asset, network, destination, provider reference, and terminal settlement evidence.
ESCALATE WHEN
Escalate when money movement is ambiguous, provider and ledger states disagree, or a destination or asset cannot be proven exact.
401The bearer credential is invalid.Authentication required · JSON RESPONSE+
{
  "code": "invalid_credentials",
  "message": "The bearer credential is invalid."
}
INTEGRATION DECISIONinvalid_credentials
CALLER ACTION
Discard the rejected credential, complete the documented authentication or reassertion flow, and rebuild any request signature with fresh timestamps and nonces.
RETRY SAFETY
Retry only with a newly valid credential and fresh replay-protection values. For one logical mutation, retain the same Idempotency-Key and byte-equivalent request. Never reuse that key for changed instructions.
STATE RECONCILIATION
Assume the outcome is unknown only when the connection failed after transmission; otherwise authentication failed before domain work. Refresh the funding method and transfer or deposit lifecycle; compare amount, asset, network, destination, provider reference, and terminal settlement evidence.
ESCALATE WHEN
Escalate when money movement is ambiguous, provider and ledger states disagree, or a destination or asset cannot be proven exact.
403The principal lacks funding:write or does not own the intent.Authority or policy denied · JSON RESPONSE+
{
  "code": "settlement_cancellation_forbidden",
  "message": "The principal lacks funding:write or does not own the intent."
}
INTEGRATION DECISIONsettlement_cancellation_forbidden
CALLER ACTION
Verify the exact scope, tenant or workspace membership, owner boundary, step-up purpose, feature policy, and resource eligibility. Never broaden authority automatically.
RETRY SAFETY
Do not retry until the missing authority or policy condition has been deliberately resolved with least privilege.
STATE RECONCILIATION
Confirm the caller and resource resolve to the same authority boundary for owner-scoped funding methods, deposit instructions, transfer intents, settlement progress, and delivery receipts.
ESCALATE WHEN
Escalate when money movement is ambiguous, provider and ledger states disagree, or a destination or asset cannot be proven exact.
404The intent does not exist in the owner and network boundary.Resource not visible · JSON RESPONSE+
{
  "code": "settlement_intent_not_found",
  "message": "The intent does not exist in the owner and network boundary."
}
INTEGRATION DECISIONsettlement_intent_not_found
CALLER ACTION
Verify the canonical identifier and authenticated owner boundary. A 404 may intentionally conceal a resource outside the caller's authority.
RETRY SAFETY
Do not retry the unchanged identifier repeatedly. Refresh the relevant collection or lookup before choosing another identifier.
STATE RECONCILIATION
Refresh the funding method and transfer or deposit lifecycle; compare amount, asset, network, destination, provider reference, and terminal settlement evidence.
ESCALATE WHEN
Escalate when money movement is ambiguous, provider and ledger states disagree, or a destination or asset cannot be proven exact.
409The commitment is stale, the intent entered signing, broadcast, or terminal state, or idempotency conflicts.State reconciliation required · JSON RESPONSE+
{
  "code": "settlement_cancellation_conflict",
  "message": "The commitment is stale, the intent entered signing, broadcast, or terminal state, or idempotency conflicts."
}
INTEGRATION DECISIONsettlement_cancellation_conflict
CALLER ACTION
Stop the mutation sequence and fetch the latest authoritative resource, lifecycle state, version, ETag, reservation, or existing idempotency result.
RETRY SAFETY
Retry only after reconciling the conflict. For one logical mutation, retain the same Idempotency-Key and byte-equivalent request. Never reuse that key for changed instructions.
STATE RECONCILIATION
Refresh the funding method and transfer or deposit lifecycle; compare amount, asset, network, destination, provider reference, and terminal settlement evidence.
ESCALATE WHEN
Escalate when money movement is ambiguous, provider and ledger states disagree, or a destination or asset cannot be proven exact.
422Lifecycle or collateral-release policy rejected cancellation.Request must change · JSON RESPONSE+
{
  "code": "settlement_cancellation_rejected",
  "message": "Lifecycle or collateral-release policy rejected cancellation."
}
INTEGRATION DECISIONsettlement_cancellation_rejected
CALLER ACTION
Rebuild the request from the live OpenAPI operation and correct the rejected method, media type, header, parameter, or body field.
RETRY SAFETY
Do not retry the same invalid request. For one logical mutation, retain the same Idempotency-Key and byte-equivalent request. Never reuse that key for changed instructions.
STATE RECONCILIATION
Compare the submitted values with the documented constraints before another call. Refresh the funding method and transfer or deposit lifecycle; compare amount, asset, network, destination, provider reference, and terminal settlement evidence.
ESCALATE WHEN
Escalate when money movement is ambiguous, provider and ledger states disagree, or a destination or asset cannot be proven exact.
503Funding or collateral ownership is unavailable; intent and collateral remain unchanged.Dependency unavailable or outcome uncertain · JSON RESPONSE+
{
  "code": "settlement_cancellation_unavailable",
  "message": "Funding or collateral ownership is unavailable; intent and collateral remain unchanged."
}
INTEGRATION DECISIONsettlement_cancellation_unavailable
CALLER ACTION
Preserve the exact request and treat the outcome as uncertain until authoritative state proves whether it committed.
RETRY SAFETY
Reconcile before retrying. For one logical mutation, retain the same Idempotency-Key and byte-equivalent request. Never reuse that key for changed instructions. Use bounded backoff with jitter.
STATE RECONCILIATION
Refresh the funding method and transfer or deposit lifecycle; compare amount, asset, network, destination, provider reference, and terminal settlement evidence.
ESCALATE WHEN
Escalate when money movement is ambiguous, provider and ledger states disagree, or a destination or asset cannot be proven exact.

OPERATIONAL NOTES

Security and lifecycle guarantees

  • This reviewed planning contract is non-executable until present in production OpenAPI.
  • Customer cancellation is eligible only from AUTHORIZATION_REQUIRED, AUTHORIZED, or FUNDS_RESERVED. Signing, broadcasting, confirming, completed, failed, and other terminal states return HTTP 409.
  • An already CANCELLED exact intent is idempotent. After an ambiguous response, re-read intent and collateral state before retrying the same body and Idempotency-Key.
  • Cancellation cannot reverse a broadcast transaction or revoke a wallet, credential, binding, deposit, or external-rail instruction.
DOCUMENTATION STATUS

This route is implemented in canonical gateway source and appears in the production OpenAPI snapshot observed 2026-09-11T06:35:11.572Z. Authentication, tenant, feature, venue, and market policy still apply.

Verify the exact production OpenAPI operation Return to the V2 directory