Skip to content

Manage HTTPErrors in Client.requests

Administrator requested to merge add-http-error-class into master

Create new class HTTPError

Add tests for HTTPError and assert that a bad Client.requests raises an HTTPError

In our HTTPError instances we map the messages that come from the MM API:

example-estructure:

[
    {
    "errors": [
        {
        "fields": "first_name,last_name",
        "statusCode": "400",
        "message": "Debe informar el nombre del cliente"
        }
    ]
    }
]
Edited by Administrator

Merge request reports

Loading