Skip to content
View Markdown

Loading documentation…

Handling errors

Check HTTP status and legacy response bodies before processing data.

Paydro’s existing JSON resources do not all use one error envelope. Check the HTTP status, content type, and response body before processing a response as a resource.

Authentication and permissions

Incorrect Basic credentials return a legacy 403 with this structure:

JSON
{"status":403,"title":"Unauthorized","detail":"User name and password combination are incorrect"}

Missing credentials can result in a login redirect. Do not automatically follow that redirect and decode the final HTML as JSON. Confirm credentials on the origin and verify the account’s organization and event rights.

Invalid input

Invalid event discovery years return 400 and an error/detail object. Unknown paths can return 404. Invalid order IDs can return {"error":"no_valid_id"} through a legacy redirect response. Treat a recognized error property as failure even when a legacy response status is successful.

Pagination errors

A list page past the end may use a redirect/error response. Stop after a short page, and distinguish an out of range page from an authentication error. Keep the last successfully imported page until the entire import is complete.

Temporary failures

For 429, honor Retry-After. Back off after network errors or server failures. A temporarily unavailable authentication rate limit store can produce 503. Correct authentication/permission failures before retrying; see retry guidance.

Report a problem

Capture the method, path, response status, and timestamp. Sanitize credentials and personal data before sharing logs with support.