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

# Get agent

GET https://api.getvoxai.com/v1/agents/{agent_id}

Returns one agent with the same fields as in the list: name, language, phone line, state and the variables declared by the organization. The value of a variable with a fixed value is never returned here: `has_default` only tells whether it is set (read it with `GET /agents/{agent_id}/variables`). An agent of another organization, a colleague of a team and an agent that does not exist all give `404`. Required scope: `agents:read`. With a test key (`vx_test_`) it behaves exactly as with a live key and consumes nothing.

Reference: https://docs.getvoxai.com/api-reference/agents/get

## Authentication

- `Authorization` header (bearer token, required) — API key created by an Owner or Admin of the organization. Never in the query string.

## Request

### Path parameters

- `agent_id` (string, required) — Id of an agent of the organization, as returned by `GET /agents`.

### Headers

- `VoxAI-Version` (enum, optional) — API version for this request; defaults to the version the key is pinned to.
  - Allowed values: `2026-10-01`

## Response

### 200

Successful response.

- `object` ("agent", required) — Always `agent`.
- `id` (string, required) — Id of the agent. Use it in the path of the other agent endpoints and as `agent_id` wherever an agent is asked for.
- `name` (string, required) — Name of the agent: the name of the assistant, or the name of the business when the assistant has no name. A default name when neither is set.
- `language` (string, required) — Base language of the agent, for example `it`; `multi` for a multilingual agent.
- `line_number` (string, required, nullable) — The phone line assigned to the agent, if any.
- `status` (enum, required) — `active`: the agent works normally. `suspended`: the agent does not answer (callers hear busy), does not call, its web widget does not open and its campaigns are paused. Calls already in progress end normally.
  - Allowed values: `active`, `suspended`
- `suspended_at` (datetime, required, nullable) — When the agent was suspended; `null` when it is active.
- `created_at` (datetime, required, nullable) — When the agent was created. `null` for some older agents.
- `updated_at` (datetime, required, nullable) — When the agent was last changed. `null` when it is not recorded.
- `variables` (list of AgentsAgentIdGetResponsesContentApplicationJsonSchemaVariablesItems, required) — Variables declared by the organization for this agent (not the ones the platform always provides).

## Errors

### 400 Bad Request Error

Possible errors: * `invalid_api_version`: The `VoxAI-Version` header names a version that does not exist. Use one of the versions listed in the `VoxAI-Version` parameter, or omit the header to use the version the key is pinned to. * `invalid_request`: The path, query or body does not match the schema of the operation: a missing or unknown field, a wrong type, a value out of range. Fix the request. `details` lists each problem as `{ location, path, message }`: `location` is `params`, `query` or `body` and `path` points to the field.

- `error` (string, required) — Human-readable message in English.
- `code` (string, required) — Stable machine-readable code; decide what to do from this, never from the message.
- `requestId` (string, required) — Same value as the X-Request-Id response header; quote it when contacting support.
- `details` (any, optional) — Extra information, only on some codes. For `invalid_request` it is a list of `{ location, path, message }`, one per field (`location` is `params`, `query` or `body`) with a problem; for the other codes its fields depend on the code (for example `details.limit`).

### 401 Unauthorized Error

Possible errors: - `invalid_api_key`: The `Authorization` header is missing, malformed, or carries a key that does not exist, was revoked or has expired. Send `Authorization: Bearer vx_live_…` (or `vx_test_…`) with an active key. Create a new key in the app if this one expired.

- `error` (string, required) — Human-readable message in English.
- `code` (string, required) — Stable machine-readable code; decide what to do from this, never from the message.
- `requestId` (string, required) — Same value as the X-Request-Id response header; quote it when contacting support.
- `details` (any, optional) — Extra information, only on some codes. For `invalid_request` it is a list of `{ location, path, message }`, one per field (`location` is `params`, `query` or `body`) with a problem; for the other codes its fields depend on the code (for example `details.limit`).

### 403 Forbidden Error

Possible errors: - `feature_not_available`: The plan of the organization does not include the API, or the feature this operation needs. Upgrade the plan in the app. Reads and deletions stay available after a downgrade. - `insufficient_scope`: The key does not have the scope this operation requires (written in the description of the operation). Create a key with the required scope (an Owner or Admin can do it in the app), or ask for the scope to be added. - `ip_not_allowed`: The key has an IP allow-list and the request comes from an address that is not on it. Call from an allowed address, or add this address to the key in the app. - `organization_suspended`: The organization that owns the key is suspended. Contact the organization Owner: nothing can be done through the API until the organization is active again.

- `error` (string, required) — Human-readable message in English.
- `code` (string, required) — Stable machine-readable code; decide what to do from this, never from the message.
- `requestId` (string, required) — Same value as the X-Request-Id response header; quote it when contacting support.
- `details` (any, optional) — Extra information, only on some codes. For `invalid_request` it is a list of `{ location, path, message }`, one per field (`location` is `params`, `query` or `body`) with a problem; for the other codes its fields depend on the code (for example `details.limit`).

### 404 Not Found Error

Possible errors: - `not_found`: The resource does not exist, or it belongs to another organization: the two cases give the same answer on purpose. Check the id. Ids come from the list operations of the same organization.

