Skip to content

How to handle 422 json error response? #69

@sjmueller

Description

@sjmueller

Our api server gives a 422 response when validating request params:

{
    "errors": [{ "detail": "Missing field: anon_id" }]
}

However, Get only supplies the error code: Response status code was unacceptable: 422 via APIError

.unacceptableStatusCode(let statusCode)

How can we hook into the actual error response for logging and (sometimes) showing to the user?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions