Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save DavidBiesack/5319932920759b07c65e72eb635c0125 to your computer and use it in GitHub Desktop.
Save DavidBiesack/5319932920759b07c65e72eb635c0125 to your computer and use it in GitHub Desktop.
Multiple 400-level application/problem+json responses
paths:
/chainLinks:
get:
responses:
'200': ... as seen above ...
'400':
description: Bad Request.
content:
application/problem+json:
schema:
title: API Problem
description: >-
API problem response, as per
[RFC 7807](https://tools.ietf.org/html/rfc7807).
type: object
properties:
type:
description: >-
A URI reference
[RFC 3986](https://tools.ietf.org/html/rfc3986)
that identifies the problem type.
type: string
format: uri-reference
maxLength: 2048
title:
description: >-
A short, human-readable summary
of the problem type.
type: string
maxLength: 120
status:
description: >-
The
[RFC 9110](https://tools.ietf.org/html/rfc9110)
HTTP status code generated by the origin server
for this occurrence of the problem.
type: integer
format: int32
minimum: 100
maximum: 599
instance:
description: >-
A URI reference that identifies
the specific occurrence of the problem.
type: string
format: uri-reference
maxLength: 256
detail:
description: >-
A human-readable explanation
specific to this occurrence of the problem.
type: string
maxLength: 2048
'409':
description: Conflict
content:
application/problem+json:
schema:
title: API Problem
description: >-
API problem response, as per
[RFC 7807](https://tools.ietf.org/html/rfc7807).
type: object
properties:
type:
description: >-
A URI reference
[RFC 3986](https://tools.ietf.org/html/rfc3986)
that identifies the problem type.
type: string
format: uri-reference
maxLength: 2048
title:
description: >-
A short, human-readable summary
of the problem type.
type: string
maxLength: 120
status:
description: >-
The
[RFC 9110](https://tools.ietf.org/html/rfc9110)
HTTP status code generated by the origin server
for this occurrence of the problem.
type: integer
format: int32
minimum: 100
maximum: 599
instance:
description: >-
A URI reference that identifies
the specific occurrence of the problem.
type: string
format: uri-reference
maxLength: 256
detail:
description: >-
A human-readable explanation
specific to this occurrence of the problem.
type: string
maxLength: 2048
'422':
description: Unprocessable Entity
content:
application/problem+json:
schema:
title: API Problem
description: >-
API problem response, as per
[RFC 7807](https://tools.ietf.org/html/rfc7807).
type: object
properties:
type:
description: >-
A URI reference
[RFC 3986](https://tools.ietf.org/html/rfc3986)
that identifies the problem type.
type: string
format: uri-reference
maxLength: 2048
title:
description: >-
A short, human-readable summary
of the problem type.
type: string
maxLength: 120
status:
description: >-
The
[RFC 9110](https://tools.ietf.org/html/rfc9110)
HTTP status code generated by the origin server
for this occurrence of the problem.
type: integer
format: int32
minimum: 100
maximum: 599
instance:
description: >-
A URI reference that identifies
the specific occurrence of the problem.
type: string
format: uri-reference
maxLength: 256
detail:
description: >-
A human-readable explanation
specific to this occurrence of the problem.
type: string
maxLength: 2048
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment