diff --git a/paths/evaluate/evaluate.yml b/paths/evaluate/evaluate.yml index ea197b2..653dd42 100644 --- a/paths/evaluate/evaluate.yml +++ b/paths/evaluate/evaluate.yml @@ -372,6 +372,8 @@ post: $ref: "./responses/400-BadRequest.yml" "403": $ref: "./responses/403-Forbidden.yml" + "422": + $ref: "./responses/422-UnprocessableSubmission.yml" "500": $ref: "./responses/500-InternalError.yml" "406": diff --git a/paths/evaluate/responses/422-UnprocessableSubmission.yml b/paths/evaluate/responses/422-UnprocessableSubmission.yml new file mode 100644 index 0000000..33e2215 --- /dev/null +++ b/paths/evaluate/responses/422-UnprocessableSubmission.yml @@ -0,0 +1,23 @@ +description: The request is valid, but the evaluation function cannot process the submission content (e.g. an unparseable expression). +headers: + X-Request-Id: + description: Request id for tracing this request across services. + schema: + type: string + X-Api-Version: + description: The API version that was used to serve this response. + schema: + type: string +content: + application/json: + schema: + $ref: "../../shared/schemas/ErrorResponse.yml" + examples: + unprocessableSubmission: + summary: Example unprocessable submission error + value: + title: "Unprocessable submission" + message: "Failed to parse SymPy expression: A/(w*" + code: "VALIDATION_ERROR" + trace: null + details: null