{"openapi":"3.1.0","info":{"title":"XCS reference read API","version":"0.1.0-alpha.1"},"paths":{"/health/live":{"get":{"responses":{"200":{"description":"200 response"}}}},"/health":{"get":{"responses":{"200":{"description":"200 response"}}}},"/health/ready":{"get":{"responses":{"200":{"description":"200 response"}}}},"/v1/networks":{"get":{"responses":{"200":{"description":"200 response"}}}},"/v1/networks/{network}/status":{"get":{"parameters":[{"name":"network","in":"path","required":true,"schema":{"type":"string","pattern":"^[a-z0-9][a-z0-9._-]{0,127}$"}}],"responses":{"200":{"description":"200 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["profileId","state","sourceTips","lastAgreedLedger","errorCode","updatedAt"],"properties":{"profileId":{"type":"string","pattern":"^[a-z0-9][a-z0-9._-]{0,127}$"},"state":{"type":"string","enum":["starting","catching_up","ready","halted"]},"sourceTips":{"type":"object","additionalProperties":false,"required":["primary","secondary"],"properties":{"primary":{"type":"integer","nullable":true,"minimum":0,"maximum":4294967295},"secondary":{"type":"integer","nullable":true,"minimum":0,"maximum":4294967295}}},"lastAgreedLedger":{"anyOf":[{"type":"object","additionalProperties":false,"required":["index","hash"],"properties":{"index":{"type":"integer","minimum":0,"maximum":4294967295},"hash":{"type":"string","pattern":"^[0-9a-f]{64}$"}}},{"type":"null"}]},"errorCode":{"type":"string","nullable":true,"pattern":"^[A-Z][A-Z0-9_]{0,63}$"},"updatedAt":{"type":"string","format":"date-time"}}}}}},"404":{"description":"404 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}}}}},"/v1/networks/{network}/readiness":{"get":{"parameters":[{"name":"network","in":"path","required":true,"schema":{"type":"string","pattern":"^[a-z0-9][a-z0-9._-]{0,127}$"}}],"responses":{"200":{"description":"200 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["profileId","status","checkpoint"],"properties":{"profileId":{"type":"string","pattern":"^[a-z0-9][a-z0-9._-]{0,127}$"},"status":{"type":"string","enum":["ready"]},"checkpoint":{"type":"object","additionalProperties":false,"required":["ledgerIndex","ledgerHash","closeTime","transactionRoot"],"properties":{"ledgerIndex":{"type":"integer","minimum":0,"maximum":4294967295},"ledgerHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"closeTime":{"type":"integer","minimum":0,"maximum":4294967295},"transactionRoot":{"type":"string","pattern":"^[0-9a-f]{64}$"}}}}}}}},"400":{"description":"400 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"404":{"description":"404 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"429":{"description":"429 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["statusCode","error","message"],"properties":{"statusCode":{"type":"integer","const":429},"error":{"type":"string"},"message":{"type":"string"}}}}}},"500":{"description":"500 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"503":{"description":"503 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}}}}},"/v1/networks/{network}/stats":{"get":{"parameters":[{"name":"network","in":"path","required":true,"schema":{"type":"string","pattern":"^[a-z0-9][a-z0-9._-]{0,127}$"}}],"responses":{"200":{"description":"200 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["network","schemas","credentialGenerations","checkpoint"],"properties":{"network":{"type":"string","pattern":"^[a-z0-9][a-z0-9._-]{0,127}$"},"schemas":{"type":"object","additionalProperties":false,"required":["total","publishers"],"properties":{"total":{"type":"integer","minimum":0},"publishers":{"type":"integer","minimum":0}}},"credentialGenerations":{"type":"object","additionalProperties":false,"required":["total","pending","active","expired","deleted"],"properties":{"total":{"type":"integer","minimum":0},"pending":{"type":"integer","minimum":0},"active":{"type":"integer","minimum":0},"expired":{"type":"integer","minimum":0},"deleted":{"type":"integer","minimum":0}}},"checkpoint":{"type":"object","additionalProperties":false,"required":["ledgerIndex","ledgerHash","closeTime","transactionRoot"],"properties":{"ledgerIndex":{"type":"integer","minimum":0,"maximum":4294967295},"ledgerHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"closeTime":{"type":"integer","minimum":0,"maximum":4294967295},"transactionRoot":{"type":"string","pattern":"^[0-9a-f]{64}$"}}}}}}}},"400":{"description":"400 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"404":{"description":"404 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"503":{"description":"503 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}}}}},"/v1/networks/{network}/search":{"get":{"parameters":[{"name":"network","in":"path","required":true,"schema":{"type":"string","pattern":"^[a-z0-9][a-z0-9._-]{0,127}$"}},{"name":"q","in":"query","required":true,"schema":{"type":"string","minLength":2,"maxLength":128}},{"name":"limit","in":"query","required":false,"schema":{"type":"string","pattern":"^(?:[1-9]|[1-4][0-9]|50)$"}}],"responses":{"200":{"description":"200 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["items","hasMore"],"properties":{"items":{"type":"array","items":{"anyOf":[{"type":"object","additionalProperties":false,"required":["type","schemaUid","publisher","name","description","parentUid","supersedesUid","registrationTransactionHash","ledgerIndex","transactionIndex"],"properties":{"type":{"type":"string","const":"schema"},"schemaUid":{"type":"string","pattern":"^[0-9a-f]{64}$"},"publisher":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"},"name":{"type":"string"},"description":{"type":"string"},"parentUid":{"anyOf":[{"type":"string","pattern":"^[0-9a-f]{64}$"},{"type":"null"}]},"supersedesUid":{"anyOf":[{"type":"string","pattern":"^[0-9a-f]{64}$"},{"type":"null"}]},"registrationTransactionHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"ledgerIndex":{"type":"integer","minimum":0,"maximum":4294967295},"transactionIndex":{"type":"integer","minimum":0}}},{"type":"object","additionalProperties":false,"required":["type","generationId","issuer","subject","schemaUid","state","createdLedgerIndex","lastLedgerIndex"],"properties":{"type":{"type":"string","const":"credential_generation"},"generationId":{"type":"string","pattern":"^[0-9a-f]{64}$"},"issuer":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"},"subject":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"},"schemaUid":{"type":"string","pattern":"^[0-9a-f]{64}$"},"state":{"type":"string","enum":["pending","active","expired","deleted"]},"createdLedgerIndex":{"type":"integer","minimum":0,"maximum":4294967295},"lastLedgerIndex":{"type":"integer","minimum":0,"maximum":4294967295}}},{"type":"object","additionalProperties":false,"required":["type","transactionHash","ledgerIndex","ledgerHash","transactionIndex","registrationStatus","credentialEventCount"],"properties":{"type":{"type":"string","const":"transaction"},"transactionHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"ledgerIndex":{"type":"integer","minimum":0,"maximum":4294967295},"ledgerHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"transactionIndex":{"type":"integer","minimum":0},"registrationStatus":{"anyOf":[{"type":"string","enum":["accepted","rejected"]},{"type":"null"}]},"credentialEventCount":{"type":"integer","minimum":0}}}]}},"hasMore":{"type":"boolean"}}}}}},"400":{"description":"400 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"404":{"description":"404 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"503":{"description":"503 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}}}}},"/v1/networks/{network}/activity":{"get":{"parameters":[{"name":"network","in":"path","required":true,"schema":{"type":"string","pattern":"^[a-z0-9][a-z0-9._-]{0,127}$"}},{"name":"cursor","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":512}},{"name":"limit","in":"query","required":false,"schema":{"type":"string","pattern":"^(?:[1-9]|[1-9][0-9]|100)$"}}],"responses":{"200":{"description":"200 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["items"],"properties":{"items":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["transactionHash","status","publisher","ledgerIndex","ledgerHash","transactionIndex","schemaUid","schemaDigestHex","reasonCode"],"properties":{"transactionHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"status":{"type":"string","enum":["accepted","rejected"]},"publisher":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"},"ledgerIndex":{"type":"integer","minimum":0,"maximum":4294967295},"ledgerHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"transactionIndex":{"type":"integer","minimum":0},"schemaUid":{"anyOf":[{"type":"string","pattern":"^[0-9a-f]{64}$"},{"type":"null"}]},"schemaDigestHex":{"anyOf":[{"type":"string","pattern":"^[0-9a-f]{64}$"},{"type":"null"}]},"reasonCode":{"anyOf":[{"type":"string","minLength":1,"maxLength":128},{"type":"null"}]}}}},"nextCursor":{"type":"string"}}}}}},"400":{"description":"400 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"404":{"description":"404 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"503":{"description":"503 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}}}}},"/v1/networks/{network}/credential-generations/{generationId}":{"get":{"parameters":[{"name":"network","in":"path","required":true,"schema":{"type":"string","pattern":"^[a-z0-9][a-z0-9._-]{0,127}$"}},{"name":"generationId","in":"path","required":true,"schema":{"type":"string","pattern":"^[0-9A-Fa-f]{64}$"}}],"responses":{"200":{"description":"200 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["generation","state","timeline"],"properties":{"generation":{"type":"object","additionalProperties":false,"required":["generationId","ledgerObjectId","issuer","subject","schemaUid","uriHex","expiration","accepted","createdLedgerIndex","createdTransactionIndex","lastLedgerIndex","deletedLedgerIndex","deletionCause"],"properties":{"generationId":{"type":"string","pattern":"^[0-9a-f]{64}$"},"ledgerObjectId":{"type":"string","pattern":"^[0-9a-f]{64}$"},"issuer":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"},"subject":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"},"schemaUid":{"type":"string","pattern":"^[0-9a-f]{64}$"},"uriHex":{"anyOf":[{"type":"string","pattern":"^(?:[0-9A-Fa-f]{2})*$"},{"type":"null"}]},"expiration":{"anyOf":[{"type":"integer","minimum":0,"maximum":4294967295},{"type":"null"}]},"accepted":{"type":"boolean"},"createdLedgerIndex":{"type":"integer","minimum":0,"maximum":4294967295},"createdTransactionIndex":{"type":"integer","minimum":0},"lastLedgerIndex":{"type":"integer","minimum":0,"maximum":4294967295},"deletedLedgerIndex":{"anyOf":[{"type":"integer","minimum":0,"maximum":4294967295},{"type":"null"}]},"deletionCause":{"anyOf":[{"type":"string","enum":["issuer_revoked","subject_rejected","subject_removed","expired_cleanup","account_deleted","self_deleted"]},{"type":"null"}]}}},"state":{"type":"string","enum":["pending","active","expired","deleted"]},"timeline":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["transactionHash","nodeIndex","generationId","ledgerIndex","ledgerHash","transactionIndex","eventType","issuer","subject","schemaUid","accepted","deletionCause"],"properties":{"transactionHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"nodeIndex":{"type":"integer","minimum":0},"generationId":{"type":"string","pattern":"^[0-9a-f]{64}$"},"ledgerIndex":{"type":"integer","minimum":0,"maximum":4294967295},"ledgerHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"transactionIndex":{"type":"integer","minimum":0},"eventType":{"type":"string","enum":["created","accepted","deleted"]},"issuer":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"},"subject":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"},"schemaUid":{"type":"string","pattern":"^[0-9a-f]{64}$"},"accepted":{"type":"boolean"},"deletionCause":{"anyOf":[{"type":"string","enum":["issuer_revoked","subject_rejected","subject_removed","expired_cleanup","account_deleted","self_deleted"]},{"type":"null"}]}}}}}}}}},"400":{"description":"400 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"404":{"description":"404 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"503":{"description":"503 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}}}}},"/v1/networks/{network}/transactions/{transactionHash}":{"get":{"parameters":[{"name":"network","in":"path","required":true,"schema":{"type":"string","pattern":"^[a-z0-9][a-z0-9._-]{0,127}$"}},{"name":"transactionHash","in":"path","required":true,"schema":{"type":"string","pattern":"^[0-9A-Fa-f]{64}$"}},{"name":"cursor","in":"query","required":false,"schema":{"type":"string","pattern":"^(?:0|[1-9][0-9]{0,9})$"}},{"name":"limit","in":"query","required":false,"schema":{"type":"string","pattern":"^(?:[1-9]|[1-9][0-9]|100)$"}}],"responses":{"200":{"description":"200 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["transactionHash","ledgerIndex","ledgerHash","transactionIndex","registration","credentialEvents"],"properties":{"transactionHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"ledgerIndex":{"type":"integer","minimum":0,"maximum":4294967295},"ledgerHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"transactionIndex":{"type":"integer","minimum":0},"registration":{"anyOf":[{"type":"object","additionalProperties":false,"required":["status","publisher","ledgerIndex","ledgerHash","transactionIndex","schemaUid","schemaDigestHex","reasonCode"],"properties":{"status":{"type":"string","enum":["accepted","rejected"]},"publisher":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"},"ledgerIndex":{"type":"integer","minimum":0,"maximum":4294967295},"ledgerHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"transactionIndex":{"type":"integer","minimum":0},"schemaUid":{"anyOf":[{"type":"string","pattern":"^[0-9a-f]{64}$"},{"type":"null"}]},"schemaDigestHex":{"anyOf":[{"type":"string","pattern":"^[0-9a-f]{64}$"},{"type":"null"}]},"reasonCode":{"anyOf":[{"type":"string","minLength":1,"maxLength":128},{"type":"null"}]}}},{"type":"null"}]},"credentialEvents":{"type":"object","additionalProperties":false,"required":["items"],"properties":{"items":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["transactionHash","nodeIndex","generationId","ledgerIndex","ledgerHash","transactionIndex","eventType","issuer","subject","schemaUid","accepted","deletionCause"],"properties":{"transactionHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"nodeIndex":{"type":"integer","minimum":0},"generationId":{"type":"string","pattern":"^[0-9a-f]{64}$"},"ledgerIndex":{"type":"integer","minimum":0,"maximum":4294967295},"ledgerHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"transactionIndex":{"type":"integer","minimum":0},"eventType":{"type":"string","enum":["created","accepted","deleted"]},"issuer":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"},"subject":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"},"schemaUid":{"type":"string","pattern":"^[0-9a-f]{64}$"},"accepted":{"type":"boolean"},"deletionCause":{"anyOf":[{"type":"string","enum":["issuer_revoked","subject_rejected","subject_removed","expired_cleanup","account_deleted","self_deleted"]},{"type":"null"}]}}}},"nextCursor":{"type":"string","pattern":"^[0-9]+$"}}}}}}}},"400":{"description":"400 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"404":{"description":"404 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"503":{"description":"503 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}}}}},"/v1/networks/{network}/schemas/{uid}/catalog":{"get":{"parameters":[{"name":"network","in":"path","required":true,"schema":{"type":"string","pattern":"^[a-z0-9][a-z0-9._-]{0,127}$"}},{"name":"uid","in":"path","required":true,"schema":{"type":"string","pattern":"^[0-9a-f]{64}$"}}],"responses":{"200":{"description":"200 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["format","profile","targetUid","checkpoint","schemas"],"properties":{"format":{"type":"string","const":"xcs-schema-catalog/1"},"profile":{"type":"object","additionalProperties":false,"required":["profileId","xcsVersion","networkId","requiredAmendment","registryAddress","registrationAmountDrops","activationLedgerIndex","activationLedgerHash"],"properties":{"profileId":{"type":"string","pattern":"^[a-z0-9][a-z0-9._-]{0,127}$"},"xcsVersion":{"type":"string","const":"0.1"},"networkId":{"type":"integer","minimum":0,"maximum":4294967295},"requiredAmendment":{"type":"string","pattern":"^[0-9A-F]{64}$"},"registryAddress":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"},"registrationAmountDrops":{"type":"string","const":"1"},"activationLedgerIndex":{"type":"integer","minimum":1,"maximum":4294967295},"activationLedgerHash":{"type":"string","pattern":"^[0-9a-f]{64}$"}}},"targetUid":{"type":"string","pattern":"^[0-9a-f]{64}$"},"checkpoint":{"type":"object","additionalProperties":false,"required":["ledgerIndex","ledgerHash"],"properties":{"ledgerIndex":{"type":"integer","minimum":1,"maximum":4294967295},"ledgerHash":{"type":"string","pattern":"^[0-9a-f]{64}$"}}},"schemas":{"type":"array","minItems":1,"maxItems":256,"items":{"type":"object","additionalProperties":false,"required":["uid","definition","publisher","ledgerIndex","ledgerHash","transactionIndex","transactionHash"],"properties":{"uid":{"type":"string","pattern":"^[0-9a-f]{64}$"},"definition":{"type":"object","additionalProperties":false,"required":["xcsVersion","name","description","fields"],"properties":{"xcsVersion":{"type":"string","const":"0.1"},"name":{"type":"string","minLength":1},"description":{"type":"string","minLength":1},"extends":{"type":"string","pattern":"^[0-9a-f]{64}$"},"supersedes":{"type":"string","pattern":"^[0-9a-f]{64}$"},"fields":{"type":"object","minProperties":1,"additionalProperties":{"$ref":"#/components/schemas/XcsFieldDescriptor"}}}},"publisher":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"},"ledgerIndex":{"type":"integer","minimum":1,"maximum":4294967295},"ledgerHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"transactionIndex":{"type":"integer","minimum":0,"maximum":4294967295},"transactionHash":{"type":"string","pattern":"^[0-9a-f]{64}$"}}}}}}}}},"400":{"description":"400 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"404":{"description":"404 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"429":{"description":"429 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["statusCode","error","message"],"properties":{"statusCode":{"type":"integer","const":429},"error":{"type":"string"},"message":{"type":"string"}}}}}},"500":{"description":"500 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"503":{"description":"503 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}}}}},"/v1/networks/{network}/schemas/{uid}":{"get":{"parameters":[{"name":"network","in":"path","required":true,"schema":{"type":"string","pattern":"^[a-z0-9][a-z0-9._-]{0,127}$"}},{"name":"uid","in":"path","required":true,"schema":{"type":"string","pattern":"^[0-9a-f]{64}$"}}],"responses":{"200":{"description":"200 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["profileId","schemaUid","publisher","name","description","parentUid","supersedesUid","registrationTransactionHash","ledgerIndex","transactionIndex","definition","resolvedDefinition","registeredAt"],"properties":{"profileId":{"type":"string","pattern":"^[a-z0-9][a-z0-9._-]{0,127}$"},"schemaUid":{"type":"string","pattern":"^[0-9a-f]{64}$"},"publisher":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"},"name":{"type":"string"},"description":{"type":"string"},"parentUid":{"anyOf":[{"type":"string","pattern":"^[0-9a-f]{64}$"},{"type":"null"}]},"supersedesUid":{"anyOf":[{"type":"string","pattern":"^[0-9a-f]{64}$"},{"type":"null"}]},"registrationTransactionHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"ledgerIndex":{"type":"integer","minimum":0,"maximum":4294967295},"transactionIndex":{"type":"integer","minimum":0},"definition":{"type":"object","additionalProperties":false,"required":["xcsVersion","name","description","fields"],"properties":{"xcsVersion":{"type":"string","const":"0.1"},"name":{"type":"string","minLength":1},"description":{"type":"string","minLength":1},"extends":{"type":"string","pattern":"^[0-9a-f]{64}$"},"supersedes":{"type":"string","pattern":"^[0-9a-f]{64}$"},"fields":{"type":"object","minProperties":1,"additionalProperties":{"$ref":"#/components/schemas/XcsFieldDescriptor"}}}},"resolvedDefinition":{"type":"object","additionalProperties":false,"required":["definition","fields","lineage"],"properties":{"definition":{"type":"object","additionalProperties":false,"required":["xcsVersion","name","description","fields"],"properties":{"xcsVersion":{"type":"string","const":"0.1"},"name":{"type":"string","minLength":1},"description":{"type":"string","minLength":1},"extends":{"type":"string","pattern":"^[0-9a-f]{64}$"},"supersedes":{"type":"string","pattern":"^[0-9a-f]{64}$"},"fields":{"type":"object","minProperties":1,"additionalProperties":{"$ref":"#/components/schemas/XcsFieldDescriptor"}}}},"fields":{"type":"object","minProperties":1,"additionalProperties":{"$ref":"#/components/schemas/XcsFieldDescriptor"}},"lineage":{"type":"array","items":{"type":"string","pattern":"^[0-9a-f]{64}$"}}}},"registeredAt":{"type":"string","format":"date-time"}}}}}},"404":{"description":"404 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"503":{"description":"503 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}}}}},"/v1/networks/{network}/schema-registrations/{transactionHash}":{"get":{"parameters":[{"name":"network","in":"path","required":true,"schema":{"type":"string","pattern":"^[a-z0-9][a-z0-9._-]{0,127}$"}},{"name":"transactionHash","in":"path","required":true,"schema":{"type":"string","pattern":"^[0-9A-Fa-f]{64}$"}}],"responses":{"200":{"description":"200 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["transactionHash","registration"],"properties":{"transactionHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"registration":{"anyOf":[{"type":"object","additionalProperties":false,"required":["status","publisher","ledgerIndex","ledgerHash","transactionIndex","schemaUid","schemaDigestHex","reasonCode"],"properties":{"status":{"type":"string","enum":["accepted","rejected"]},"publisher":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"},"ledgerIndex":{"type":"integer","minimum":0,"maximum":4294967295},"ledgerHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"transactionIndex":{"type":"integer","minimum":0},"schemaUid":{"anyOf":[{"type":"string","pattern":"^[0-9a-f]{64}$"},{"type":"null"}]},"schemaDigestHex":{"anyOf":[{"type":"string","pattern":"^[0-9a-f]{64}$"},{"type":"null"}]},"reasonCode":{"anyOf":[{"type":"string","minLength":1,"maxLength":128},{"type":"null"}]}}},{"type":"null"}]}}}}}},"400":{"description":"400 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"404":{"description":"404 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"503":{"description":"503 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}}}}},"/v1/networks/{network}/schemas":{"get":{"parameters":[{"name":"network","in":"path","required":true,"schema":{"type":"string","pattern":"^[a-z0-9][a-z0-9._-]{0,127}$"}},{"name":"publisher","in":"query","required":false,"schema":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"}},{"name":"cursor","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":512}},{"name":"limit","in":"query","required":false,"schema":{"type":"string","pattern":"^(?:[1-9]|[1-9][0-9]|100)$"}}],"responses":{"200":{"description":"200 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["items"],"properties":{"items":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["profileId","schemaUid","publisher","name","description","parentUid","supersedesUid","registrationTransactionHash","ledgerIndex","transactionIndex","definition","resolvedDefinition","registeredAt"],"properties":{"profileId":{"type":"string","pattern":"^[a-z0-9][a-z0-9._-]{0,127}$"},"schemaUid":{"type":"string","pattern":"^[0-9a-f]{64}$"},"publisher":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"},"name":{"type":"string"},"description":{"type":"string"},"parentUid":{"anyOf":[{"type":"string","pattern":"^[0-9a-f]{64}$"},{"type":"null"}]},"supersedesUid":{"anyOf":[{"type":"string","pattern":"^[0-9a-f]{64}$"},{"type":"null"}]},"registrationTransactionHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"ledgerIndex":{"type":"integer","minimum":0,"maximum":4294967295},"transactionIndex":{"type":"integer","minimum":0},"definition":{"type":"object","additionalProperties":false,"required":["xcsVersion","name","description","fields"],"properties":{"xcsVersion":{"type":"string","const":"0.1"},"name":{"type":"string","minLength":1},"description":{"type":"string","minLength":1},"extends":{"type":"string","pattern":"^[0-9a-f]{64}$"},"supersedes":{"type":"string","pattern":"^[0-9a-f]{64}$"},"fields":{"type":"object","minProperties":1,"additionalProperties":{"$ref":"#/components/schemas/XcsFieldDescriptor"}}}},"resolvedDefinition":{"type":"object","additionalProperties":false,"required":["definition","fields","lineage"],"properties":{"definition":{"type":"object","additionalProperties":false,"required":["xcsVersion","name","description","fields"],"properties":{"xcsVersion":{"type":"string","const":"0.1"},"name":{"type":"string","minLength":1},"description":{"type":"string","minLength":1},"extends":{"type":"string","pattern":"^[0-9a-f]{64}$"},"supersedes":{"type":"string","pattern":"^[0-9a-f]{64}$"},"fields":{"type":"object","minProperties":1,"additionalProperties":{"$ref":"#/components/schemas/XcsFieldDescriptor"}}}},"fields":{"type":"object","minProperties":1,"additionalProperties":{"$ref":"#/components/schemas/XcsFieldDescriptor"}},"lineage":{"type":"array","items":{"type":"string","pattern":"^[0-9a-f]{64}$"}}}},"registeredAt":{"type":"string","format":"date-time"}}}},"nextCursor":{"type":"string","minLength":1,"maxLength":512}}}}}},"503":{"description":"503 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}}}}},"/v1/networks/{network}/credentials/{issuer}/{subject}/{schemaUid}":{"get":{"parameters":[{"name":"network","in":"path","required":true,"schema":{"type":"string","pattern":"^[a-z0-9][a-z0-9._-]{0,127}$"}},{"name":"issuer","in":"path","required":true,"schema":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"}},{"name":"subject","in":"path","required":true,"schema":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"}},{"name":"schemaUid","in":"path","required":true,"schema":{"type":"string","pattern":"^[0-9a-f]{64}$"}}],"responses":{"200":{"description":"200 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["profileId","generationId","ledgerObjectId","issuer","subject","schemaUid","uriHex","expiration","accepted","createdLedgerIndex","createdTransactionIndex","lastLedgerIndex","deletedLedgerIndex","deletionCause","createdAt","updatedAt","state"],"properties":{"profileId":{"type":"string","pattern":"^[a-z0-9][a-z0-9._-]{0,127}$"},"generationId":{"type":"string","pattern":"^[0-9a-f]{64}$"},"ledgerObjectId":{"type":"string","pattern":"^[0-9a-f]{64}$"},"issuer":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"},"subject":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"},"schemaUid":{"type":"string","pattern":"^[0-9a-f]{64}$"},"uriHex":{"anyOf":[{"type":"string","pattern":"^(?:[0-9A-Fa-f]{2})*$"},{"type":"null"}]},"expiration":{"anyOf":[{"type":"integer","minimum":0,"maximum":4294967295},{"type":"null"}]},"accepted":{"type":"boolean"},"createdLedgerIndex":{"type":"integer","minimum":0,"maximum":4294967295},"createdTransactionIndex":{"type":"integer","minimum":0},"lastLedgerIndex":{"type":"integer","minimum":0,"maximum":4294967295},"deletedLedgerIndex":{"anyOf":[{"type":"integer","minimum":0,"maximum":4294967295},{"type":"null"}]},"deletionCause":{"anyOf":[{"type":"string","enum":["issuer_revoked","subject_rejected","subject_removed","expired_cleanup","account_deleted","self_deleted"]},{"type":"null"}]},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"},"state":{"type":"string","enum":["pending","active","expired","deleted"]}}}}}},"404":{"description":"404 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"503":{"description":"503 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}}}}},"/v1/networks/{network}/credentials/{issuer}/{subject}/{schemaUid}/events":{"get":{"parameters":[{"name":"network","in":"path","required":true,"schema":{"type":"string","pattern":"^[a-z0-9][a-z0-9._-]{0,127}$"}},{"name":"issuer","in":"path","required":true,"schema":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"}},{"name":"subject","in":"path","required":true,"schema":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"}},{"name":"schemaUid","in":"path","required":true,"schema":{"type":"string","pattern":"^[0-9a-f]{64}$"}}],"responses":{"200":{"description":"200 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["items"],"properties":{"items":{"type":"array","items":{"type":"object","additionalProperties":true,"required":["transactionHash","nodeIndex","generationId","ledgerIndex","ledgerHash","transactionIndex","eventType","issuer","subject","schemaUid","accepted","deletionCause"],"properties":{"transactionHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"nodeIndex":{"type":"integer","minimum":0},"generationId":{"type":"string","pattern":"^[0-9a-f]{64}$"},"ledgerIndex":{"type":"integer","minimum":0,"maximum":4294967295},"ledgerHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"transactionIndex":{"type":"integer","minimum":0},"eventType":{"type":"string","enum":["created","accepted","deleted"]},"issuer":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"},"subject":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"},"schemaUid":{"type":"string","pattern":"^[0-9a-f]{64}$"},"accepted":{"type":"boolean"},"deletionCause":{"anyOf":[{"type":"string","enum":["issuer_revoked","subject_rejected","subject_removed","expired_cleanup","account_deleted","self_deleted"]},{"type":"null"}]}}}}}}}}},"413":{"description":"413 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"503":{"description":"503 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}}}}},"/v1/networks/{network}/credentials/{issuer}/{subject}/{schemaUid}/events/{transactionHash}":{"get":{"parameters":[{"name":"network","in":"path","required":true,"schema":{"type":"string","pattern":"^[a-z0-9][a-z0-9._-]{0,127}$"}},{"name":"issuer","in":"path","required":true,"schema":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"}},{"name":"subject","in":"path","required":true,"schema":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"}},{"name":"schemaUid","in":"path","required":true,"schema":{"type":"string","pattern":"^[0-9a-f]{64}$"}},{"name":"transactionHash","in":"path","required":true,"schema":{"type":"string","pattern":"^[0-9A-Fa-f]{64}$"}}],"responses":{"200":{"description":"200 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["transactionHash","event"],"properties":{"transactionHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"event":{"anyOf":[{"type":"object","additionalProperties":false,"required":["transactionHash","nodeIndex","generationId","ledgerIndex","ledgerHash","transactionIndex","eventType","issuer","subject","schemaUid","accepted","deletionCause"],"properties":{"transactionHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"nodeIndex":{"type":"integer","minimum":0},"generationId":{"type":"string","pattern":"^[0-9a-f]{64}$"},"ledgerIndex":{"type":"integer","minimum":0,"maximum":4294967295},"ledgerHash":{"type":"string","pattern":"^[0-9a-f]{64}$"},"transactionIndex":{"type":"integer","minimum":0},"eventType":{"type":"string","enum":["created","accepted","deleted"]},"issuer":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"},"subject":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"},"schemaUid":{"type":"string","pattern":"^[0-9a-f]{64}$"},"accepted":{"type":"boolean"},"deletionCause":{"anyOf":[{"type":"string","enum":["issuer_revoked","subject_rejected","subject_removed","expired_cleanup","account_deleted","self_deleted"]},{"type":"null"}]}}},{"type":"null"}]}}}}}},"400":{"description":"400 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"404":{"description":"404 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"503":{"description":"503 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}}}}},"/v1/verify":{"post":{"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["network","issuer","subject","schemaUid"],"properties":{"network":{"type":"string","pattern":"^[a-z0-9][a-z0-9._-]{0,127}$"},"issuer":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"},"subject":{"type":"string","pattern":"^r[1-9A-HJ-NP-Za-km-z]{24,34}$"},"schemaUid":{"type":"string","pattern":"^[0-9a-f]{64}$"},"payload":{"type":"object"},"resolvePayload":{"type":"boolean"}},"not":{"required":["payload","resolvePayload"]}}}}},"responses":{"200":{"description":"200 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["onChain","schema","payload","issuerTrust"],"properties":{"onChain":{"type":"string","enum":["pending","active","expired","deleted","not_found"]},"schema":{"type":"string","enum":["valid","invalid","unknown"]},"payload":{"type":"string","enum":["valid","unavailable","tampered","invalid","not_checked"]},"issuerTrust":{"type":"string","enum":["trusted","untrusted","unknown"]},"generationId":{"type":"string","pattern":"^[0-9a-f]{64}$"}}}}}},"404":{"description":"404 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"503":{"description":"503 response","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["error","message"],"properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}}}}}},"components":{"schemas":{"XcsFieldDescriptor":{"oneOf":[{"type":"object","additionalProperties":false,"required":["type"],"properties":{"type":{"type":"string","enum":["string","bool","uint","int","bytes","address"]},"optional":{"type":"boolean"}}},{"type":"object","additionalProperties":false,"required":["type","items"],"properties":{"type":{"type":"string","const":"array"},"optional":{"type":"boolean"},"items":{"$ref":"#/components/schemas/XcsFieldDescriptor"}}},{"type":"object","additionalProperties":false,"required":["type","fields"],"properties":{"type":{"type":"string","const":"object"},"optional":{"type":"boolean"},"fields":{"type":"object","minProperties":1,"additionalProperties":{"$ref":"#/components/schemas/XcsFieldDescriptor"}}}}]}}}}