Consent API
5 operations from the external ASIRI OpenAPI surface.
Public endpoint
GET/v1/consent
List consent notices
Requires
consent:readSecurity
bearer
Authorization: Bearer <ASIRI_API_KEY>Parameters
| Name | In | Required | Schema | Description |
|---|---|---|---|---|
status | query | no | string | - |
domain | query | no | string | - |
search | query | no | string | - |
cursor | query | no | string | - |
limit | query | no | integer | - |
Request body
No request body.
Responses
Public endpoint
GET/v1/consent/{id}
Get a consent notice by id
Requires
consent:readSecurity
bearer
Authorization: Bearer <ASIRI_API_KEY>Parameters
| Name | In | Required | Schema | Description |
|---|---|---|---|---|
id | path | yes | string | - |
Request body
No request body.
Responses
Public endpoint
GET/v1/consent/{id}/records
List consent records captured against a notice
Requires
consent:readSecurity
bearer
Authorization: Bearer <ASIRI_API_KEY>Parameters
| Name | In | Required | Schema | Description |
|---|---|---|---|---|
id | path | yes | string | - |
cursor | query | no | string | - |
limit | query | no | integer | - |
Request body
No request body.
Responses
Public endpoint
POST/v1/consent/{id}/records
Capture a new consent record (append-only)
Captures a single consent record against a published notice. The notice MUST be in status='published'; a draft or archived notice returns 409 conflict with `code: "consent_notice_not_published"` and `requiredStatus` / `actualStatus` fields on the error envelope. Publish via POST /v1/consent/{id}/publish before capturing. The records ledger is append-only — withdrawals create a new linked row rather than mutating the original.
Requires
consent:writeSecurity
bearer
Authorization: Bearer <ASIRI_API_KEY>Parameters
| Name | In | Required | Schema | Description |
|---|---|---|---|---|
id | path | yes | string | - |
Request body
application/jsonobjectResponses
Public endpoint
GET/v1/consent/{id}/records/{recordId}
Get a single consent record
Requires
consent:readSecurity
bearer
Authorization: Bearer <ASIRI_API_KEY>Parameters
| Name | In | Required | Schema | Description |
|---|---|---|---|---|
id | path | yes | string | - |
recordId | path | yes | string | - |
Request body
No request body.