v1
latestOpenAPI 3.0.02026-07-14732267.9 KBCreate a proxy role
Overview
Use this endpoint to create a new proxy role between a patient and a related person (proxy).
Access modes
This endpoint supports the following access modes:
- Healthcare worker access
- Application-restricted access
Sandbox test scenarios
You can test the following scenarios in our sandbox environment:
| Scenario | Request | Response |
|---|---|---|
| Successful parent-child proxy creation | Valid request with a legal basis of parental responsibility, with performer identifier value of 9000000009 | HTTP Status 201 and OperationOutcome response |
| Successful adult-adult proxy creation | Valid request with legal basis of consent, with performer identifier value of 9000000017 | HTTP Status 201 and OperationOutcome response |
| Valid OTHER reason code with free text | Request with reason code 'OTHER' and free text provided, performer identifier 9000000051 | HTTP Status 201 and OperationOutcome response |
| Non-OTHER reason code without free text | Request with a reason code other than 'OTHER', no free text, performer identifier 9000000052 | HTTP Status 201 and OperationOutcome response |
| Non-OTHER reason code with free text | Request with a reason code other than 'OTHER', with free text, performer identifier 9000000053 | HTTP Status 201 and OperationOutcome response |
| Missing free text for OTHER reason code | Request with reason code 'OTHER' but missing free text, performer identifier 9000000050 | HTTP Status 400 and MISSING_FREE_TEXT_FOR_OTHER error response |
| Missing grantor | Valid request with status 'active' but no grantor extension, performer identifier 9000000054 | HTTP Status 400 and MISSING_GRANTOR error response |
| Missing grantor valueReference | Request with grantor extension but missing valueReference, performer identifier 9000000057 | HTTP Status 400 and MISSING_GRANTOR_REFERENCE error response |
| Missing grantor valueIdentifier | Request with grantor extension but missing valueIdentifier, performer identifier 9000000058 | HTTP Status 400 and MISSING_GRANTOR_IDENTIFIER error response |
| Invalid grantor ODS code value | Request with grantor extension but missing/empty/invalid ODS code, performer identifier 9000000055 | HTTP Status 422 and INVALID_GRANTOR_VALUE error response |
| Invalid grantor identifier system | Request with grantor extension but wrong/missing identifier system, performer identifier 9000000056 | HTTP Status 422 and INVALID_GRANTOR_SYSTEM error response |
| Duplicate relationship | Request for relationship that already exists, with performer identifier value of 9000000049 | HTTP Status 409 and DUPLICATE_RELATIONSHIP error response |
Sandbox constraints
The sandbox environment has the following constraints for this endpoint:
- patient.identifier.value is disregarded. The returned response is based on the performer.identifier.value only.
- Request body is not validated.
- Request headers are not tested. X-Request-ID and X-Correlation-ID are disregarded.
- No proxy role is created.
post/Consent
Headers
Authorizationstring ^Bearer\ [[:ascii:]]+$ required
Example:Bearer g1112R_ccQ1Ebbb4gtHBP1aaaNM
X-Request-IDstring uuid required
Example:60E0B220-8136-4CA5-AE46-1D97EF59D068
A globally unique identifier (GUID) for the request, which we use to correlate logs through different components. Must be a universally unique identifier (UUID) (ideally version 4). Mirrored back in a response header.
X-Correlation-IDstring uuid
Example:11C46F5F-CDEF-4865-94B2-0EE0EDCC26DA
An optional ID which you can use to track transactions across multiple systems. Must be a universally unique identifier (UUID) (ideally version 4). Mirrored back in a response header.
Response
Consent resource successfully created