Skip to main content

Error handling

All errors produced by TransferGo Business API follow a predefined format:

{
"message": "human readable error description",
"code": "pre-defined code to help identify the error"
}

Here's a list of all the possible errors:

Error codeHTTP statusMeaning
VALIDATION_ERROR400There are problems with the data you provided.
E.g. the fromCreatedAt date is later than the toCreatedAt date.
INVALID_CORRELATION_ID400The provided Correlation ID doesn't match the required format.
INVALID_PAGE_SIZE400The provided pageSize is outside the supported range of 1 to 100. Omit it to use the default of 10.
INVALID_CURSOR400The cursor is invalid. Most likely it was modified after being received.
CURSOR_FILTERS_CHANGED400The cursor was used with different filters than the ones it was created with. Requests that carry a cursor must repeat the exact same filters as the request that produced it. To change filters, re-issue the request without a cursor to start a new result set.

Trying it out

If you haven't yet made a successful call to our API, please consult the Calling the API page first.

Execute the same ping call but this time with a dedicated query parameter:

curl -X GET \
--url https://business-api.transfergo.com/v1/ping?produceError=true \
--cert client.crt \
--key client.key \
--header "Authorization: Bearer {access_token}"

The expected response with status code 400:

{
"message": "This is an example error.",
"code": "EXAMPLE_ERROR"
}

Next steps