application/problem+json. One shape covers every
failure, so you write the handling once.
Fields
A problem may also carry extension fields specific to it —
validation-failed
adds issues, listing every field that failed. The generated catalog lists the extensions declared by the deployed API and shared error registry.
Handle problems by type or code
type and code are wire contracts: once published, neither changes without a
breaking change. Match on either one.
title or detail. Both are written for people, and both
change without notice.
Look up a type URI
Every problem the API publishes is listed in the catalog, with its code, status, and any extension fields it carries. Each slug there is anchored, and atype URI redirects onto it. Open
https://photon.codes/docs/problems/rate-limited and you land on that row with
it highlighted, whatever filter was set.