> ## Documentation Index
> Fetch the complete documentation index at: https://docs.bland.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Agent Number Binding

> Check which phone numbers are attached to an agent and whether each one answers on the production or staging environment.

### Overview

Returns the agent's inbound number binding. `persona_id` is `null` until the first successful [Attach Numbers to Agent](https://docs.bland.ai/api-v2/post/agents-id-inbound-attach.md) call. `numbers` lists the numbers attached to the agent and the environment each one answers on. An unknown agent ID returns `persona_id: null` rather than `404`.

### Headers

**authorization** `string` *required*

Your API key for authentication.

### Path Parameters

**agent\_id** `string` *required*

The agent's unique identifier.

### Response

**data.agent\_id** `string`

The agent ID from the request path, echoed back.

**data.persona\_id** `string | null`

ID of the persona that attached numbers route through. Bland creates it on the first attach and keeps it afterwards, so it stays set even after every number is detached. `null` if numbers have never been attached to this agent.

**data.numbers** `array`

The numbers attached to the agent, newest first. Empty when no number is attached.

**properties**

**phone\_number** `string`

The attached phone number.

**agent\_env\_type** `string | null`

`staging` when calls to the number run the staging version. `null` when they run production.

**data.staging\_attach\_supported** `boolean`

`false` when your account runs on dedicated infrastructure, where numbers can't be attached to staging. Attaching to staging also requires an enterprise plan, which this field does not check.

**errors** `null | array`

`null` on success, or a list of error objects if the request failed.

```json Response theme={null}
{
  "data": {
    "agent_id": "680817f5-147a-4e7f-9d25-eac973e693a5",
    "persona_id": "a308a95d-854d-435a-ae2a-b3d113b59054",
    "numbers": [
      {
        "phone_number": "+18005551234",
        "agent_env_type": "staging"
      },
      {
        "phone_number": "+18005556789",
        "agent_env_type": null
      }
    ],
    "staging_attach_supported": true
  },
  "errors": null
}
```

```json No Binding theme={null}
{
  "data": {
    "agent_id": "818cab80-86c9-46fc-93d8-a7f548b18d7e",
    "persona_id": null,
    "numbers": [],
    "staging_attach_supported": true
  },
  "errors": null
}
```

***

Docs for agents: [llms.txt](https://docs.bland.ai/llms.txt)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.