# API error handling

Source: https://developer.avalara.com/goods-calculation-en/ozp9653181733329/

# API error handling

Understand how AvaTax Brazil uses HTTP status codes to report API errors.

When an AvaTax Brazil API call produces an error, it responds using standard [HTTP error response codes](https://en.wikipedia.org/wiki/List_of_HTTP_status_codes). Response codes between 400 and 499 are called **client errors**, and indicate a mistake in an API call. Response codes between 500 and 599 refer to internal errors within AvaTax Brazil.

Code

Description

400

Bad request. The request is invalid or can't be processed.

401

Authentication credentials are missing or incorrect.

403

The request is denied because you don't have permission to make this change.

404

The URL requested is invalid or the resource requested doesn't exist.

429

The user has sent too many requests in a given amount of time ("rate limiting").

500

The server has encountered a situation that it doesn't know how to handle.

503

The server isn’t ready to handle the request.