Peak problem types
Home / Shared / unsupported_media_type

The request's media type is not supported.

Code
unsupported_media_type
Type
https://problems.peakintelligence.ch/unsupported-media-type
Status
415 Unsupported Media Type
Audience
client. Only the calling software can act on it. A client shows its own general failure and quotes traceId; detail is in English, for developers.
Service
Shared: every Peak service answers with it.

Description

The request's Content-Type is one the endpoint does not read, or it is missing. Send the media type the endpoint's OpenAPI description names for its body, usually application/json.

Example

HTTP/1.1 415 Unsupported Media Type
Content-Type: application/problem+json

{
  "type": "https://problems.peakintelligence.ch/unsupported-media-type",
  "title": "The request's media type is not supported.",
  "status": 415,
  "code": "unsupported_media_type",
  "audience": "client",
  "traceId": "4bf92f3577b34da6a3ce929d0e0e4736"
}

A real answer also carries detail when there is something to say about this occurrence, and may carry errors or members of the type's own, which the service's OpenAPI document describes. When to ask again is the Retry-After header.