{"openapi":"3.1.0","info":{"title":"Prokura API","version":"0.5.0","description":"Verifiable authority for AI-agent payments: mandates, a deterministic policy gate, rails and signed evidence.","license":{"name":"Source-available during pre-release"}},"servers":[{"url":"http://localhost:8080"}],"tags":[{"name":"Authority"},{"name":"Payments"},{"name":"Approvals"},{"name":"Evidence"},{"name":"Session"},{"name":"Public"},{"name":"Adapters"}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","description":"Tenant API key"},"session":{"type":"http","scheme":"bearer","description":"Read-only demo session token (pks_…), bound to one mandate"}},"schemas":{"Error":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}},"paths":{"/v1/principals":{"post":{"summary":"Create a principal (did:web or did:key)","tags":["Authority"],"operationId":"postV1Principals","security":[{"bearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"did":{"anyOf":[{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},{"type":"string","pattern":"^did:web:[a-z0-9.%:-]+$"}]},"domain":{"type":"string","pattern":"^([a-z0-9-]+\\.)+[a-z]{2,}$"},"legalName":{"type":"string","minLength":1},"register":{"type":"string"},"publicKeyMultibase":{"type":"string"}},"required":["legalName"]}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"keyCustody":{"type":"string","enum":["dev","external"]},"didDocument":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}},"passkeys":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"passkeyEnrollmentUrl":{"type":"string","format":"uri"}},"required":["id","keyCustody","didDocument","passkeys","passkeyEnrollmentUrl"],"additionalProperties":false}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key"},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/agents":{"post":{"summary":"Register an agent public key as did:key","tags":["Authority"],"operationId":"postV1Agents","security":[{"bearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"publicKeyMultibase":{"type":"string"}},"required":["publicKeyMultibase"]}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"}},"required":["id"],"additionalProperties":false}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key"},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/mandates":{"post":{"summary":"Issue an Agent Authority Credential (grantedBy.method passkey needs an assertion; the demo tenant also gets a session token)","tags":["Authority"],"operationId":"postV1Mandates","security":[{"bearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"principalId":{"type":"string"},"agentId":{"type":"string"},"validFrom":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"validUntil":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"scope":{"type":"object","properties":{"currency":{"type":"string","pattern":"^[A-Z]{3,5}$"},"capPerTx":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"capPeriod":{"type":"object","properties":{"amount":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"period":{"type":"string","pattern":"^P(\\d+)([DWMY])$"}},"required":["amount","period"]},"fourEyesAbove":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"payees":{"minItems":1,"type":"array","items":{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"iban"},"value":{"type":"string","pattern":"^[A-Z]{2}\\d{2}[A-Z0-9]{11,30}$"},"name":{"type":"string"}},"required":["type","value"]},{"type":"object","properties":{"type":{"type":"string","const":"domain"},"value":{"type":"string","pattern":"^(?=.{1,253}$)([a-z0-9-]{1,63}\\.)+[a-z]{2,63}$"},"name":{"type":"string"}},"required":["type","value"]}]}},"mcc":{"type":"array","items":{"type":"string","pattern":"^\\d{4}$"}},"rails":{"minItems":1,"type":"array","items":{"type":"string","minLength":1}},"purposes":{"minItems":1,"type":"array","items":{"type":"string","minLength":1}},"currencyLimits":{"type":"array","items":{"type":"object","properties":{"currency":{"type":"string","pattern":"^[A-Z]{3,5}$"},"capPerTx":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"capPeriod":{"type":"object","properties":{"amount":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"period":{"type":"string","pattern":"^P(\\d+)([DWMY])$"}},"required":["amount","period"]},"fourEyesAbove":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]}},"required":["currency","capPerTx","capPeriod","fourEyesAbove"]}}},"required":["currency","capPerTx","capPeriod","fourEyesAbove","payees","rails","purposes"]},"b2b":{"type":"object","properties":{"costCentre":{"type":"string"},"poRequired":{"default":false,"type":"boolean"},"invoiceHashRequired":{"default":false,"type":"boolean"},"skontoWindowDays":{"type":"integer","minimum":0,"maximum":9007199254740991}}},"delegation":{"type":"object","properties":{"subDelegate":{"type":"boolean"},"maxDepth":{"type":"integer","minimum":0,"maximum":9007199254740991},"parent":{"type":["string","null"]}},"required":["subDelegate","maxDepth","parent"]},"grantedBy":{"type":"object","properties":{"name":{"type":"string","minLength":1},"role":{"type":"string"},"method":{"type":"string","enum":["passkey","dev-preapproved","demo-unsigned"]}},"required":["method"]},"passkey":{"type":"object","properties":{"challengeId":{"type":"string"},"response":{"type":"object","properties":{"id":{"type":"string"},"rawId":{"type":"string"},"type":{"type":"string","const":"public-key"},"clientExtensionResults":{"default":{},"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}},"authenticatorAttachment":{"type":"string"},"response":{"type":"object","properties":{"authenticatorData":{"type":"string"},"clientDataJSON":{"type":"string"},"signature":{"type":"string"},"userHandle":{"type":"string"}},"required":["authenticatorData","clientDataJSON","signature"]}},"required":["id","rawId","type","response"]}},"required":["challengeId","response"]}},"required":["agentId","validUntil","scope","grantedBy"]}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"anyOf":[{"type":"object","properties":{"mandateId":{"type":"string"},"credential":{"type":"object","properties":{"@context":{"minItems":2,"type":"array","items":{"anyOf":[{"type":"string"},{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}}]}},"id":{"type":"string","pattern":"^urn:ulid:[0-9A-HJKMNP-TV-Z]{26}$"},"type":{"type":"array","prefixItems":[{"type":"string","const":"VerifiableCredential"},{"type":"string","const":"AgentAuthorityCredential"}],"items":false,"minItems":2,"maxItems":2},"issuer":{"anyOf":[{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},{"type":"string","pattern":"^did:web:[a-z0-9.%:-]+$"}]},"validFrom":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"validUntil":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"credentialStatus":{"type":"object","properties":{"id":{"type":"string"},"type":{"type":"string","const":"BitstringStatusListEntry"},"statusPurpose":{"type":"string","const":"revocation"},"statusListIndex":{"type":"string","pattern":"^\\d+$"},"statusListCredential":{"type":"string","format":"uri"}},"required":["type","statusPurpose","statusListIndex","statusListCredential"],"additionalProperties":false},"credentialSubject":{"type":"object","properties":{"id":{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},"principal":{"type":"object","properties":{"id":{"anyOf":[{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},{"type":"string","pattern":"^did:web:[a-z0-9.%:-]+$"}]},"legalName":{"type":"string","minLength":1},"register":{"type":"string"}},"required":["id","legalName"],"additionalProperties":false},"grantedBy":{"type":"object","properties":{"name":{"type":"string","minLength":1},"role":{"type":"string"},"method":{"type":"string","enum":["passkey","dev-preapproved","demo-unsigned"]}},"required":["name","method"],"additionalProperties":false},"scope":{"type":"object","properties":{"currency":{"type":"string","pattern":"^[A-Z]{3,5}$"},"capPerTx":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"capPeriod":{"type":"object","properties":{"amount":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"period":{"type":"string","pattern":"^P(\\d+)([DWMY])$"}},"required":["amount","period"],"additionalProperties":false},"fourEyesAbove":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"payees":{"minItems":1,"type":"array","items":{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"iban"},"value":{"type":"string","pattern":"^[A-Z]{2}\\d{2}[A-Z0-9]{11,30}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false},{"type":"object","properties":{"type":{"type":"string","const":"domain"},"value":{"type":"string","pattern":"^(?=.{1,253}$)([a-z0-9-]{1,63}\\.)+[a-z]{2,63}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false}]}},"mcc":{"type":"array","items":{"type":"string","pattern":"^\\d{4}$"}},"rails":{"minItems":1,"type":"array","items":{"type":"string","minLength":1}},"purposes":{"minItems":1,"type":"array","items":{"type":"string","minLength":1}},"currencyLimits":{"type":"array","items":{"type":"object","properties":{"currency":{"type":"string","pattern":"^[A-Z]{3,5}$"},"capPerTx":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"capPeriod":{"type":"object","properties":{"amount":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"period":{"type":"string","pattern":"^P(\\d+)([DWMY])$"}},"required":["amount","period"],"additionalProperties":false},"fourEyesAbove":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]}},"required":["currency","capPerTx","capPeriod","fourEyesAbove"],"additionalProperties":false}}},"required":["currency","capPerTx","capPeriod","fourEyesAbove","payees","rails","purposes"],"additionalProperties":false},"b2b":{"type":"object","properties":{"costCentre":{"type":"string"},"poRequired":{"default":false,"type":"boolean"},"invoiceHashRequired":{"default":false,"type":"boolean"},"skontoWindowDays":{"type":"integer","minimum":0,"maximum":9007199254740991}},"required":["poRequired","invoiceHashRequired"],"additionalProperties":false},"delegation":{"type":"object","properties":{"subDelegate":{"type":"boolean"},"maxDepth":{"type":"integer","minimum":0,"maximum":9007199254740991},"parent":{"type":["string","null"]}},"required":["subDelegate","maxDepth","parent"],"additionalProperties":false},"evidence":{"type":"object","properties":{"retainDays":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"exportFormat":{"type":"string","const":"nachweis/v1"}},"required":["retainDays","exportFormat"],"additionalProperties":false}},"required":["id","principal","grantedBy","scope","delegation","evidence"],"additionalProperties":false},"proof":{"type":"object","properties":{"type":{"type":"string","const":"DataIntegrityProof"},"cryptosuite":{"type":"string","const":"eddsa-rdfc-2022"},"verificationMethod":{"type":"string"},"proofPurpose":{"type":"string","const":"assertionMethod"},"proofValue":{"type":"string"},"created":{"type":"string"}},"required":["type","cryptosuite","verificationMethod","proofPurpose","proofValue"],"additionalProperties":{}}},"required":["@context","id","type","issuer","validFrom","validUntil","credentialStatus","credentialSubject"],"additionalProperties":{}}},"required":["mandateId","credential"],"additionalProperties":false},{"type":"object","properties":{"mandateId":{"type":"string"},"credential":{"type":"object","properties":{"@context":{"minItems":2,"type":"array","items":{"anyOf":[{"type":"string"},{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}}]}},"id":{"type":"string","pattern":"^urn:ulid:[0-9A-HJKMNP-TV-Z]{26}$"},"type":{"type":"array","prefixItems":[{"type":"string","const":"VerifiableCredential"},{"type":"string","const":"AgentAuthorityCredential"}],"items":false,"minItems":2,"maxItems":2},"issuer":{"anyOf":[{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},{"type":"string","pattern":"^did:web:[a-z0-9.%:-]+$"}]},"validFrom":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"validUntil":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"credentialStatus":{"type":"object","properties":{"id":{"type":"string"},"type":{"type":"string","const":"BitstringStatusListEntry"},"statusPurpose":{"type":"string","const":"revocation"},"statusListIndex":{"type":"string","pattern":"^\\d+$"},"statusListCredential":{"type":"string","format":"uri"}},"required":["type","statusPurpose","statusListIndex","statusListCredential"],"additionalProperties":false},"credentialSubject":{"type":"object","properties":{"id":{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},"principal":{"type":"object","properties":{"id":{"anyOf":[{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},{"type":"string","pattern":"^did:web:[a-z0-9.%:-]+$"}]},"legalName":{"type":"string","minLength":1},"register":{"type":"string"}},"required":["id","legalName"],"additionalProperties":false},"grantedBy":{"type":"object","properties":{"name":{"type":"string","minLength":1},"role":{"type":"string"},"method":{"type":"string","enum":["passkey","dev-preapproved","demo-unsigned"]}},"required":["name","method"],"additionalProperties":false},"scope":{"type":"object","properties":{"currency":{"type":"string","pattern":"^[A-Z]{3,5}$"},"capPerTx":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"capPeriod":{"type":"object","properties":{"amount":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"period":{"type":"string","pattern":"^P(\\d+)([DWMY])$"}},"required":["amount","period"],"additionalProperties":false},"fourEyesAbove":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"payees":{"minItems":1,"type":"array","items":{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"iban"},"value":{"type":"string","pattern":"^[A-Z]{2}\\d{2}[A-Z0-9]{11,30}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false},{"type":"object","properties":{"type":{"type":"string","const":"domain"},"value":{"type":"string","pattern":"^(?=.{1,253}$)([a-z0-9-]{1,63}\\.)+[a-z]{2,63}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false}]}},"mcc":{"type":"array","items":{"type":"string","pattern":"^\\d{4}$"}},"rails":{"minItems":1,"type":"array","items":{"type":"string","minLength":1}},"purposes":{"minItems":1,"type":"array","items":{"type":"string","minLength":1}},"currencyLimits":{"type":"array","items":{"type":"object","properties":{"currency":{"type":"string","pattern":"^[A-Z]{3,5}$"},"capPerTx":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"capPeriod":{"type":"object","properties":{"amount":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"period":{"type":"string","pattern":"^P(\\d+)([DWMY])$"}},"required":["amount","period"],"additionalProperties":false},"fourEyesAbove":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]}},"required":["currency","capPerTx","capPeriod","fourEyesAbove"],"additionalProperties":false}}},"required":["currency","capPerTx","capPeriod","fourEyesAbove","payees","rails","purposes"],"additionalProperties":false},"b2b":{"type":"object","properties":{"costCentre":{"type":"string"},"poRequired":{"default":false,"type":"boolean"},"invoiceHashRequired":{"default":false,"type":"boolean"},"skontoWindowDays":{"type":"integer","minimum":0,"maximum":9007199254740991}},"required":["poRequired","invoiceHashRequired"],"additionalProperties":false},"delegation":{"type":"object","properties":{"subDelegate":{"type":"boolean"},"maxDepth":{"type":"integer","minimum":0,"maximum":9007199254740991},"parent":{"type":["string","null"]}},"required":["subDelegate","maxDepth","parent"],"additionalProperties":false},"evidence":{"type":"object","properties":{"retainDays":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"exportFormat":{"type":"string","const":"nachweis/v1"}},"required":["retainDays","exportFormat"],"additionalProperties":false}},"required":["id","principal","grantedBy","scope","delegation","evidence"],"additionalProperties":false},"proof":{"type":"object","properties":{"type":{"type":"string","const":"DataIntegrityProof"},"cryptosuite":{"type":"string","const":"eddsa-rdfc-2022"},"verificationMethod":{"type":"string"},"proofPurpose":{"type":"string","const":"assertionMethod"},"proofValue":{"type":"string"},"created":{"type":"string"}},"required":["type","cryptosuite","verificationMethod","proofPurpose","proofValue"],"additionalProperties":{}}},"required":["@context","id","type","issuer","validFrom","validUntil","credentialStatus","credentialSubject"],"additionalProperties":{}},"principalId":{"type":"string"},"sessionId":{"type":"string"},"sessionToken":{"type":"object","properties":{"token":{"type":"string","description":"pks_…, read-only, bound to this mandate"},"mandateId":{"type":"string"},"expiresAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"scope":{"type":"string","const":"read:evidence"}},"required":["token","mandateId","expiresAt","scope"],"additionalProperties":false}},"required":["mandateId","credential","principalId","sessionToken"],"additionalProperties":false}]}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key"},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/webauthn/challenges":{"post":{"summary":"Core-issued WebAuthn challenge (register a passkey, or grant a mandate)","tags":["Authority"],"operationId":"postV1WebauthnChallenges","security":[{"bearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"principalId":{"type":"string"},"purpose":{"type":"string","enum":["register","issue"]},"rpId":{"type":"string"}},"required":["principalId","purpose"]}}}},"responses":{"200":{"description":"OK"},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key"},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/passkeys":{"post":{"summary":"Register a passkey for a principal (any allowlisted RP)","tags":["Authority"],"operationId":"postV1Passkeys","security":[{"bearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"response":{"type":"object","properties":{"id":{"type":"string"},"rawId":{"type":"string"},"type":{"type":"string","const":"public-key"},"clientExtensionResults":{"default":{},"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}},"authenticatorAttachment":{"type":"string"},"response":{"type":"object","properties":{"clientDataJSON":{"type":"string"},"attestationObject":{"type":"string"},"transports":{"type":"array","items":{"type":"string"}}},"required":["clientDataJSON","attestationObject"],"additionalProperties":{}}},"required":["id","rawId","type","response"]},"challengeId":{"type":"string"}},"required":["response","challengeId"]}}}},"responses":{"200":{"description":"OK"},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key"},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/mandates/{id}":{"get":{"summary":"Fetch a mandate (full for the owner, redacted summary otherwise)","tags":["Authority"],"operationId":"getV1MandatesId","security":[{"bearer":[]},{}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK"},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/mandates/{id}/revoke":{"post":{"summary":"Revoke: flip the status-list bit and write evidence","tags":["Authority"],"operationId":"postV1MandatesIdRevoke","security":[{"bearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"mandateId":{"type":"string"},"revoked":{"type":"boolean","const":true},"evidenceId":{"type":"string"}},"required":["mandateId","revoked","evidenceId"],"additionalProperties":false}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key"},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/status/{list}":{"get":{"summary":"Bitstring Status List credential","tags":["Authority"],"operationId":"getV1StatusList","security":[],"parameters":[{"name":"list","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK"},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/verify":{"post":{"summary":"Verify a credential","tags":["Authority"],"operationId":"postV1Verify","security":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"@context":{"minItems":2,"type":"array","items":{"anyOf":[{"type":"string"},{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}}]}},"id":{"type":"string","pattern":"^urn:ulid:[0-9A-HJKMNP-TV-Z]{26}$"},"type":{"type":"array","prefixItems":[{"type":"string","const":"VerifiableCredential"},{"type":"string","const":"AgentAuthorityCredential"}],"items":false,"minItems":2,"maxItems":2},"issuer":{"anyOf":[{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},{"type":"string","pattern":"^did:web:[a-z0-9.%:-]+$"}]},"validFrom":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"validUntil":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"credentialStatus":{"type":"object","properties":{"id":{"type":"string"},"type":{"type":"string","const":"BitstringStatusListEntry"},"statusPurpose":{"type":"string","const":"revocation"},"statusListIndex":{"type":"string","pattern":"^\\d+$"},"statusListCredential":{"type":"string","format":"uri"}},"required":["type","statusPurpose","statusListIndex","statusListCredential"]},"credentialSubject":{"type":"object","properties":{"id":{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},"principal":{"type":"object","properties":{"id":{"anyOf":[{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},{"type":"string","pattern":"^did:web:[a-z0-9.%:-]+$"}]},"legalName":{"type":"string","minLength":1},"register":{"type":"string"}},"required":["id","legalName"]},"grantedBy":{"type":"object","properties":{"name":{"type":"string","minLength":1},"role":{"type":"string"},"method":{"type":"string","enum":["passkey","dev-preapproved","demo-unsigned"]}},"required":["name","method"]},"scope":{"type":"object","properties":{"currency":{"type":"string","pattern":"^[A-Z]{3,5}$"},"capPerTx":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"capPeriod":{"type":"object","properties":{"amount":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"period":{"type":"string","pattern":"^P(\\d+)([DWMY])$"}},"required":["amount","period"]},"fourEyesAbove":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"payees":{"minItems":1,"type":"array","items":{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"iban"},"value":{"type":"string","pattern":"^[A-Z]{2}\\d{2}[A-Z0-9]{11,30}$"},"name":{"type":"string"}},"required":["type","value"]},{"type":"object","properties":{"type":{"type":"string","const":"domain"},"value":{"type":"string","pattern":"^(?=.{1,253}$)([a-z0-9-]{1,63}\\.)+[a-z]{2,63}$"},"name":{"type":"string"}},"required":["type","value"]}]}},"mcc":{"type":"array","items":{"type":"string","pattern":"^\\d{4}$"}},"rails":{"minItems":1,"type":"array","items":{"type":"string","minLength":1}},"purposes":{"minItems":1,"type":"array","items":{"type":"string","minLength":1}},"currencyLimits":{"type":"array","items":{"type":"object","properties":{"currency":{"type":"string","pattern":"^[A-Z]{3,5}$"},"capPerTx":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"capPeriod":{"type":"object","properties":{"amount":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"period":{"type":"string","pattern":"^P(\\d+)([DWMY])$"}},"required":["amount","period"]},"fourEyesAbove":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]}},"required":["currency","capPerTx","capPeriod","fourEyesAbove"]}}},"required":["currency","capPerTx","capPeriod","fourEyesAbove","payees","rails","purposes"]},"b2b":{"type":"object","properties":{"costCentre":{"type":"string"},"poRequired":{"default":false,"type":"boolean"},"invoiceHashRequired":{"default":false,"type":"boolean"},"skontoWindowDays":{"type":"integer","minimum":0,"maximum":9007199254740991}}},"delegation":{"type":"object","properties":{"subDelegate":{"type":"boolean"},"maxDepth":{"type":"integer","minimum":0,"maximum":9007199254740991},"parent":{"type":["string","null"]}},"required":["subDelegate","maxDepth","parent"]},"evidence":{"type":"object","properties":{"retainDays":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"exportFormat":{"type":"string","const":"nachweis/v1"}},"required":["retainDays","exportFormat"]}},"required":["id","principal","grantedBy","scope","delegation","evidence"]},"proof":{"type":"object","properties":{"type":{"type":"string","const":"DataIntegrityProof"},"cryptosuite":{"type":"string","const":"eddsa-rdfc-2022"},"verificationMethod":{"type":"string"},"proofPurpose":{"type":"string","const":"assertionMethod"},"proofValue":{"type":"string"},"created":{"type":"string"}},"required":["type","cryptosuite","verificationMethod","proofPurpose","proofValue"],"additionalProperties":{}}},"required":["@context","id","type","issuer","validFrom","validUntil","credentialStatus","credentialSubject"],"additionalProperties":{}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"valid":{"type":"boolean"},"errors":{"type":"array","items":{"type":"string"}},"checks":{"type":"object","properties":{"schema":{"type":"boolean"},"proof":{"type":"boolean"},"validity":{"type":"string","enum":["valid","expired","not_yet_valid"]},"status":{"type":"string","enum":["active","revoked","unchecked"]}},"required":["schema","proof","validity","status"],"additionalProperties":false}},"required":["valid","errors","checks"],"additionalProperties":false}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/check":{"post":{"summary":"Evaluate an intent without executing","tags":["Payments"],"operationId":"postV1Check","security":[{"bearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"mandateId":{"type":"string","pattern":"^[0-9A-HJKMNP-TV-Z]{26}$"},"agentId":{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},"amount":{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"},"currency":{"type":"string","pattern":"^[A-Z]{3,5}$"},"payee":{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"iban"},"value":{"type":"string","pattern":"^[A-Z]{2}\\d{2}[A-Z0-9]{11,30}$"},"name":{"type":"string"}},"required":["type","value"]},{"type":"object","properties":{"type":{"type":"string","const":"domain"},"value":{"type":"string","pattern":"^(?=.{1,253}$)([a-z0-9-]{1,63}\\.)+[a-z]{2,63}$"},"name":{"type":"string"}},"required":["type","value"]}]},"purpose":{"type":"string","minLength":1},"reference":{"default":{},"type":"object","properties":{"po":{"type":"string","minLength":1},"invoiceHash":{"type":"string","pattern":"^sha256:[0-9a-f]{64}$"},"description":{"type":"string","maxLength":255},"resource":{"type":"string","format":"uri"}}},"rail":{"type":"string","minLength":1},"protocol":{"type":"string","enum":["mcp","ap2","tap","acp"]},"mcc":{"type":"string","pattern":"^\\d{4}$"},"nonce":{"type":"string","pattern":"^[A-Za-z0-9_-]{16,64}$"},"createdAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"agentSignature":{"type":"string","minLength":1},"agentName":{"type":"string","maxLength":64}},"required":["mandateId","agentId","amount","currency","payee","purpose","rail","protocol","nonce","createdAt","agentSignature"]}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"decision":{"type":"string","enum":["allow","step_up","deny"]},"reasons":{"minItems":1,"type":"array","items":{"type":"string","enum":["OK","MANDATE_EXPIRED","MANDATE_REVOKED","MANDATE_NOT_YET_VALID","AGENT_MISMATCH","SIGNATURE_INVALID","PAYEE_NOT_ALLOWED","RAIL_NOT_ALLOWED","PURPOSE_NOT_ALLOWED","CAP_PER_TX_EXCEEDED","CAP_PERIOD_EXCEEDED","FOUR_EYES_REQUIRED","PO_MISSING","INVOICE_HASH_MISSING","DUPLICATE_INVOICE","VOP_MISMATCH","MCC_NOT_ALLOWED"]}},"evidenceId":{"type":"string"},"stepUp":{"type":"object","properties":{"url":{"type":"string","format":"uri"},"expiresAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"}},"required":["url","expiresAt"],"additionalProperties":false}},"required":["decision","reasons","evidenceId"],"additionalProperties":false}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key"},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/pay":{"post":{"summary":"Evaluate an intent and execute it if allowed","tags":["Payments"],"operationId":"postV1Pay","security":[{"bearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"mandateId":{"type":"string","pattern":"^[0-9A-HJKMNP-TV-Z]{26}$"},"agentId":{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},"amount":{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"},"currency":{"type":"string","pattern":"^[A-Z]{3,5}$"},"payee":{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"iban"},"value":{"type":"string","pattern":"^[A-Z]{2}\\d{2}[A-Z0-9]{11,30}$"},"name":{"type":"string"}},"required":["type","value"]},{"type":"object","properties":{"type":{"type":"string","const":"domain"},"value":{"type":"string","pattern":"^(?=.{1,253}$)([a-z0-9-]{1,63}\\.)+[a-z]{2,63}$"},"name":{"type":"string"}},"required":["type","value"]}]},"purpose":{"type":"string","minLength":1},"reference":{"default":{},"type":"object","properties":{"po":{"type":"string","minLength":1},"invoiceHash":{"type":"string","pattern":"^sha256:[0-9a-f]{64}$"},"description":{"type":"string","maxLength":255},"resource":{"type":"string","format":"uri"}}},"rail":{"type":"string","minLength":1},"protocol":{"type":"string","enum":["mcp","ap2","tap","acp"]},"mcc":{"type":"string","pattern":"^\\d{4}$"},"nonce":{"type":"string","pattern":"^[A-Za-z0-9_-]{16,64}$"},"createdAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"agentSignature":{"type":"string","minLength":1},"agentName":{"type":"string","maxLength":64}},"required":["mandateId","agentId","amount","currency","payee","purpose","rail","protocol","nonce","createdAt","agentSignature"]}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"decision":{"type":"string","enum":["allow","step_up","deny"]},"reasons":{"minItems":1,"type":"array","items":{"type":"string","enum":["OK","MANDATE_EXPIRED","MANDATE_REVOKED","MANDATE_NOT_YET_VALID","AGENT_MISMATCH","SIGNATURE_INVALID","PAYEE_NOT_ALLOWED","RAIL_NOT_ALLOWED","PURPOSE_NOT_ALLOWED","CAP_PER_TX_EXCEEDED","CAP_PERIOD_EXCEEDED","FOUR_EYES_REQUIRED","PO_MISSING","INVOICE_HASH_MISSING","DUPLICATE_INVOICE","VOP_MISMATCH","MCC_NOT_ALLOWED"]}},"evidenceId":{"type":"string"},"stepUp":{"type":"object","properties":{"url":{"type":"string","format":"uri"},"expiresAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"}},"required":["url","expiresAt"],"additionalProperties":false},"execution":{"type":"object","properties":{"rail":{"type":"string"},"railRef":{"type":["string","null"]},"railStatus":{"type":"string"},"evidenceId":{"type":"string"},"checkoutUrl":{"type":"string","format":"uri"},"error":{"type":"string"},"response":{"type":"object","properties":{"status":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"contentType":{"type":"string"},"body":{"type":"string"}},"required":["status","contentType","body"],"additionalProperties":false}},"required":["rail","railRef","railStatus","evidenceId"],"additionalProperties":false}},"required":["decision","reasons","evidenceId"],"additionalProperties":false}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key"},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/approvals/{id}":{"get":{"summary":"Step-up details and WebAuthn options (?rpId= picks an allowlisted RP)","tags":["Approvals"],"operationId":"getV1ApprovalsId","security":[],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"rpId","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK"},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/approvals/{id}/complete":{"post":{"summary":"Submit a passkey assertion; resumes the payment","tags":["Approvals"],"operationId":"postV1ApprovalsIdComplete","security":[],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"response":{"type":"object","properties":{"id":{"type":"string"},"rawId":{"type":"string"},"type":{"type":"string","const":"public-key"},"clientExtensionResults":{"default":{},"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}},"authenticatorAttachment":{"type":"string"},"response":{"type":"object","properties":{"authenticatorData":{"type":"string"},"clientDataJSON":{"type":"string"},"signature":{"type":"string"},"userHandle":{"type":"string"}},"required":["authenticatorData","clientDataJSON","signature"]}},"required":["id","rawId","type","response"]}},"required":["response"]}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"decision":{"type":"string","enum":["allow","step_up","deny"]},"reasons":{"minItems":1,"type":"array","items":{"type":"string","enum":["OK","MANDATE_EXPIRED","MANDATE_REVOKED","MANDATE_NOT_YET_VALID","AGENT_MISMATCH","SIGNATURE_INVALID","PAYEE_NOT_ALLOWED","RAIL_NOT_ALLOWED","PURPOSE_NOT_ALLOWED","CAP_PER_TX_EXCEEDED","CAP_PERIOD_EXCEEDED","FOUR_EYES_REQUIRED","PO_MISSING","INVOICE_HASH_MISSING","DUPLICATE_INVOICE","VOP_MISMATCH","MCC_NOT_ALLOWED"]}},"evidenceId":{"type":"string"},"stepUp":{"type":"object","properties":{"url":{"type":"string","format":"uri"},"expiresAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"}},"required":["url","expiresAt"],"additionalProperties":false},"execution":{"type":"object","properties":{"rail":{"type":"string"},"railRef":{"type":["string","null"]},"railStatus":{"type":"string"},"evidenceId":{"type":"string"},"checkoutUrl":{"type":"string","format":"uri"},"error":{"type":"string"},"response":{"type":"object","properties":{"status":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"contentType":{"type":"string"},"body":{"type":"string"}},"required":["status","contentType","body"],"additionalProperties":false}},"required":["rail","railRef","railStatus","evidenceId"],"additionalProperties":false}},"required":["decision","reasons","evidenceId"],"additionalProperties":false}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/approvals/{id}/reject":{"post":{"summary":"Reject a step-up: the intent ends deny [FOUR_EYES_REQUIRED], approval status rejected","tags":["Approvals"],"operationId":"postV1ApprovalsIdReject","security":[],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"response":{"type":"object","properties":{"id":{"type":"string"},"rawId":{"type":"string"},"type":{"type":"string","const":"public-key"},"clientExtensionResults":{"default":{},"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}},"authenticatorAttachment":{"type":"string"},"response":{"type":"object","properties":{"authenticatorData":{"type":"string"},"clientDataJSON":{"type":"string"},"signature":{"type":"string"},"userHandle":{"type":"string"}},"required":["authenticatorData","clientDataJSON","signature"]}},"required":["id","rawId","type","response"]}}}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"decision":{"type":"string","enum":["allow","step_up","deny"]},"reasons":{"minItems":1,"type":"array","items":{"type":"string","enum":["OK","MANDATE_EXPIRED","MANDATE_REVOKED","MANDATE_NOT_YET_VALID","AGENT_MISMATCH","SIGNATURE_INVALID","PAYEE_NOT_ALLOWED","RAIL_NOT_ALLOWED","PURPOSE_NOT_ALLOWED","CAP_PER_TX_EXCEEDED","CAP_PERIOD_EXCEEDED","FOUR_EYES_REQUIRED","PO_MISSING","INVOICE_HASH_MISSING","DUPLICATE_INVOICE","VOP_MISMATCH","MCC_NOT_ALLOWED"]}},"evidenceId":{"type":"string"},"stepUp":{"type":"object","properties":{"url":{"type":"string","format":"uri"},"expiresAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"}},"required":["url","expiresAt"],"additionalProperties":false}},"required":["decision","reasons","evidenceId"],"additionalProperties":false}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/enrollments/{token}":{"get":{"summary":"Passkey registration options for a principal","tags":["Approvals"],"operationId":"getV1EnrollmentsToken","security":[],"parameters":[{"name":"token","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK"},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}},"post":{"summary":"Register a passkey for a principal","tags":["Approvals"],"operationId":"postV1EnrollmentsToken","security":[],"parameters":[{"name":"token","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"response":{"type":"object","properties":{"id":{"type":"string"},"rawId":{"type":"string"},"type":{"type":"string","const":"public-key"},"clientExtensionResults":{"default":{},"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}},"authenticatorAttachment":{"type":"string"},"response":{"type":"object","properties":{"clientDataJSON":{"type":"string"},"attestationObject":{"type":"string"},"transports":{"type":"array","items":{"type":"string"}}},"required":["clientDataJSON","attestationObject"],"additionalProperties":{}}},"required":["id","rawId","type","response"]}},"required":["response"]}}}},"responses":{"200":{"description":"OK"},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/evidence":{"get":{"summary":"Evidence records of a mandate (?mandateId=)","tags":["Evidence"],"operationId":"getV1Evidence","security":[{"bearer":[]}],"parameters":[{"name":"mandateId","in":"query","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"records":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"prevHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"hash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"kind":{"type":"string","enum":["check","pay","approval","rejection","execution","rail_status","revocation"]},"refId":{"type":["string","null"]},"mandateId":{"type":"string"},"agentId":{"type":["string","null"]},"principalId":{"type":"string"},"intent":{"anyOf":[{"type":"object","properties":{"mandateId":{"type":"string","pattern":"^[0-9A-HJKMNP-TV-Z]{26}$"},"agentId":{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},"amount":{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"},"currency":{"type":"string","pattern":"^[A-Z]{3,5}$"},"payee":{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"iban"},"value":{"type":"string","pattern":"^[A-Z]{2}\\d{2}[A-Z0-9]{11,30}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false},{"type":"object","properties":{"type":{"type":"string","const":"domain"},"value":{"type":"string","pattern":"^(?=.{1,253}$)([a-z0-9-]{1,63}\\.)+[a-z]{2,63}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false}]},"purpose":{"type":"string","minLength":1},"reference":{"default":{},"type":"object","properties":{"po":{"type":"string","minLength":1},"invoiceHash":{"type":"string","pattern":"^sha256:[0-9a-f]{64}$"},"description":{"type":"string","maxLength":255},"resource":{"type":"string","format":"uri"}},"additionalProperties":false},"rail":{"type":"string","minLength":1},"protocol":{"type":"string","enum":["mcp","ap2","tap","acp"]},"mcc":{"type":"string","pattern":"^\\d{4}$"},"nonce":{"type":"string","pattern":"^[A-Za-z0-9_-]{16,64}$"},"createdAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"agentSignature":{"type":"string","minLength":1}},"required":["mandateId","agentId","amount","currency","payee","purpose","reference","rail","protocol","nonce","createdAt","agentSignature"],"additionalProperties":false},{"type":"null"}]},"intentHash":{"type":["string","null"]},"decision":{"anyOf":[{"type":"string","enum":["allow","step_up","deny"]},{"type":"null"}]},"reasons":{"type":"array","items":{"type":"string","enum":["OK","MANDATE_EXPIRED","MANDATE_REVOKED","MANDATE_NOT_YET_VALID","AGENT_MISMATCH","SIGNATURE_INVALID","PAYEE_NOT_ALLOWED","RAIL_NOT_ALLOWED","PURPOSE_NOT_ALLOWED","CAP_PER_TX_EXCEEDED","CAP_PERIOD_EXCEEDED","FOUR_EYES_REQUIRED","PO_MISSING","INVOICE_HASH_MISSING","DUPLICATE_INVOICE","VOP_MISMATCH","MCC_NOT_ALLOWED"]}},"stepUp":{"anyOf":[{"type":"object","properties":{"approvalId":{"type":"string"},"passkeyCredentialId":{"type":"string"},"approvedAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"rpId":{"type":"string"},"origin":{"type":"string"},"challenge":{"type":"string"},"publicKey":{"type":"string"},"assertion":{"type":"object","properties":{"authenticatorData":{"type":"string"},"clientDataJSON":{"type":"string"},"signature":{"type":"string"},"userHandle":{"type":"string"}},"required":["authenticatorData","clientDataJSON","signature"],"additionalProperties":false}},"required":["approvalId","passkeyCredentialId","approvedAt","rpId","origin","challenge","publicKey","assertion"],"additionalProperties":false},{"type":"null"}]},"gateState":{"anyOf":[{"type":"object","properties":{"now":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"spentThisPeriod":{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"},"seenInvoiceHashes":{"type":"array","items":{"type":"string"}},"seenNonces":{"type":"array","items":{"type":"string"}},"revocationBit":{"type":"boolean"},"credentialProofValid":{"type":"boolean"},"stepUpApproved":{"type":"boolean"}},"required":["now","spentThisPeriod","seenInvoiceHashes","seenNonces","revocationBit","credentialProofValid","stepUpApproved"],"additionalProperties":false},{"type":"null"}]},"rail":{"type":["string","null"]},"railRef":{"type":["string","null"]},"railStatus":{"type":["string","null"]},"amount":{"anyOf":[{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"},{"type":"null"}]},"currency":{"type":["string","null"]},"payee":{"anyOf":[{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"iban"},"value":{"type":"string","pattern":"^[A-Z]{2}\\d{2}[A-Z0-9]{11,30}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false},{"type":"object","properties":{"type":{"type":"string","const":"domain"},"value":{"type":"string","pattern":"^(?=.{1,253}$)([a-z0-9-]{1,63}\\.)+[a-z]{2,63}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false}]},{"type":"null"}]},"createdAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"signature":{"type":"string"},"v":{"type":"number","const":2},"mandateSeq":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"mandatePrevHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"agentName":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}]}},"required":["id","prevHash","hash","kind","refId","mandateId","agentId","principalId","intent","intentHash","decision","reasons","stepUp","gateState","rail","railRef","railStatus","amount","currency","payee","createdAt","signature"],"additionalProperties":false}}},"required":["records"],"additionalProperties":false}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key"},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/evidence/{id}":{"get":{"summary":"Evidence record","tags":["Evidence"],"operationId":"getV1EvidenceId","security":[{"bearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"prevHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"hash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"kind":{"type":"string","enum":["check","pay","approval","rejection","execution","rail_status","revocation"]},"refId":{"type":["string","null"]},"mandateId":{"type":"string"},"agentId":{"type":["string","null"]},"principalId":{"type":"string"},"intent":{"anyOf":[{"type":"object","properties":{"mandateId":{"type":"string","pattern":"^[0-9A-HJKMNP-TV-Z]{26}$"},"agentId":{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},"amount":{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"},"currency":{"type":"string","pattern":"^[A-Z]{3,5}$"},"payee":{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"iban"},"value":{"type":"string","pattern":"^[A-Z]{2}\\d{2}[A-Z0-9]{11,30}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false},{"type":"object","properties":{"type":{"type":"string","const":"domain"},"value":{"type":"string","pattern":"^(?=.{1,253}$)([a-z0-9-]{1,63}\\.)+[a-z]{2,63}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false}]},"purpose":{"type":"string","minLength":1},"reference":{"default":{},"type":"object","properties":{"po":{"type":"string","minLength":1},"invoiceHash":{"type":"string","pattern":"^sha256:[0-9a-f]{64}$"},"description":{"type":"string","maxLength":255},"resource":{"type":"string","format":"uri"}},"additionalProperties":false},"rail":{"type":"string","minLength":1},"protocol":{"type":"string","enum":["mcp","ap2","tap","acp"]},"mcc":{"type":"string","pattern":"^\\d{4}$"},"nonce":{"type":"string","pattern":"^[A-Za-z0-9_-]{16,64}$"},"createdAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"agentSignature":{"type":"string","minLength":1}},"required":["mandateId","agentId","amount","currency","payee","purpose","reference","rail","protocol","nonce","createdAt","agentSignature"],"additionalProperties":false},{"type":"null"}]},"intentHash":{"type":["string","null"]},"decision":{"anyOf":[{"type":"string","enum":["allow","step_up","deny"]},{"type":"null"}]},"reasons":{"type":"array","items":{"type":"string","enum":["OK","MANDATE_EXPIRED","MANDATE_REVOKED","MANDATE_NOT_YET_VALID","AGENT_MISMATCH","SIGNATURE_INVALID","PAYEE_NOT_ALLOWED","RAIL_NOT_ALLOWED","PURPOSE_NOT_ALLOWED","CAP_PER_TX_EXCEEDED","CAP_PERIOD_EXCEEDED","FOUR_EYES_REQUIRED","PO_MISSING","INVOICE_HASH_MISSING","DUPLICATE_INVOICE","VOP_MISMATCH","MCC_NOT_ALLOWED"]}},"stepUp":{"anyOf":[{"type":"object","properties":{"approvalId":{"type":"string"},"passkeyCredentialId":{"type":"string"},"approvedAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"rpId":{"type":"string"},"origin":{"type":"string"},"challenge":{"type":"string"},"publicKey":{"type":"string"},"assertion":{"type":"object","properties":{"authenticatorData":{"type":"string"},"clientDataJSON":{"type":"string"},"signature":{"type":"string"},"userHandle":{"type":"string"}},"required":["authenticatorData","clientDataJSON","signature"],"additionalProperties":false}},"required":["approvalId","passkeyCredentialId","approvedAt","rpId","origin","challenge","publicKey","assertion"],"additionalProperties":false},{"type":"null"}]},"gateState":{"anyOf":[{"type":"object","properties":{"now":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"spentThisPeriod":{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"},"seenInvoiceHashes":{"type":"array","items":{"type":"string"}},"seenNonces":{"type":"array","items":{"type":"string"}},"revocationBit":{"type":"boolean"},"credentialProofValid":{"type":"boolean"},"stepUpApproved":{"type":"boolean"}},"required":["now","spentThisPeriod","seenInvoiceHashes","seenNonces","revocationBit","credentialProofValid","stepUpApproved"],"additionalProperties":false},{"type":"null"}]},"rail":{"type":["string","null"]},"railRef":{"type":["string","null"]},"railStatus":{"type":["string","null"]},"amount":{"anyOf":[{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"},{"type":"null"}]},"currency":{"type":["string","null"]},"payee":{"anyOf":[{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"iban"},"value":{"type":"string","pattern":"^[A-Z]{2}\\d{2}[A-Z0-9]{11,30}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false},{"type":"object","properties":{"type":{"type":"string","const":"domain"},"value":{"type":"string","pattern":"^(?=.{1,253}$)([a-z0-9-]{1,63}\\.)+[a-z]{2,63}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false}]},{"type":"null"}]},"createdAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"signature":{"type":"string"},"v":{"type":"number","const":2},"mandateSeq":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"mandatePrevHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"agentName":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}]}},"required":["id","prevHash","hash","kind","refId","mandateId","agentId","principalId","intent","intentHash","decision","reasons","stepUp","gateState","rail","railRef","railStatus","amount","currency","payee","createdAt","signature"],"additionalProperties":false}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key"},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/evidence/{id}/nachweis":{"get":{"summary":"Signed nachweis/v1 export (JSON)","tags":["Evidence"],"operationId":"getV1EvidenceIdNachweis","security":[{"bearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"format":{"type":"string","const":"nachweis/v1"},"exportedAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"subject":{"type":"string"},"records":{"minItems":1,"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"prevHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"hash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"kind":{"type":"string","enum":["check","pay","approval","rejection","execution","rail_status","revocation"]},"refId":{"type":["string","null"]},"mandateId":{"type":"string"},"agentId":{"type":["string","null"]},"principalId":{"type":"string"},"intent":{"anyOf":[{"type":"object","properties":{"mandateId":{"type":"string","pattern":"^[0-9A-HJKMNP-TV-Z]{26}$"},"agentId":{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},"amount":{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"},"currency":{"type":"string","pattern":"^[A-Z]{3,5}$"},"payee":{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"iban"},"value":{"type":"string","pattern":"^[A-Z]{2}\\d{2}[A-Z0-9]{11,30}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false},{"type":"object","properties":{"type":{"type":"string","const":"domain"},"value":{"type":"string","pattern":"^(?=.{1,253}$)([a-z0-9-]{1,63}\\.)+[a-z]{2,63}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false}]},"purpose":{"type":"string","minLength":1},"reference":{"default":{},"type":"object","properties":{"po":{"type":"string","minLength":1},"invoiceHash":{"type":"string","pattern":"^sha256:[0-9a-f]{64}$"},"description":{"type":"string","maxLength":255},"resource":{"type":"string","format":"uri"}},"additionalProperties":false},"rail":{"type":"string","minLength":1},"protocol":{"type":"string","enum":["mcp","ap2","tap","acp"]},"mcc":{"type":"string","pattern":"^\\d{4}$"},"nonce":{"type":"string","pattern":"^[A-Za-z0-9_-]{16,64}$"},"createdAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"agentSignature":{"type":"string","minLength":1}},"required":["mandateId","agentId","amount","currency","payee","purpose","reference","rail","protocol","nonce","createdAt","agentSignature"],"additionalProperties":false},{"type":"null"}]},"intentHash":{"type":["string","null"]},"decision":{"anyOf":[{"type":"string","enum":["allow","step_up","deny"]},{"type":"null"}]},"reasons":{"type":"array","items":{"type":"string","enum":["OK","MANDATE_EXPIRED","MANDATE_REVOKED","MANDATE_NOT_YET_VALID","AGENT_MISMATCH","SIGNATURE_INVALID","PAYEE_NOT_ALLOWED","RAIL_NOT_ALLOWED","PURPOSE_NOT_ALLOWED","CAP_PER_TX_EXCEEDED","CAP_PERIOD_EXCEEDED","FOUR_EYES_REQUIRED","PO_MISSING","INVOICE_HASH_MISSING","DUPLICATE_INVOICE","VOP_MISMATCH","MCC_NOT_ALLOWED"]}},"stepUp":{"anyOf":[{"type":"object","properties":{"approvalId":{"type":"string"},"passkeyCredentialId":{"type":"string"},"approvedAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"rpId":{"type":"string"},"origin":{"type":"string"},"challenge":{"type":"string"},"publicKey":{"type":"string"},"assertion":{"type":"object","properties":{"authenticatorData":{"type":"string"},"clientDataJSON":{"type":"string"},"signature":{"type":"string"},"userHandle":{"type":"string"}},"required":["authenticatorData","clientDataJSON","signature"],"additionalProperties":false}},"required":["approvalId","passkeyCredentialId","approvedAt","rpId","origin","challenge","publicKey","assertion"],"additionalProperties":false},{"type":"null"}]},"gateState":{"anyOf":[{"type":"object","properties":{"now":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"spentThisPeriod":{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"},"seenInvoiceHashes":{"type":"array","items":{"type":"string"}},"seenNonces":{"type":"array","items":{"type":"string"}},"revocationBit":{"type":"boolean"},"credentialProofValid":{"type":"boolean"},"stepUpApproved":{"type":"boolean"}},"required":["now","spentThisPeriod","seenInvoiceHashes","seenNonces","revocationBit","credentialProofValid","stepUpApproved"],"additionalProperties":false},{"type":"null"}]},"rail":{"type":["string","null"]},"railRef":{"type":["string","null"]},"railStatus":{"type":["string","null"]},"amount":{"anyOf":[{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"},{"type":"null"}]},"currency":{"type":["string","null"]},"payee":{"anyOf":[{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"iban"},"value":{"type":"string","pattern":"^[A-Z]{2}\\d{2}[A-Z0-9]{11,30}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false},{"type":"object","properties":{"type":{"type":"string","const":"domain"},"value":{"type":"string","pattern":"^(?=.{1,253}$)([a-z0-9-]{1,63}\\.)+[a-z]{2,63}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false}]},{"type":"null"}]},"createdAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"signature":{"type":"string"},"v":{"type":"number","const":2},"mandateSeq":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"mandatePrevHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"agentName":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}]}},"required":["id","prevHash","hash","kind","refId","mandateId","agentId","principalId","intent","intentHash","decision","reasons","stepUp","gateState","rail","railRef","railStatus","amount","currency","payee","createdAt","signature"],"additionalProperties":false}},"credential":{"type":"object","properties":{"@context":{"minItems":2,"type":"array","items":{"anyOf":[{"type":"string"},{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}}]}},"id":{"type":"string","pattern":"^urn:ulid:[0-9A-HJKMNP-TV-Z]{26}$"},"type":{"type":"array","prefixItems":[{"type":"string","const":"VerifiableCredential"},{"type":"string","const":"AgentAuthorityCredential"}],"items":false,"minItems":2,"maxItems":2},"issuer":{"anyOf":[{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},{"type":"string","pattern":"^did:web:[a-z0-9.%:-]+$"}]},"validFrom":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"validUntil":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"credentialStatus":{"type":"object","properties":{"id":{"type":"string"},"type":{"type":"string","const":"BitstringStatusListEntry"},"statusPurpose":{"type":"string","const":"revocation"},"statusListIndex":{"type":"string","pattern":"^\\d+$"},"statusListCredential":{"type":"string","format":"uri"}},"required":["type","statusPurpose","statusListIndex","statusListCredential"],"additionalProperties":false},"credentialSubject":{"type":"object","properties":{"id":{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},"principal":{"type":"object","properties":{"id":{"anyOf":[{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},{"type":"string","pattern":"^did:web:[a-z0-9.%:-]+$"}]},"legalName":{"type":"string","minLength":1},"register":{"type":"string"}},"required":["id","legalName"],"additionalProperties":false},"grantedBy":{"type":"object","properties":{"name":{"type":"string","minLength":1},"role":{"type":"string"},"method":{"type":"string","enum":["passkey","dev-preapproved","demo-unsigned"]}},"required":["name","method"],"additionalProperties":false},"scope":{"type":"object","properties":{"currency":{"type":"string","pattern":"^[A-Z]{3,5}$"},"capPerTx":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"capPeriod":{"type":"object","properties":{"amount":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"period":{"type":"string","pattern":"^P(\\d+)([DWMY])$"}},"required":["amount","period"],"additionalProperties":false},"fourEyesAbove":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"payees":{"minItems":1,"type":"array","items":{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"iban"},"value":{"type":"string","pattern":"^[A-Z]{2}\\d{2}[A-Z0-9]{11,30}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false},{"type":"object","properties":{"type":{"type":"string","const":"domain"},"value":{"type":"string","pattern":"^(?=.{1,253}$)([a-z0-9-]{1,63}\\.)+[a-z]{2,63}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false}]}},"mcc":{"type":"array","items":{"type":"string","pattern":"^\\d{4}$"}},"rails":{"minItems":1,"type":"array","items":{"type":"string","minLength":1}},"purposes":{"minItems":1,"type":"array","items":{"type":"string","minLength":1}},"currencyLimits":{"type":"array","items":{"type":"object","properties":{"currency":{"type":"string","pattern":"^[A-Z]{3,5}$"},"capPerTx":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"capPeriod":{"type":"object","properties":{"amount":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"period":{"type":"string","pattern":"^P(\\d+)([DWMY])$"}},"required":["amount","period"],"additionalProperties":false},"fourEyesAbove":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]}},"required":["currency","capPerTx","capPeriod","fourEyesAbove"],"additionalProperties":false}}},"required":["currency","capPerTx","capPeriod","fourEyesAbove","payees","rails","purposes"],"additionalProperties":false},"b2b":{"type":"object","properties":{"costCentre":{"type":"string"},"poRequired":{"default":false,"type":"boolean"},"invoiceHashRequired":{"default":false,"type":"boolean"},"skontoWindowDays":{"type":"integer","minimum":0,"maximum":9007199254740991}},"required":["poRequired","invoiceHashRequired"],"additionalProperties":false},"delegation":{"type":"object","properties":{"subDelegate":{"type":"boolean"},"maxDepth":{"type":"integer","minimum":0,"maximum":9007199254740991},"parent":{"type":["string","null"]}},"required":["subDelegate","maxDepth","parent"],"additionalProperties":false},"evidence":{"type":"object","properties":{"retainDays":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"exportFormat":{"type":"string","const":"nachweis/v1"}},"required":["retainDays","exportFormat"],"additionalProperties":false}},"required":["id","principal","grantedBy","scope","delegation","evidence"],"additionalProperties":false},"proof":{"type":"object","properties":{"type":{"type":"string","const":"DataIntegrityProof"},"cryptosuite":{"type":"string","const":"eddsa-rdfc-2022"},"verificationMethod":{"type":"string"},"proofPurpose":{"type":"string","const":"assertionMethod"},"proofValue":{"type":"string"},"created":{"type":"string"}},"required":["type","cryptosuite","verificationMethod","proofPurpose","proofValue"],"additionalProperties":{}}},"required":["@context","id","type","issuer","validFrom","validUntil","credentialStatus","credentialSubject"],"additionalProperties":{}},"issuerDidDocument":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}},"server":{"type":"string"},"proof":{"type":"object","properties":{"type":{"type":"string","const":"Ed25519Canonical"},"verificationMethod":{"type":"string"},"signature":{"type":"string"}},"required":["type","verificationMethod","signature"],"additionalProperties":false}},"required":["format","exportedAt","subject","records","credential","server","proof"],"additionalProperties":false}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key"},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/evidence/{id}/nachweis.pdf":{"get":{"summary":"Nachweis as PDF with the signed JSON attached","tags":["Evidence"],"operationId":"getV1EvidenceIdNachweisPdf","security":[{"bearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/pdf":{"schema":{"type":"string","format":"binary"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key"},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/evidence/{id}/proof":{"get":{"summary":"Inclusion proof: the day's Merkle root if published, else the latest hourly checkpoint","tags":["Evidence"],"operationId":"getV1EvidenceIdProof","security":[{"bearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"anyOf":[{"type":"object","properties":{"format":{"type":"string","const":"merkle-proof/v1"},"recordId":{"type":"string"},"recordHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"leafIndex":{"type":"integer","minimum":0,"maximum":9007199254740991},"auditPath":{"type":"array","items":{"type":"string","pattern":"^[0-9a-f]{64}$"}},"root":{"type":"object","properties":{"format":{"type":"string","const":"merkle-root/v1"},"date":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"treeSize":{"type":"integer","minimum":0,"maximum":9007199254740991},"root":{"type":"string","pattern":"^[0-9a-f]{64}$"},"firstRecordId":{"type":["string","null"]},"lastRecordId":{"type":["string","null"]},"publishedAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"server":{"type":"string"},"signature":{"type":"string"}},"required":["format","date","treeSize","root","firstRecordId","lastRecordId","publishedAt","server","signature"],"additionalProperties":false}},"required":["format","recordId","recordHash","leafIndex","auditPath","root"],"additionalProperties":false},{"type":"object","properties":{"format":{"type":"string","const":"merkle-checkpoint-proof/v1"},"recordId":{"type":"string"},"recordHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"leafIndex":{"type":"integer","minimum":0,"maximum":9007199254740991},"auditPath":{"type":"array","items":{"type":"string","pattern":"^[0-9a-f]{64}$"}},"checkpoint":{"type":"object","properties":{"format":{"type":"string","const":"merkle-checkpoint/v1"},"id":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}T\\d{2}$"},"date":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"from":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"to":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"treeSize":{"type":"integer","minimum":0,"maximum":9007199254740991},"root":{"type":"string","pattern":"^[0-9a-f]{64}$"},"firstRecordId":{"type":["string","null"]},"lastRecordId":{"type":["string","null"]},"publishedAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"server":{"type":"string"},"signature":{"type":"string"}},"required":["format","id","date","from","to","treeSize","root","firstRecordId","lastRecordId","publishedAt","server","signature"],"additionalProperties":false}},"required":["format","recordId","recordHash","leafIndex","auditPath","checkpoint"],"additionalProperties":false}]}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key"},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/roots/current":{"get":{"summary":"Latest published hourly checkpoint; isDailyRoot is true once it is the day's T23 checkpoint and the daily root with the same root exists","tags":["Evidence"],"operationId":"getV1RootsCurrent","security":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"checkpoint":{"type":"object","properties":{"format":{"type":"string","const":"merkle-checkpoint/v1"},"id":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}T\\d{2}$"},"date":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"from":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"to":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"treeSize":{"type":"integer","minimum":0,"maximum":9007199254740991},"root":{"type":"string","pattern":"^[0-9a-f]{64}$"},"firstRecordId":{"type":["string","null"]},"lastRecordId":{"type":["string","null"]},"publishedAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"server":{"type":"string"},"signature":{"type":"string"}},"required":["format","id","date","from","to","treeSize","root","firstRecordId","lastRecordId","publishedAt","server","signature"],"additionalProperties":false},"isDailyRoot":{"type":"boolean"},"dailyRoot":{"anyOf":[{"type":"object","properties":{"format":{"type":"string","const":"merkle-root/v1"},"date":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"treeSize":{"type":"integer","minimum":0,"maximum":9007199254740991},"root":{"type":"string","pattern":"^[0-9a-f]{64}$"},"firstRecordId":{"type":["string","null"]},"lastRecordId":{"type":["string","null"]},"publishedAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"server":{"type":"string"},"signature":{"type":"string"}},"required":["format","date","treeSize","root","firstRecordId","lastRecordId","publishedAt","server","signature"],"additionalProperties":false},{"type":"null"}]}},"required":["checkpoint","isDailyRoot","dailyRoot"],"additionalProperties":false}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/roots/checkpoints/latest":{"get":{"summary":"Latest signed hourly checkpoint","tags":["Evidence"],"operationId":"getV1RootsCheckpointsLatest","security":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"format":{"type":"string","const":"merkle-checkpoint/v1"},"id":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}T\\d{2}$"},"date":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"from":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"to":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"treeSize":{"type":"integer","minimum":0,"maximum":9007199254740991},"root":{"type":"string","pattern":"^[0-9a-f]{64}$"},"firstRecordId":{"type":["string","null"]},"lastRecordId":{"type":["string","null"]},"publishedAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"server":{"type":"string"},"signature":{"type":"string"}},"required":["format","id","date","from","to","treeSize","root","firstRecordId","lastRecordId","publishedAt","server","signature"],"additionalProperties":false}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/roots/checkpoints/{id}":{"get":{"summary":"Signed hourly checkpoint (id = YYYY-MM-DDTHH, UTC)","tags":["Evidence"],"operationId":"getV1RootsCheckpointsId","security":[],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"format":{"type":"string","const":"merkle-checkpoint/v1"},"id":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}T\\d{2}$"},"date":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"from":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"to":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"treeSize":{"type":"integer","minimum":0,"maximum":9007199254740991},"root":{"type":"string","pattern":"^[0-9a-f]{64}$"},"firstRecordId":{"type":["string","null"]},"lastRecordId":{"type":["string","null"]},"publishedAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"server":{"type":"string"},"signature":{"type":"string"}},"required":["format","id","date","from","to","treeSize","root","firstRecordId","lastRecordId","publishedAt","server","signature"],"additionalProperties":false}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/session/evidence":{"get":{"summary":"Evidence records of the session's mandate","tags":["Session"],"operationId":"getV1SessionEvidence","security":[{"session":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"mandateId":{"type":"string"},"records":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"prevHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"hash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"kind":{"type":"string","enum":["check","pay","approval","rejection","execution","rail_status","revocation"]},"refId":{"type":["string","null"]},"mandateId":{"type":"string"},"agentId":{"type":["string","null"]},"principalId":{"type":"string"},"intent":{"anyOf":[{"type":"object","properties":{"mandateId":{"type":"string","pattern":"^[0-9A-HJKMNP-TV-Z]{26}$"},"agentId":{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},"amount":{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"},"currency":{"type":"string","pattern":"^[A-Z]{3,5}$"},"payee":{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"iban"},"value":{"type":"string","pattern":"^[A-Z]{2}\\d{2}[A-Z0-9]{11,30}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false},{"type":"object","properties":{"type":{"type":"string","const":"domain"},"value":{"type":"string","pattern":"^(?=.{1,253}$)([a-z0-9-]{1,63}\\.)+[a-z]{2,63}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false}]},"purpose":{"type":"string","minLength":1},"reference":{"default":{},"type":"object","properties":{"po":{"type":"string","minLength":1},"invoiceHash":{"type":"string","pattern":"^sha256:[0-9a-f]{64}$"},"description":{"type":"string","maxLength":255},"resource":{"type":"string","format":"uri"}},"additionalProperties":false},"rail":{"type":"string","minLength":1},"protocol":{"type":"string","enum":["mcp","ap2","tap","acp"]},"mcc":{"type":"string","pattern":"^\\d{4}$"},"nonce":{"type":"string","pattern":"^[A-Za-z0-9_-]{16,64}$"},"createdAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"agentSignature":{"type":"string","minLength":1}},"required":["mandateId","agentId","amount","currency","payee","purpose","reference","rail","protocol","nonce","createdAt","agentSignature"],"additionalProperties":false},{"type":"null"}]},"intentHash":{"type":["string","null"]},"decision":{"anyOf":[{"type":"string","enum":["allow","step_up","deny"]},{"type":"null"}]},"reasons":{"type":"array","items":{"type":"string","enum":["OK","MANDATE_EXPIRED","MANDATE_REVOKED","MANDATE_NOT_YET_VALID","AGENT_MISMATCH","SIGNATURE_INVALID","PAYEE_NOT_ALLOWED","RAIL_NOT_ALLOWED","PURPOSE_NOT_ALLOWED","CAP_PER_TX_EXCEEDED","CAP_PERIOD_EXCEEDED","FOUR_EYES_REQUIRED","PO_MISSING","INVOICE_HASH_MISSING","DUPLICATE_INVOICE","VOP_MISMATCH","MCC_NOT_ALLOWED"]}},"stepUp":{"anyOf":[{"type":"object","properties":{"approvalId":{"type":"string"},"passkeyCredentialId":{"type":"string"},"approvedAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"rpId":{"type":"string"},"origin":{"type":"string"},"challenge":{"type":"string"},"publicKey":{"type":"string"},"assertion":{"type":"object","properties":{"authenticatorData":{"type":"string"},"clientDataJSON":{"type":"string"},"signature":{"type":"string"},"userHandle":{"type":"string"}},"required":["authenticatorData","clientDataJSON","signature"],"additionalProperties":false}},"required":["approvalId","passkeyCredentialId","approvedAt","rpId","origin","challenge","publicKey","assertion"],"additionalProperties":false},{"type":"null"}]},"gateState":{"anyOf":[{"type":"object","properties":{"now":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"spentThisPeriod":{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"},"seenInvoiceHashes":{"type":"array","items":{"type":"string"}},"seenNonces":{"type":"array","items":{"type":"string"}},"revocationBit":{"type":"boolean"},"credentialProofValid":{"type":"boolean"},"stepUpApproved":{"type":"boolean"}},"required":["now","spentThisPeriod","seenInvoiceHashes","seenNonces","revocationBit","credentialProofValid","stepUpApproved"],"additionalProperties":false},{"type":"null"}]},"rail":{"type":["string","null"]},"railRef":{"type":["string","null"]},"railStatus":{"type":["string","null"]},"amount":{"anyOf":[{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"},{"type":"null"}]},"currency":{"type":["string","null"]},"payee":{"anyOf":[{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"iban"},"value":{"type":"string","pattern":"^[A-Z]{2}\\d{2}[A-Z0-9]{11,30}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false},{"type":"object","properties":{"type":{"type":"string","const":"domain"},"value":{"type":"string","pattern":"^(?=.{1,253}$)([a-z0-9-]{1,63}\\.)+[a-z]{2,63}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false}]},{"type":"null"}]},"createdAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"signature":{"type":"string"},"v":{"type":"number","const":2},"mandateSeq":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"mandatePrevHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"agentName":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}]}},"required":["id","prevHash","hash","kind","refId","mandateId","agentId","principalId","intent","intentHash","decision","reasons","stepUp","gateState","rail","railRef","railStatus","amount","currency","payee","createdAt","signature"],"additionalProperties":false}}},"required":["mandateId","records"],"additionalProperties":false}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing, invalid or expired session token"},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/session/evidence/{id}":{"get":{"summary":"Evidence record of the session's mandate","tags":["Session"],"operationId":"getV1SessionEvidenceId","security":[{"session":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"prevHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"hash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"kind":{"type":"string","enum":["check","pay","approval","rejection","execution","rail_status","revocation"]},"refId":{"type":["string","null"]},"mandateId":{"type":"string"},"agentId":{"type":["string","null"]},"principalId":{"type":"string"},"intent":{"anyOf":[{"type":"object","properties":{"mandateId":{"type":"string","pattern":"^[0-9A-HJKMNP-TV-Z]{26}$"},"agentId":{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},"amount":{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"},"currency":{"type":"string","pattern":"^[A-Z]{3,5}$"},"payee":{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"iban"},"value":{"type":"string","pattern":"^[A-Z]{2}\\d{2}[A-Z0-9]{11,30}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false},{"type":"object","properties":{"type":{"type":"string","const":"domain"},"value":{"type":"string","pattern":"^(?=.{1,253}$)([a-z0-9-]{1,63}\\.)+[a-z]{2,63}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false}]},"purpose":{"type":"string","minLength":1},"reference":{"default":{},"type":"object","properties":{"po":{"type":"string","minLength":1},"invoiceHash":{"type":"string","pattern":"^sha256:[0-9a-f]{64}$"},"description":{"type":"string","maxLength":255},"resource":{"type":"string","format":"uri"}},"additionalProperties":false},"rail":{"type":"string","minLength":1},"protocol":{"type":"string","enum":["mcp","ap2","tap","acp"]},"mcc":{"type":"string","pattern":"^\\d{4}$"},"nonce":{"type":"string","pattern":"^[A-Za-z0-9_-]{16,64}$"},"createdAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"agentSignature":{"type":"string","minLength":1}},"required":["mandateId","agentId","amount","currency","payee","purpose","reference","rail","protocol","nonce","createdAt","agentSignature"],"additionalProperties":false},{"type":"null"}]},"intentHash":{"type":["string","null"]},"decision":{"anyOf":[{"type":"string","enum":["allow","step_up","deny"]},{"type":"null"}]},"reasons":{"type":"array","items":{"type":"string","enum":["OK","MANDATE_EXPIRED","MANDATE_REVOKED","MANDATE_NOT_YET_VALID","AGENT_MISMATCH","SIGNATURE_INVALID","PAYEE_NOT_ALLOWED","RAIL_NOT_ALLOWED","PURPOSE_NOT_ALLOWED","CAP_PER_TX_EXCEEDED","CAP_PERIOD_EXCEEDED","FOUR_EYES_REQUIRED","PO_MISSING","INVOICE_HASH_MISSING","DUPLICATE_INVOICE","VOP_MISMATCH","MCC_NOT_ALLOWED"]}},"stepUp":{"anyOf":[{"type":"object","properties":{"approvalId":{"type":"string"},"passkeyCredentialId":{"type":"string"},"approvedAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"rpId":{"type":"string"},"origin":{"type":"string"},"challenge":{"type":"string"},"publicKey":{"type":"string"},"assertion":{"type":"object","properties":{"authenticatorData":{"type":"string"},"clientDataJSON":{"type":"string"},"signature":{"type":"string"},"userHandle":{"type":"string"}},"required":["authenticatorData","clientDataJSON","signature"],"additionalProperties":false}},"required":["approvalId","passkeyCredentialId","approvedAt","rpId","origin","challenge","publicKey","assertion"],"additionalProperties":false},{"type":"null"}]},"gateState":{"anyOf":[{"type":"object","properties":{"now":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"spentThisPeriod":{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"},"seenInvoiceHashes":{"type":"array","items":{"type":"string"}},"seenNonces":{"type":"array","items":{"type":"string"}},"revocationBit":{"type":"boolean"},"credentialProofValid":{"type":"boolean"},"stepUpApproved":{"type":"boolean"}},"required":["now","spentThisPeriod","seenInvoiceHashes","seenNonces","revocationBit","credentialProofValid","stepUpApproved"],"additionalProperties":false},{"type":"null"}]},"rail":{"type":["string","null"]},"railRef":{"type":["string","null"]},"railStatus":{"type":["string","null"]},"amount":{"anyOf":[{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"},{"type":"null"}]},"currency":{"type":["string","null"]},"payee":{"anyOf":[{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"iban"},"value":{"type":"string","pattern":"^[A-Z]{2}\\d{2}[A-Z0-9]{11,30}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false},{"type":"object","properties":{"type":{"type":"string","const":"domain"},"value":{"type":"string","pattern":"^(?=.{1,253}$)([a-z0-9-]{1,63}\\.)+[a-z]{2,63}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false}]},{"type":"null"}]},"createdAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"signature":{"type":"string"},"v":{"type":"number","const":2},"mandateSeq":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"mandatePrevHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"agentName":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}]}},"required":["id","prevHash","hash","kind","refId","mandateId","agentId","principalId","intent","intentHash","decision","reasons","stepUp","gateState","rail","railRef","railStatus","amount","currency","payee","createdAt","signature"],"additionalProperties":false}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing, invalid or expired session token"},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/session/evidence/{id}/nachweis":{"get":{"summary":"Signed nachweis/v1 export","tags":["Session"],"operationId":"getV1SessionEvidenceIdNachweis","security":[{"session":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"format":{"type":"string","const":"nachweis/v1"},"exportedAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"subject":{"type":"string"},"records":{"minItems":1,"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"prevHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"hash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"kind":{"type":"string","enum":["check","pay","approval","rejection","execution","rail_status","revocation"]},"refId":{"type":["string","null"]},"mandateId":{"type":"string"},"agentId":{"type":["string","null"]},"principalId":{"type":"string"},"intent":{"anyOf":[{"type":"object","properties":{"mandateId":{"type":"string","pattern":"^[0-9A-HJKMNP-TV-Z]{26}$"},"agentId":{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},"amount":{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"},"currency":{"type":"string","pattern":"^[A-Z]{3,5}$"},"payee":{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"iban"},"value":{"type":"string","pattern":"^[A-Z]{2}\\d{2}[A-Z0-9]{11,30}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false},{"type":"object","properties":{"type":{"type":"string","const":"domain"},"value":{"type":"string","pattern":"^(?=.{1,253}$)([a-z0-9-]{1,63}\\.)+[a-z]{2,63}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false}]},"purpose":{"type":"string","minLength":1},"reference":{"default":{},"type":"object","properties":{"po":{"type":"string","minLength":1},"invoiceHash":{"type":"string","pattern":"^sha256:[0-9a-f]{64}$"},"description":{"type":"string","maxLength":255},"resource":{"type":"string","format":"uri"}},"additionalProperties":false},"rail":{"type":"string","minLength":1},"protocol":{"type":"string","enum":["mcp","ap2","tap","acp"]},"mcc":{"type":"string","pattern":"^\\d{4}$"},"nonce":{"type":"string","pattern":"^[A-Za-z0-9_-]{16,64}$"},"createdAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"agentSignature":{"type":"string","minLength":1}},"required":["mandateId","agentId","amount","currency","payee","purpose","reference","rail","protocol","nonce","createdAt","agentSignature"],"additionalProperties":false},{"type":"null"}]},"intentHash":{"type":["string","null"]},"decision":{"anyOf":[{"type":"string","enum":["allow","step_up","deny"]},{"type":"null"}]},"reasons":{"type":"array","items":{"type":"string","enum":["OK","MANDATE_EXPIRED","MANDATE_REVOKED","MANDATE_NOT_YET_VALID","AGENT_MISMATCH","SIGNATURE_INVALID","PAYEE_NOT_ALLOWED","RAIL_NOT_ALLOWED","PURPOSE_NOT_ALLOWED","CAP_PER_TX_EXCEEDED","CAP_PERIOD_EXCEEDED","FOUR_EYES_REQUIRED","PO_MISSING","INVOICE_HASH_MISSING","DUPLICATE_INVOICE","VOP_MISMATCH","MCC_NOT_ALLOWED"]}},"stepUp":{"anyOf":[{"type":"object","properties":{"approvalId":{"type":"string"},"passkeyCredentialId":{"type":"string"},"approvedAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"rpId":{"type":"string"},"origin":{"type":"string"},"challenge":{"type":"string"},"publicKey":{"type":"string"},"assertion":{"type":"object","properties":{"authenticatorData":{"type":"string"},"clientDataJSON":{"type":"string"},"signature":{"type":"string"},"userHandle":{"type":"string"}},"required":["authenticatorData","clientDataJSON","signature"],"additionalProperties":false}},"required":["approvalId","passkeyCredentialId","approvedAt","rpId","origin","challenge","publicKey","assertion"],"additionalProperties":false},{"type":"null"}]},"gateState":{"anyOf":[{"type":"object","properties":{"now":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"spentThisPeriod":{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"},"seenInvoiceHashes":{"type":"array","items":{"type":"string"}},"seenNonces":{"type":"array","items":{"type":"string"}},"revocationBit":{"type":"boolean"},"credentialProofValid":{"type":"boolean"},"stepUpApproved":{"type":"boolean"}},"required":["now","spentThisPeriod","seenInvoiceHashes","seenNonces","revocationBit","credentialProofValid","stepUpApproved"],"additionalProperties":false},{"type":"null"}]},"rail":{"type":["string","null"]},"railRef":{"type":["string","null"]},"railStatus":{"type":["string","null"]},"amount":{"anyOf":[{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"},{"type":"null"}]},"currency":{"type":["string","null"]},"payee":{"anyOf":[{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"iban"},"value":{"type":"string","pattern":"^[A-Z]{2}\\d{2}[A-Z0-9]{11,30}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false},{"type":"object","properties":{"type":{"type":"string","const":"domain"},"value":{"type":"string","pattern":"^(?=.{1,253}$)([a-z0-9-]{1,63}\\.)+[a-z]{2,63}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false}]},{"type":"null"}]},"createdAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"signature":{"type":"string"},"v":{"type":"number","const":2},"mandateSeq":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"mandatePrevHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"agentName":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}]}},"required":["id","prevHash","hash","kind","refId","mandateId","agentId","principalId","intent","intentHash","decision","reasons","stepUp","gateState","rail","railRef","railStatus","amount","currency","payee","createdAt","signature"],"additionalProperties":false}},"credential":{"type":"object","properties":{"@context":{"minItems":2,"type":"array","items":{"anyOf":[{"type":"string"},{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}}]}},"id":{"type":"string","pattern":"^urn:ulid:[0-9A-HJKMNP-TV-Z]{26}$"},"type":{"type":"array","prefixItems":[{"type":"string","const":"VerifiableCredential"},{"type":"string","const":"AgentAuthorityCredential"}],"items":false,"minItems":2,"maxItems":2},"issuer":{"anyOf":[{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},{"type":"string","pattern":"^did:web:[a-z0-9.%:-]+$"}]},"validFrom":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"validUntil":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"credentialStatus":{"type":"object","properties":{"id":{"type":"string"},"type":{"type":"string","const":"BitstringStatusListEntry"},"statusPurpose":{"type":"string","const":"revocation"},"statusListIndex":{"type":"string","pattern":"^\\d+$"},"statusListCredential":{"type":"string","format":"uri"}},"required":["type","statusPurpose","statusListIndex","statusListCredential"],"additionalProperties":false},"credentialSubject":{"type":"object","properties":{"id":{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},"principal":{"type":"object","properties":{"id":{"anyOf":[{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},{"type":"string","pattern":"^did:web:[a-z0-9.%:-]+$"}]},"legalName":{"type":"string","minLength":1},"register":{"type":"string"}},"required":["id","legalName"],"additionalProperties":false},"grantedBy":{"type":"object","properties":{"name":{"type":"string","minLength":1},"role":{"type":"string"},"method":{"type":"string","enum":["passkey","dev-preapproved","demo-unsigned"]}},"required":["name","method"],"additionalProperties":false},"scope":{"type":"object","properties":{"currency":{"type":"string","pattern":"^[A-Z]{3,5}$"},"capPerTx":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"capPeriod":{"type":"object","properties":{"amount":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"period":{"type":"string","pattern":"^P(\\d+)([DWMY])$"}},"required":["amount","period"],"additionalProperties":false},"fourEyesAbove":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"payees":{"minItems":1,"type":"array","items":{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"iban"},"value":{"type":"string","pattern":"^[A-Z]{2}\\d{2}[A-Z0-9]{11,30}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false},{"type":"object","properties":{"type":{"type":"string","const":"domain"},"value":{"type":"string","pattern":"^(?=.{1,253}$)([a-z0-9-]{1,63}\\.)+[a-z]{2,63}$"},"name":{"type":"string"}},"required":["type","value"],"additionalProperties":false}]}},"mcc":{"type":"array","items":{"type":"string","pattern":"^\\d{4}$"}},"rails":{"minItems":1,"type":"array","items":{"type":"string","minLength":1}},"purposes":{"minItems":1,"type":"array","items":{"type":"string","minLength":1}},"currencyLimits":{"type":"array","items":{"type":"object","properties":{"currency":{"type":"string","pattern":"^[A-Z]{3,5}$"},"capPerTx":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"capPeriod":{"type":"object","properties":{"amount":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"period":{"type":"string","pattern":"^P(\\d+)([DWMY])$"}},"required":["amount","period"],"additionalProperties":false},"fourEyesAbove":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]}},"required":["currency","capPerTx","capPeriod","fourEyesAbove"],"additionalProperties":false}}},"required":["currency","capPerTx","capPeriod","fourEyesAbove","payees","rails","purposes"],"additionalProperties":false},"b2b":{"type":"object","properties":{"costCentre":{"type":"string"},"poRequired":{"default":false,"type":"boolean"},"invoiceHashRequired":{"default":false,"type":"boolean"},"skontoWindowDays":{"type":"integer","minimum":0,"maximum":9007199254740991}},"required":["poRequired","invoiceHashRequired"],"additionalProperties":false},"delegation":{"type":"object","properties":{"subDelegate":{"type":"boolean"},"maxDepth":{"type":"integer","minimum":0,"maximum":9007199254740991},"parent":{"type":["string","null"]}},"required":["subDelegate","maxDepth","parent"],"additionalProperties":false},"evidence":{"type":"object","properties":{"retainDays":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"exportFormat":{"type":"string","const":"nachweis/v1"}},"required":["retainDays","exportFormat"],"additionalProperties":false}},"required":["id","principal","grantedBy","scope","delegation","evidence"],"additionalProperties":false},"proof":{"type":"object","properties":{"type":{"type":"string","const":"DataIntegrityProof"},"cryptosuite":{"type":"string","const":"eddsa-rdfc-2022"},"verificationMethod":{"type":"string"},"proofPurpose":{"type":"string","const":"assertionMethod"},"proofValue":{"type":"string"},"created":{"type":"string"}},"required":["type","cryptosuite","verificationMethod","proofPurpose","proofValue"],"additionalProperties":{}}},"required":["@context","id","type","issuer","validFrom","validUntil","credentialStatus","credentialSubject"],"additionalProperties":{}},"issuerDidDocument":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}},"server":{"type":"string"},"proof":{"type":"object","properties":{"type":{"type":"string","const":"Ed25519Canonical"},"verificationMethod":{"type":"string"},"signature":{"type":"string"}},"required":["type","verificationMethod","signature"],"additionalProperties":false}},"required":["format","exportedAt","subject","records","credential","server","proof"],"additionalProperties":false}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing, invalid or expired session token"},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/session/evidence/{id}/nachweis.pdf":{"get":{"summary":"Nachweis as PDF","tags":["Session"],"operationId":"getV1SessionEvidenceIdNachweisPdf","security":[{"session":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/pdf":{"schema":{"type":"string","format":"binary"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing, invalid or expired session token"},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/session/evidence/{id}/proof":{"get":{"summary":"Inclusion proof (daily root or hourly checkpoint)","tags":["Session"],"operationId":"getV1SessionEvidenceIdProof","security":[{"session":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"anyOf":[{"type":"object","properties":{"format":{"type":"string","const":"merkle-proof/v1"},"recordId":{"type":"string"},"recordHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"leafIndex":{"type":"integer","minimum":0,"maximum":9007199254740991},"auditPath":{"type":"array","items":{"type":"string","pattern":"^[0-9a-f]{64}$"}},"root":{"type":"object","properties":{"format":{"type":"string","const":"merkle-root/v1"},"date":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"treeSize":{"type":"integer","minimum":0,"maximum":9007199254740991},"root":{"type":"string","pattern":"^[0-9a-f]{64}$"},"firstRecordId":{"type":["string","null"]},"lastRecordId":{"type":["string","null"]},"publishedAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"server":{"type":"string"},"signature":{"type":"string"}},"required":["format","date","treeSize","root","firstRecordId","lastRecordId","publishedAt","server","signature"],"additionalProperties":false}},"required":["format","recordId","recordHash","leafIndex","auditPath","root"],"additionalProperties":false},{"type":"object","properties":{"format":{"type":"string","const":"merkle-checkpoint-proof/v1"},"recordId":{"type":"string"},"recordHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"leafIndex":{"type":"integer","minimum":0,"maximum":9007199254740991},"auditPath":{"type":"array","items":{"type":"string","pattern":"^[0-9a-f]{64}$"}},"checkpoint":{"type":"object","properties":{"format":{"type":"string","const":"merkle-checkpoint/v1"},"id":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}T\\d{2}$"},"date":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"from":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"to":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"treeSize":{"type":"integer","minimum":0,"maximum":9007199254740991},"root":{"type":"string","pattern":"^[0-9a-f]{64}$"},"firstRecordId":{"type":["string","null"]},"lastRecordId":{"type":["string","null"]},"publishedAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"server":{"type":"string"},"signature":{"type":"string"}},"required":["format","id","date","from","to","treeSize","root","firstRecordId","lastRecordId","publishedAt","server","signature"],"additionalProperties":false}},"required":["format","recordId","recordHash","leafIndex","auditPath","checkpoint"],"additionalProperties":false}]}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing, invalid or expired session token"},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/public/evidence":{"get":{"summary":"Public feed of demo-tenant evidence (public fields only). Newest first with cursor; oldest first with since; date = one UTC day","tags":["Public"],"operationId":"getV1PublicEvidence","security":[],"parameters":[{"name":"cursor","in":"query","required":false,"schema":{"type":"string"}},{"name":"since","in":"query","required":false,"schema":{"type":"string"}},{"name":"date","in":"query","required":false,"schema":{"type":"string"}},{"name":"limit","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"records":{"type":"array","items":{"type":"object","properties":{"cursor":{"type":"string"},"hash":{"type":"string"},"prevHash":{"type":"string"},"kind":{"type":"string","enum":["store_purchase","agent_to_agent","revocation","execution"]},"recordKind":{"type":"string"},"decision":{"type":["string","null"]},"reasons":{"type":"array","items":{"type":"string"}},"rail":{"type":["string","null"]},"createdAt":{"type":"string"},"agentId":{"type":["string","null"]},"agentName":{"anyOf":[{"type":"object","properties":{"value":{"type":"string"},"selfDeclared":{"type":"boolean","const":true}},"required":["value","selfDeclared"],"additionalProperties":false},{"type":"null"}]},"counterparty":{"type":["string","null"]},"currency":{"type":["string","null"]},"amountBucket":{"type":["string","null"]},"amount":{"type":"object","properties":{"value":{"type":"string"},"currency":{"type":"string"}},"required":["value","currency"],"additionalProperties":false},"amountExact":{"type":"boolean"},"outcome":{"type":["string","null"]},"signed":{"type":"boolean"},"mandateId":{"type":["string","null"]},"delegationParent":{"type":["string","null"]},"mandateSeq":{"type":["number","null"]},"mandatePrevHash":{"type":["string","null"]}},"required":["cursor","hash","prevHash","kind","recordKind","decision","reasons","rail","createdAt","agentId","agentName","counterparty","currency","amountBucket","amountExact","outcome","signed","mandateId","delegationParent","mandateSeq","mandatePrevHash"],"additionalProperties":false}},"nextCursor":{"type":["string","null"]},"more":{"description":"with since: a full page came back","type":"boolean"}},"required":["records","nextCursor"],"additionalProperties":false}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/public/stream":{"get":{"summary":"Server-sent events: stats (snapshot), record (id = cursor), stats_delta, heartbeat (15 s), gap. Resumes after Last-Event-ID or ?since=","tags":["Public"],"operationId":"getV1PublicStream","security":[],"parameters":[{"name":"since","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"text/event-stream":{"schema":{"type":"string","format":"binary"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/public/health/rails":{"get":{"summary":"Demo rail health: mode test|live and status ok|degraded|down, probed at most every 60 s","tags":["Public"],"operationId":"getV1PublicHealthRails","security":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"rails":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"mode":{"type":"string","enum":["test","live"]},"status":{"type":"string","enum":["ok","degraded","down"]},"checkedAt":{"type":"string"}},"required":["id","mode","status","checkedAt"],"additionalProperties":false}}},"required":["rails"],"additionalProperties":false}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/public/stats":{"get":{"summary":"Demo decisions since launch, revocations, agent-to-agent payments, delegations, active fleet agents and the breach counter","tags":["Public"],"operationId":"getV1PublicStats","security":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"since":{"type":["string","null"]},"records":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"decisions":{"type":"object","properties":{"allow":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"step_up":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"deny":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"total":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["allow","step_up","deny","total"],"additionalProperties":false},"decisionsToday":{"type":"object","properties":{"allow":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"step_up":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"deny":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"total":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["allow","step_up","deny","total"],"additionalProperties":false,"description":"the same counts for the current UTC day"},"revoked":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"agentToAgent":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"delegations":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"fleetAgentsActive":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991,"description":"fleet agents with a record in the last 5 minutes"},"breaches":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"breachDefinition":{"type":"string"},"generatedAt":{"type":"string"}},"required":["since","records","decisions","decisionsToday","revoked","agentToAgent","delegations","fleetAgentsActive","breaches","breachDefinition","generatedAt"],"additionalProperties":false}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/public/keys":{"get":{"summary":"Published server key (evidence, Nachweis, roots and checkpoints)","tags":["Public"],"operationId":"getV1PublicKeys","security":[],"responses":{"200":{"description":"OK"},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/public/verify":{"post":{"summary":"Verify a Nachweis against the published server key (stateless, rate-limited)","tags":["Public"],"operationId":"postV1PublicVerify","security":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"format":{"type":"string","const":"nachweis/v1"},"exportedAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"subject":{"type":"string"},"records":{"minItems":1,"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"prevHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"hash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"kind":{"type":"string","enum":["check","pay","approval","rejection","execution","rail_status","revocation"]},"refId":{"type":["string","null"]},"mandateId":{"type":"string"},"agentId":{"type":["string","null"]},"principalId":{"type":"string"},"intent":{"anyOf":[{"type":"object","properties":{"mandateId":{"type":"string","pattern":"^[0-9A-HJKMNP-TV-Z]{26}$"},"agentId":{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},"amount":{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"},"currency":{"type":"string","pattern":"^[A-Z]{3,5}$"},"payee":{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"iban"},"value":{"type":"string","pattern":"^[A-Z]{2}\\d{2}[A-Z0-9]{11,30}$"},"name":{"type":"string"}},"required":["type","value"]},{"type":"object","properties":{"type":{"type":"string","const":"domain"},"value":{"type":"string","pattern":"^(?=.{1,253}$)([a-z0-9-]{1,63}\\.)+[a-z]{2,63}$"},"name":{"type":"string"}},"required":["type","value"]}]},"purpose":{"type":"string","minLength":1},"reference":{"default":{},"type":"object","properties":{"po":{"type":"string","minLength":1},"invoiceHash":{"type":"string","pattern":"^sha256:[0-9a-f]{64}$"},"description":{"type":"string","maxLength":255},"resource":{"type":"string","format":"uri"}}},"rail":{"type":"string","minLength":1},"protocol":{"type":"string","enum":["mcp","ap2","tap","acp"]},"mcc":{"type":"string","pattern":"^\\d{4}$"},"nonce":{"type":"string","pattern":"^[A-Za-z0-9_-]{16,64}$"},"createdAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"agentSignature":{"type":"string","minLength":1}},"required":["mandateId","agentId","amount","currency","payee","purpose","rail","protocol","nonce","createdAt","agentSignature"]},{"type":"null"}]},"intentHash":{"type":["string","null"]},"decision":{"anyOf":[{"type":"string","enum":["allow","step_up","deny"]},{"type":"null"}]},"reasons":{"type":"array","items":{"type":"string","enum":["OK","MANDATE_EXPIRED","MANDATE_REVOKED","MANDATE_NOT_YET_VALID","AGENT_MISMATCH","SIGNATURE_INVALID","PAYEE_NOT_ALLOWED","RAIL_NOT_ALLOWED","PURPOSE_NOT_ALLOWED","CAP_PER_TX_EXCEEDED","CAP_PERIOD_EXCEEDED","FOUR_EYES_REQUIRED","PO_MISSING","INVOICE_HASH_MISSING","DUPLICATE_INVOICE","VOP_MISMATCH","MCC_NOT_ALLOWED"]}},"stepUp":{"anyOf":[{"type":"object","properties":{"approvalId":{"type":"string"},"passkeyCredentialId":{"type":"string"},"approvedAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"rpId":{"type":"string"},"origin":{"type":"string"},"challenge":{"type":"string"},"publicKey":{"type":"string"},"assertion":{"type":"object","properties":{"authenticatorData":{"type":"string"},"clientDataJSON":{"type":"string"},"signature":{"type":"string"},"userHandle":{"type":"string"}},"required":["authenticatorData","clientDataJSON","signature"]}},"required":["approvalId","passkeyCredentialId","approvedAt","rpId","origin","challenge","publicKey","assertion"]},{"type":"null"}]},"gateState":{"anyOf":[{"type":"object","properties":{"now":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"spentThisPeriod":{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"},"seenInvoiceHashes":{"type":"array","items":{"type":"string"}},"seenNonces":{"type":"array","items":{"type":"string"}},"revocationBit":{"type":"boolean"},"credentialProofValid":{"type":"boolean"},"stepUpApproved":{"type":"boolean"}},"required":["now","spentThisPeriod","seenInvoiceHashes","seenNonces","revocationBit","credentialProofValid","stepUpApproved"]},{"type":"null"}]},"rail":{"type":["string","null"]},"railRef":{"type":["string","null"]},"railStatus":{"type":["string","null"]},"amount":{"anyOf":[{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"},{"type":"null"}]},"currency":{"type":["string","null"]},"payee":{"anyOf":[{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"iban"},"value":{"type":"string","pattern":"^[A-Z]{2}\\d{2}[A-Z0-9]{11,30}$"},"name":{"type":"string"}},"required":["type","value"]},{"type":"object","properties":{"type":{"type":"string","const":"domain"},"value":{"type":"string","pattern":"^(?=.{1,253}$)([a-z0-9-]{1,63}\\.)+[a-z]{2,63}$"},"name":{"type":"string"}},"required":["type","value"]}]},{"type":"null"}]},"createdAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"signature":{"type":"string"},"v":{"type":"number","const":2},"mandateSeq":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"mandatePrevHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"agentName":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}]}},"required":["id","prevHash","hash","kind","refId","mandateId","agentId","principalId","intent","intentHash","decision","reasons","stepUp","gateState","rail","railRef","railStatus","amount","currency","payee","createdAt","signature"]}},"credential":{"type":"object","properties":{"@context":{"minItems":2,"type":"array","items":{"anyOf":[{"type":"string"},{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}}]}},"id":{"type":"string","pattern":"^urn:ulid:[0-9A-HJKMNP-TV-Z]{26}$"},"type":{"type":"array","prefixItems":[{"type":"string","const":"VerifiableCredential"},{"type":"string","const":"AgentAuthorityCredential"}],"items":false,"minItems":2,"maxItems":2},"issuer":{"anyOf":[{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},{"type":"string","pattern":"^did:web:[a-z0-9.%:-]+$"}]},"validFrom":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"validUntil":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"credentialStatus":{"type":"object","properties":{"id":{"type":"string"},"type":{"type":"string","const":"BitstringStatusListEntry"},"statusPurpose":{"type":"string","const":"revocation"},"statusListIndex":{"type":"string","pattern":"^\\d+$"},"statusListCredential":{"type":"string","format":"uri"}},"required":["type","statusPurpose","statusListIndex","statusListCredential"]},"credentialSubject":{"type":"object","properties":{"id":{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},"principal":{"type":"object","properties":{"id":{"anyOf":[{"type":"string","pattern":"^did:key:z[1-9A-HJ-NP-Za-km-z]+$"},{"type":"string","pattern":"^did:web:[a-z0-9.%:-]+$"}]},"legalName":{"type":"string","minLength":1},"register":{"type":"string"}},"required":["id","legalName"]},"grantedBy":{"type":"object","properties":{"name":{"type":"string","minLength":1},"role":{"type":"string"},"method":{"type":"string","enum":["passkey","dev-preapproved","demo-unsigned"]}},"required":["name","method"]},"scope":{"type":"object","properties":{"currency":{"type":"string","pattern":"^[A-Z]{3,5}$"},"capPerTx":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"capPeriod":{"type":"object","properties":{"amount":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"period":{"type":"string","pattern":"^P(\\d+)([DWMY])$"}},"required":["amount","period"]},"fourEyesAbove":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"payees":{"minItems":1,"type":"array","items":{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"iban"},"value":{"type":"string","pattern":"^[A-Z]{2}\\d{2}[A-Z0-9]{11,30}$"},"name":{"type":"string"}},"required":["type","value"]},{"type":"object","properties":{"type":{"type":"string","const":"domain"},"value":{"type":"string","pattern":"^(?=.{1,253}$)([a-z0-9-]{1,63}\\.)+[a-z]{2,63}$"},"name":{"type":"string"}},"required":["type","value"]}]}},"mcc":{"type":"array","items":{"type":"string","pattern":"^\\d{4}$"}},"rails":{"minItems":1,"type":"array","items":{"type":"string","minLength":1}},"purposes":{"minItems":1,"type":"array","items":{"type":"string","minLength":1}},"currencyLimits":{"type":"array","items":{"type":"object","properties":{"currency":{"type":"string","pattern":"^[A-Z]{3,5}$"},"capPerTx":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"capPeriod":{"type":"object","properties":{"amount":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]},"period":{"type":"string","pattern":"^P(\\d+)([DWMY])$"}},"required":["amount","period"]},"fourEyesAbove":{"anyOf":[{"type":"number","minimum":0},{"type":"string","pattern":"^(0|[1-9]\\d{0,15})\\.\\d{2}$"}]}},"required":["currency","capPerTx","capPeriod","fourEyesAbove"]}}},"required":["currency","capPerTx","capPeriod","fourEyesAbove","payees","rails","purposes"]},"b2b":{"type":"object","properties":{"costCentre":{"type":"string"},"poRequired":{"default":false,"type":"boolean"},"invoiceHashRequired":{"default":false,"type":"boolean"},"skontoWindowDays":{"type":"integer","minimum":0,"maximum":9007199254740991}}},"delegation":{"type":"object","properties":{"subDelegate":{"type":"boolean"},"maxDepth":{"type":"integer","minimum":0,"maximum":9007199254740991},"parent":{"type":["string","null"]}},"required":["subDelegate","maxDepth","parent"]},"evidence":{"type":"object","properties":{"retainDays":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"exportFormat":{"type":"string","const":"nachweis/v1"}},"required":["retainDays","exportFormat"]}},"required":["id","principal","grantedBy","scope","delegation","evidence"]},"proof":{"type":"object","properties":{"type":{"type":"string","const":"DataIntegrityProof"},"cryptosuite":{"type":"string","const":"eddsa-rdfc-2022"},"verificationMethod":{"type":"string"},"proofPurpose":{"type":"string","const":"assertionMethod"},"proofValue":{"type":"string"},"created":{"type":"string"}},"required":["type","cryptosuite","verificationMethod","proofPurpose","proofValue"],"additionalProperties":{}}},"required":["@context","id","type","issuer","validFrom","validUntil","credentialStatus","credentialSubject"],"additionalProperties":{}},"issuerDidDocument":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}},"server":{"type":"string"},"proof":{"type":"object","properties":{"type":{"type":"string","const":"Ed25519Canonical"},"verificationMethod":{"type":"string"},"signature":{"type":"string"}},"required":["type","verificationMethod","signature"]}},"required":["format","exportedAt","subject","records","credential","server","proof"]}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"valid":{"type":"boolean"},"serverKey":{"type":"object","properties":{"published":{"type":"string"},"inFile":{"type":["string","null"]},"matches":{"type":"boolean"}},"required":["published","inFile","matches"],"additionalProperties":false},"exportSignature":{"type":"string","enum":["OK","FAIL"]},"links":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"kind":{"type":"string"},"hashVersion":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"hash":{"type":"string","enum":["OK","FAIL"]},"signature":{"type":"string","enum":["OK","FAIL"]}},"required":["id","kind","hashVersion","hash","signature"],"additionalProperties":false}},"errors":{"type":"array","items":{"type":"string"}},"warnings":{"type":"array","items":{"type":"string"}}},"required":["valid","serverKey","exportSignature","links","errors","warnings"],"additionalProperties":false}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/roots/{date}":{"get":{"summary":"Signed daily Merkle root","tags":["Evidence"],"operationId":"getV1RootsDate","security":[],"parameters":[{"name":"date","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"format":{"type":"string","const":"merkle-root/v1"},"date":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"treeSize":{"type":"integer","minimum":0,"maximum":9007199254740991},"root":{"type":"string","pattern":"^[0-9a-f]{64}$"},"firstRecordId":{"type":["string","null"]},"lastRecordId":{"type":["string","null"]},"publishedAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"server":{"type":"string"},"signature":{"type":"string"}},"required":["format","date","treeSize","root","firstRecordId","lastRecordId","publishedAt","server","signature"],"additionalProperties":false}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/evidence/roots/{date}":{"get":{"summary":"Signed daily Merkle root (spec path)","tags":["Evidence"],"operationId":"getV1EvidenceRootsDate","security":[],"parameters":[{"name":"date","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"format":{"type":"string","const":"merkle-root/v1"},"date":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"treeSize":{"type":"integer","minimum":0,"maximum":9007199254740991},"root":{"type":"string","pattern":"^[0-9a-f]{64}$"},"firstRecordId":{"type":["string","null"]},"lastRecordId":{"type":["string","null"]},"publishedAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"server":{"type":"string"},"signature":{"type":"string"}},"required":["format","date","treeSize","root","firstRecordId","lastRecordId","publishedAt","server","signature"],"additionalProperties":false}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/adapters/ap2/mandate":{"post":{"summary":"AP2 Intent/Cart/Payment mandates for an allowed intent","tags":["Adapters"],"operationId":"postV1AdaptersAp2Mandate","security":[{"bearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"mandateId":{"type":"string"},"evidenceId":{"type":"string"},"cart":{"type":"object","properties":{"id":{"type":"string"},"merchantName":{"type":"string"},"items":{"minItems":1,"type":"array","items":{"type":"object","properties":{"label":{"type":"string"},"amount":{"type":"string","pattern":"^\\d+\\.\\d{2}$"}},"required":["label","amount"]}}},"required":["items"]}},"required":["mandateId","evidenceId"]}}}},"responses":{"200":{"description":"OK"},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key"},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}},"/v1/webhooks/mollie":{"post":{"summary":"Mollie payment status webhook (id=tr_…)","tags":["Adapters"],"operationId":"postV1WebhooksMollie","security":[],"requestBody":{"required":true,"content":{"application/x-www-form-urlencoded":{"schema":{"type":"object"}}}},"responses":{"200":{"description":"OK"},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limited"}}}}}}
