Skip to content

Commit 6154f7c

Browse files
NPA-4557: Add 5XX Error responses to OAS spec for POST Consent
1 parent ea890f7 commit 6154f7c

File tree

2 files changed

+18
-1
lines changed

2 files changed

+18
-1
lines changed

specification/examples/responses/GET_Consent/errors/downstream-service-error.yaml renamed to specification/examples/responses/errors/downstream-service-error.yaml

File renamed without changes.

specification/validated-relationships-service-api.yaml

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -491,7 +491,7 @@ paths:
491491
InternalServerError:
492492
$ref: "./examples/responses/errors/internal-server-error.yaml#/InternalServerError"
493493
DownstreamServiceError:
494-
$ref: "./examples/responses/GET_Consent/errors/downstream-service-error.yaml#/DownstreamServiceError"
494+
$ref: "./examples/responses/errors/downstream-service-error.yaml#/DownstreamServiceError"
495495
post:
496496
summary: Create a proxy role
497497
description: |
@@ -577,7 +577,24 @@ paths:
577577
$ref: "./examples/responses/POST_Consent/errors/invalid_patient_age_error.yaml#/PostConsentInvalidPatientAgeError"
578578
postConsentDuplicateRelationship:
579579
$ref: "./examples/responses/POST_Consent/errors/duplicate_relationship_error.yaml#/PostConsentDuplicateRelationshipError"
580+
"5XX":
581+
description: |
582+
Errors will be returned for the first error encountered in the request. An error occurred as follows:
583+
584+
| HTTP status | Error code | Description |
585+
| ----------- | -------------------------- | ------------------------------------------------------------ |
586+
| 500 | `SERVER_ERROR` | An unexpected internal server error has occurred. |
587+
| 503 | `DOWNSTREAM_SERVICE_ERROR` | A downsteam service has failed, request cannot be completed. |
580588
589+
content:
590+
application/fhir+json:
591+
schema:
592+
$ref: "#/components/schemas/OperationOutcome"
593+
examples:
594+
InternalServerError:
595+
$ref: "./examples/responses/errors/internal-server-error.yaml#/InternalServerError"
596+
DownstreamServiceError:
597+
$ref: "./examples/responses/errors/downstream-service-error.yaml#/DownstreamServiceError"
581598

582599
/Consent/{id}:
583600
patch:

0 commit comments

Comments
 (0)