> This page is for APIs, version Brazil.
> For other versions, use one of these documentation indexes:
> - Overview (default): https://avalara.ferndocs.com/api-reference/overview/llms.txt
> - Calculations: https://avalara.ferndocs.com/api-reference/calculations/llms.txt
> - E-invoicing: https://avalara.ferndocs.com/api-reference/e-invoicing/llms.txt
> - Brazil: https://avalara.ferndocs.com/api-reference/brazil/llms.txt
> - Returns: https://avalara.ferndocs.com/api-reference/returns/llms.txt
> - Shared service: https://avalara.ferndocs.com/api-reference/shared-service/llms.txt
> - 1099 & W-9: https://avalara.ferndocs.com/api-reference/1099-w9/llms.txt
> - Tax registrations & business licenses: https://avalara.ferndocs.com/api-reference/tax-registrations/llms.txt
> - ECM: https://avalara.ferndocs.com/api-reference/ecm/llms.txt
> - Cross-Border: https://avalara.ferndocs.com/api-reference/cross-border/llms.txt

> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://avalara.ferndocs.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://avalara.ferndocs.com/_mcp/server.

# Retrieve Status of AvaTax Brazil Server - Invoicy Server

GET https://avataxbr.sandbox.avalarabrasil.com.br/v3/ping/invoicy

> **Access control:** this endpoint is available to users with the `everyone` role.

(en) Retrieves Status of AvaTax Brazil Server - Invoice Server
(pt) Recupera Status do AvaTax Brazil Server - Servidor de fatura


Reference: https://avalara.ferndocs.com/api-reference/brazil/public-reference/retrieve-status-invoicy

## Authentication

- `Authorization` header (bearer token, required) — Bearer authentication of the form `Bearer <token>`, where token is your auth token.

## Response

### 200

(en) AvaTax Brazil Server Status - Invoice Server (pt) Status do servidor AvaTax Brasil - Servidor de fatura

- `string`

## Errors

### 400 Bad Request Error

(en) The request was invalid or cannot be otherwise served. (pt) A solicitação era inválida ou não pode ser atendida de outra forma.

- `RetrieveStatusInvoicyRequestBadRequestError`
  - ValidationError: ValidationError
  - TraceError: TraceError

### 401 Unauthorized Error

(en) Authentication credentials were missing or incorrect. (pt) As credenciais de autenticação estavam ausentes ou incorretas.

- `message` (string, optional)

### 403 Forbidden Error

(en) The request is understood, but it has been refused or access is not allowed. (pt) O pedido foi entendido, mas foi recusado ou o acesso não é permitido.

- `message` (string, optional)

### 404 Not Found Error

(en) The URI requested is invalid or the resource requested does not exists. (pt) O URI solicitado é inválido ou o recurso solicitado não existe.

- `message` (string, optional)

### 429 Too Many Requests Error

(en) The request cannot be served due to the application’s rate limit having been exhausted for the resource. (pt) A solicitação não pode ser atendida porque o limite de taxa do aplicativo foi esgotado para o recurso.

- `message` (string, optional)

### 500 Internal Server Error

(en) Something is broken (pt) Algo está quebrado

- `message` (string, optional)

### 503 Service Unavailable Error

(en) The server is up, but overloaded with requests. Try again later. (pt) O servidor está ativo, mas sobrecarregado com solicitações. Tente mais tarde.

- `message` (string, optional)

## Types

### ValidationError

- `code` (string, optional)
- `message` (string, optional)
- `innerError` (list of AJVError, optional)

### TraceError

- `code` (string, optional)
- `message` (string, optional)
- `innerError` (list of MemoryError, optional)

### AJVError

- `message` (string, required)
- `code` (string, optional)
- `field` (string, optional)
- `value` (string, optional)
- `in` (enum, optional)
  - Allowed values: `params`, `body`, `query`

### MemoryError

- `message` (string, required)
- `code` (string, optional)
- `lineIndex` (double, optional)
- `lineCode` (string, optional) — (en) This line item in the transaction (pt) Número da linha da transação por item Usage Purpose: Calculation/Invoice
- `itemCode` (string, optional) — (en) Item code inside ERP (pt) Código do item dentro do ERP Usage Purpose: Calculation/Invoice
- `where` (MemoryWhereError, optional)
- `list` (list of MemoryCitationError, optional)

### MemoryWhereError

- `type` (string, optional)
- `hsCodes.codeType` (string, optional)
- `hsCodes.code` (string, optional)
- `hsCodes.ex` (string, optional)
- `hsCodes.cest` (string, optional)
- `stateFrom` (string, optional)
- `stateTo` (string, optional)
- `serviceCode` (string, optional) — (en) City service code where the service will be executed. (pt) Código de serviço da cidade onde o serviço será executado. Usage purpose: Calculation/Invoice
- `cityCode` (double, optional)

### MemoryCitationError

- `id` (string, optional)
- `citation` (string, optional)
- `rate` (double, optional) — (en) Tax rate (pt) Alíquota Usage Purpose Calculation/Invoice
- `cst` (string, optional) — (en) Tax status code (rule of taxation) (pt) Código de situação tributária Usage Purpose: Calculation/Invoice/Do not apply for services

## Examples

**Response**

```json
"string"
```

**SDK Code**

```python
import requests

url = "https://avataxbr.sandbox.avalarabrasil.com.br/v3/ping/invoicy"

headers = {"Authorization": "Bearer <token>"}

response = requests.get(url, headers=headers)

print(response.json())
```

```javascript
const url = 'https://avataxbr.sandbox.avalarabrasil.com.br/v3/ping/invoicy';
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "https://avataxbr.sandbox.avalarabrasil.com.br/v3/ping/invoicy"

	req, _ := http.NewRequest("GET", url, nil)

	req.Header.Add("Authorization", "Bearer <token>")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby
require 'uri'
require 'net/http'

url = URI("https://avataxbr.sandbox.avalarabrasil.com.br/v3/ping/invoicy")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'

response = http.request(request)
puts response.read_body
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.get("https://avataxbr.sandbox.avalarabrasil.com.br/v3/ping/invoicy")
  .header("Authorization", "Bearer <token>")
  .asString();
```

```php
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('GET', 'https://avataxbr.sandbox.avalarabrasil.com.br/v3/ping/invoicy', [
  'headers' => [
    'Authorization' => 'Bearer <token>',
  ],
]);

echo $response->getBody();
```

```csharp
using RestSharp;

var client = new RestClient("https://avataxbr.sandbox.avalarabrasil.com.br/v3/ping/invoicy");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer <token>");
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let headers = ["Authorization": "Bearer <token>"]

let request = NSMutableURLRequest(url: NSURL(string: "https://avataxbr.sandbox.avalarabrasil.com.br/v3/ping/invoicy")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```