- `error` (string, required) — Human-readable message in English.
- `code` (string, required) — Stable machine-readable code; decide what to do from this, never from the message.
- `requestId` (string, required) — Same value as the X-Request-Id response header; quote it when contacting support.
- `details` (any, optional) — Extra information, only on some codes. For `invalid_request` it is a list of `{ location, path, message }`, one per field (`location` is `params`, `query` or `body`) with a problem; for the other codes its fields depend on the code (for example `details.limit`).

### 429 Too Many Requests Error

Possible errors: - `rate_limited`: Too many requests: over the per-minute limit of this key or of the whole organization (see `rate_limits` in `GET /me`), or over a limit of the operation itself, such as the hourly limit on webhook tests and resends. Wait for the number of seconds in the `Retry-After` header, then retry. Spread requests over time.

- `error` (string, required) — Human-readable message in English.
- `code` (string, required) — Stable machine-readable code; decide what to do from this, never from the message.
- `requestId` (string, required) — Same value as the X-Request-Id response header; quote it when contacting support.
- `details` (any, optional) — Extra information, only on some codes. For `invalid_request` it is a list of `{ location, path, message }`, one per field (`location` is `params`, `query` or `body`) with a problem; for the other codes its fields depend on the code (for example `details.limit`).

### 500 Internal Server Error

Possible errors: - `internal_error`: An unexpected error on our side. Retry once after a few seconds. For writes marked as retriable, retry with the same `Idempotency-Key`, so the operation is never done twice; for the other writes, first read the state of the resource, then retry with a NEW key only if the operation did not happen. If it persists, contact support with the `requestId`.

- `error` (string, required) — Human-readable message in English.
- `code` (string, required) — Stable machine-readable code; decide what to do from this, never from the message.
- `requestId` (string, required) — Same value as the X-Request-Id response header; quote it when contacting support.
- `details` (any, optional) — Extra information, only on some codes. For `invalid_request` it is a list of `{ location, path, message }`, one per field (`location` is `params`, `query` or `body`) with a problem; for the other codes its fields depend on the code (for example `details.limit`).

### 503 Service Unavailable Error

Possible errors: - `api_not_configured`: The API is not enabled on this service. Contact support.

- `error` (string, required) — Human-readable message in English.
- `code` (string, required) — Stable machine-readable code; decide what to do from this, never from the message.
- `requestId` (string, required) — Same value as the X-Request-Id response header; quote it when contacting support.
- `details` (any, optional) — Extra information, only on some codes. For `invalid_request` it is a list of `{ location, path, message }`, one per field (`location` is `params`, `query` or `body`) with a problem; for the other codes its fields depend on the code (for example `details.limit`).

## Types

### AgentsAgentIdGetResponsesContentApplicationJsonSchemaVariablesItems

- `name` (string, required) — Name of the variable, used as `{{name}}` in the texts of the agent.
- `source` (enum, required) — `static`: fixed value of the agent. `contact`: field of the contact, different at every call. `call`: data of the call in progress. `system`: computed by the platform.
  - Allowed values: `static`, `contact`, `call`, `system`
- `description` (string, required) — What the variable is for, as written by the organization. Empty when none was given.
- `required` (boolean, required) — true when the value must be supplied for every call: a `contact` variable with no default.
- `has_default` (boolean, required) — Whether the variable has a fixed value (`static`) or a fallback (the others).
- `default_value` (string, required, nullable) — The fallback of a `contact` or `call` variable. Always `null` for a `static` variable: its fixed value is part of the agent configuration and is not exposed.

## Examples

**Response**

```json
{
  "object": "agent",
  "id": "reception-studio-rossi",
  "name": "Reception Studio Rossi",
  "language": "it",
  "line_number": "+390212345678",
  "status": "active",
  "suspended_at": null,
  "created_at": "2026-09-02T08:15:00Z",
  "updated_at": "2026-11-10T14:32:10Z",
  "variables": [
    {
      "name": "indirizzo_studio",
      "source": "static",
      "description": "Address of the office",
      "required": false,
      "has_default": true,
      "default_value": null
    },
    {
      "name": "nome_cliente",
      "source": "contact",
      "description": "First name of the person called",
      "required": true,
      "has_default": false,
      "default_value": null
    }
  ]
}
```

**SDK Code**

```python
import requests

url = "https://api.getvoxai.com/v1/agents/reception-studio-rossi"

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

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

print(response.json())
```

```javascript
const url = 'https://api.getvoxai.com/v1/agents/reception-studio-rossi';
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://api.getvoxai.com/v1/agents/reception-studio-rossi"

	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://api.getvoxai.com/v1/agents/reception-studio-rossi")

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://api.getvoxai.com/v1/agents/reception-studio-rossi")
  .header("Authorization", "Bearer <token>")
  .asString();
```

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

$client = new \GuzzleHttp\Client();

$response = $client->request('GET', 'https://api.getvoxai.com/v1/agents/reception-studio-rossi', [
  'headers' => [
    'Authorization' => 'Bearer <token>',
  ],
]);

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

```csharp
using RestSharp;

var client = new RestClient("https://api.getvoxai.com/v1/agents/reception-studio-rossi");
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://api.getvoxai.com/v1/agents/reception-studio-rossi")! 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()
```