You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Use this endpoint to create a new proxy relationship between a patient and a related person (proxy). The request must include the necessary details about the relationship, evidence of responsibility, and requested access level.
484
-
485
-
## Request Requirements
486
-
* The performer must be specified using a valid NHS Number
487
-
* The patient must be specified using a valid NHS Number
488
-
* Evidence of responsibility must be provided (e.g., birth certificate for parental relationships)
489
-
* The requested access level must be specified
490
-
* For child proxy requests, the child's age must be under 16
491
-
* For adult proxy requests, evidence of capacity assessment may be required
483
+
Use this endpoint to create a new proxy relationship between a patient and a related person (proxy).
492
484
493
485
## Sandbox test scenarios
494
486
| Scenario | Request | Response |
@@ -511,7 +503,7 @@ paths:
511
503
summary: Parent requesting access to child's record
Use this endpoint to update an existing proxy relationship. This can be used to modify the status, access levels, or other attributes of the relationship. The update is performed using JSON Patch operations.
636
+
summary: Update a proxy role
637
+
description: |
638
+
## Overview
639
+
Use this endpoint to update an existing proxy role.
663
640
664
641
Common update scenarios include:
665
-
* Changing the status of a relationship
666
-
* Modifying access levels
667
-
* Adding or updating verification information
668
-
* Updating the validity period
669
-
* Adding or removing specific provisions
642
+
* Revocation of the role (status change from "active" to inactive
643
+
* Changing the legal basis of the role (which property this will be is TBC with IOPS)
644
+
* Updating the end date for timebound access
645
+
646
+
NOTE:
647
+
we will also need to record a coded reason, but this is with IOPS to confirm where the reasonCode is stored.
648
+
670
649
671
650
## Request Requirements
672
-
* The Consent resource must exist and be identified by a valid identifier
651
+
* The proxy role must exist and be identified by a valid identifier
673
652
* JSON Patch operations must be valid according to RFC 6902
674
653
* Status changes must use valid status codes from http://hl7.org/fhir/consent-state-codes
675
-
* Access level changes must use valid codes from the NHS proxy access level system
676
654
677
655
## Sandbox test scenarios
678
656
| Scenario | Request | Response |
679
657
| -------- | ------- | -------- |
680
-
| Successful status update | Valid patch changing status to 'active' | HTTP Status 200 and updated Bundle |
681
-
| Successful access level update | Valid patch modifying access provisions | HTTP Status 200 and updated Bundle |
658
+
| Successful status update | Valid patch changing status to 'active' | HTTP Status 200 and OperationOutcome|
659
+
| Successful access level update | Valid patch modifying access provisions | HTTP Status 200 and OperationOutcome |
682
660
| Multiple valid changes | Valid patch with multiple operations | HTTP Status 200 and updated Bundle |
683
661
| Invalid patch format | Malformed JSON patch document | HTTP Status 400 and INVALID_PATCH_FORMAT error response |
684
662
| Invalid path | Patch targeting non-existent element | HTTP Status 400 and INVALID_PATCH_PATH error response |
685
663
| Invalid status code | Patch with invalid status value | HTTP Status 422 and INVALID_STATUS_CODE error response |
686
664
| Resource not found | Patch for non-existent Consent | HTTP Status 404 and RESOURCE_NOT_FOUND error response |
687
665
| Invalid state transition | Patch attempting invalid status change | HTTP Status 422 and INVALID_STATE_TRANSITION error response |
688
666
parameters:
689
-
- name: identifier
690
-
in: query
667
+
- name: id
668
+
in: path
691
669
required: true
692
-
description: The identifier of the Consent resource to update
670
+
description: The logical id of the Consent resource to update
0 commit comments