GuidesAPI ReferenceRelease Notes
Log In
API Reference

Consents

APIs your organisation calls to read, update and revoke CDR consents.

Use the Consents APIs to record a consumer's data-sharing approval and to display and withdraw consents in your consumer dashboard under the Consumer Data Right (CDR).

Ozone hosts these APIs, and your organisation calls them. Each consent record stores information about the consumer's permission to share data. Authentication verifies the consumer's identity; consent authorization records their approval to share data.

This page explains which calls your integration supports and how they fit into authorization and consent management. Use the endpoint references for parameters, request bodies and response schemas.

Consent Manager endpoints

Your organisation calls the following Consent Manager (CM) endpoints hosted by Ozone, except for Create consent, which Ozone uses internally.

CM endpointMethod and pathRequirementPurpose
Get consentGET /consents/{consentId}OptionalReading an individual consent during authorization or for your dashboard.
Update consentPATCH /consents/{consentId}MandatoryRecording the consumer, selected accounts and authorization outcome.
Get consents for a consumerGET /psu/USERID/consentsConditionalRequired when your dashboard uses this endpoint to retrieve a consumer's consents.
Revoke consentPOST /consents/{consentId}/action/revokeConditionalRequired when your dashboard or back office uses individual-consent revocation. For arrangement-level withdrawal, see Consent groups.
Get consent auditGET /consents/{consentId}/auditOptionalReading the history of changes to a consent.
Get consents for an accountGET /accounts/{accountId}/consentsOptionalFinding consents that include an account, for example when the account is closed.
Get deleted consents for a consumerGET /psu/USERID/deleted-consentsOptionalRetrieving a consumer's deleted consents.
Search consentsGET /consentsOptionalSearching consents across consumers, for example from a back-office tool.
Delete consentDELETE /consents/{consentId}OptionalDeleting a consent record.
Create consentPOST /consentsNot called by your organisation in this authorization flowUsed internally by Ozone to create the consent.
🔴

Successfully update the consent with the authorization outcome, consumer identifier and selected account identifiers for account-based access before calling doConfirm.

Neither doConfirm nor doFail automatically updates the consent status. Update it separately using PATCH /consents/{consentId}.

Update consent during authorization

Use the consent identifier returned by the Authorization Server to call PATCH /consents/{consentId}.

Successful authorization

After the consumer has confirmed their identity and approved data sharing:

  1. Record your consumer identifier in psuIdentifiers.userId.
  2. For account-based access, record the selected internal account identifiers in accountIds.
  3. Set consentBody.data.status to Authorized.
  4. After the consent update succeeds, call doConfirm.

Rejected or incomplete authorization

If the authorization process ends without approval and the consent must be rejected:

  1. Set the consent status to Rejected.
  2. Include consentBody.data.abandonedByStage to identify where the process ended.
  3. Include the consumer identifier if it is available.
  4. Call doFail to end the authorization interaction.

The process may end before the consumer is identified. Do not invent a consumer identifier or selected accounts for such a rejection.

Fields used during authorization

The requirements below apply to recording the authorization outcome. See Update consent for the complete request schema and supported values.

FieldRequirementHow to populate it
psuIdentifiers.userIdConditionalRequired for successful authorization. Use your unique consumer identifier. Include it on a rejected consent where the consumer has been identified.
accountIdsConditionalRequired when authorizing account access. Supply the internal identifiers of the accounts selected by the consumer.
consentBody.data.statusMandatorySet to Authorized when the consumer approves, or Rejected when recording a rejected authorization.
consentBody.data.abandonedByStageConditionalRequired when setting the status to Rejected. Use the applicable value from the endpoint schema.
supplementaryInformationOptionalAdditional information stored with the consent. Follow any documented rules for fields used by your integration.
bankConnectTokenOptionalA bearer token that Ozone sends in the Authorization header on applicable Ozone Connect calls.

The PATCH request uses both nested objects (objects inside other objects) and property names that contain dots:

  • psuIdentifiers.userId identifies the userId property inside the psuIdentifiers object.
  • consentBody.data.status and consentBody.data.abandonedByStage are literal JSON property names. Do not convert them into a nested consentBody object.

For fields with a fixed list of allowed values (enum values), use the exact spelling in the API definition. For example, use preAuthorisation exactly as specified, even though the documentation uses “authorization”.

Do not set interactionId; Ozone sets it. To withdraw a consent, use the revoke endpoint rather than patching revocation fields.

Connect consent records to Ozone Connect

Record the consumer identifier your Ozone Connect implementation recognises in psuIdentifiers.userId. Ozone sends the consumer identifier object in the o3-psu-identifier header on later consumer-specific data requests. Use the same userId when retrieving the consumer's consents for your dashboard.

For account-based access, populate accountIds with the same internal account identifiers your Ozone Connect endpoints use for accounts, balances, transactions and other account-based requests.

See the CDR Overview's Consumer identity and Identifiers sections for shared data-handling guidance.

Sharing arrangements and amendments

A CDR sharing arrangement groups the consent records associated with a consumer's data-sharing agreement. Its identifier is cdr_arrangement_id, which corresponds to consentGroupId in the Consent Manager. Each individual consent record has its own consentId.

Ozone assigns the arrangement when it creates the consent at the start of the authorization interaction:

  • Amendment: if the ADR's authorization request includes a cdr_arrangement_id, the Consent Manager checks that the arrangement exists and belongs to the same ADR, and adds the new consent to it.
  • New arrangement: if the request does not include a cdr_arrangement_id, the Consent Manager generates a new arrangement identifier.

For an amendment, the earlier consents in the arrangement remain active until the first token is issued for the new consent. At that point, the Consent Manager revokes them with revokedBy set to AMENDMENT. Updating the consent with PATCH does not revoke anything, and you don't add cdr_arrangement_id to your PATCH request.

After the consent update succeeds, call doConfirm. See Stage 3 of the data-sharing diagram for the sequence and Consent groups for arrangement-level retrieval and withdrawal operations.

Consumer dashboard

Retrieve a consumer's consents

Call GET /psu/USERID/consents using the userId recorded on the consent.

Filter by status or consentType to narrow the results. Results are split into pages: use page to select a page and pageSize to control the number of results per page. Retrieve subsequent pages rather than assuming the first page contains every consent.

Individual consent records and sharing arrangements are different: several consent records may belong to the same arrangement. Use consentGroupId to associate those records where your dashboard presents arrangement-level information.

Withdraw a consent

To revoke an individual consent, call POST /consents/{consentId}/action/revoke with revokedBy set to:

  • CONSUMER – the consumer withdrew it through your consumer dashboard.
  • COLLEAGUE – a member of your staff withdrew it on the consumer's behalf.

You can also identify the consumer associated with the withdrawal in revokedByPsu.userId.

To withdraw an entire sharing arrangement, use the group revoke endpoint described on Consent groups.

Use the revoke operation for withdrawal; the delete endpoint is a separate record-management operation.

Related resources

  • CDR Overview – API responsibilities and how consent authorization connects to data sharing.
  • Consent groups – read and revoke consents belonging to a sharing arrangement.
  • Authorization Server APIs – start and complete the authorization interaction.

See Consent flow development for the screen flow and implementation steps.