# Retrieve an inbound route

`GET https://api.morevoice.ai/v1/inbound_routes/{id}`

Returns an inbound route: what it matches (`connection_id`, `match_did`, `match_caller`), its `priority`, whether it is `enabled`, and its `target`.

Authenticate with a secret API key: `Authorization: Bearer $MOREVOICE_API_KEY`.

Operation ID: `inbound_routes_retrieve`.

## Parameters

### Path parameters

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `id` | `string` | yes | A inbound route ID (`rte_…`). |

### Headers

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `MoreVoice-Version` | `string` | no | The API version to use for this request. Defaults to the version the API key is pinned to. |

## Responses

### 200 OK

OK Returns `InboundRoute`.

| Field | Type | Description |
| --- | --- | --- |
| `id` | `string` | The route's ID. |
| `object` | `"inbound_route"` | — |
| `livemode` | `boolean` | `true` in live mode, `false` in test mode. |
| `name` | `string` | — |
| `enabled` | `boolean` | — |
| `priority` | `integer` | Lower runs first; the first matching route wins. |
| `connection_id` | `string \| null` | `conn_…` ID. |
| `match_did` | `string` | The dialled number: exact, a prefix ending in `*`, or empty for any. |
| `match_caller` | `string` | The caller's number: exact, a prefix ending in `*`, or empty for any. |
| `target` | `RouteTarget \| null` | Where matching calls go (null: the connection's inbound assistant answers). |
| `target.type` | `"assistant" \| "flow" \| "queue" \| "user" \| "conference_room"` | What answers: `assistant` — an AI assistant answers; `flow` — a published voice flow (IVR) runs; `queue` — the call waits in a queue for a human agent; `user` — one person's direct line (their forwarding rules apply); `conference_room` — a conference room (PIN prompt, then join). The ID goes in the field `<type>_id`. |
| `target.assistant_id` | `string` | With `type: assistant`. |
| `target.conference_room_id` | `string` | With `type: conference_room`. |
| `target.flow_id` | `string` | With `type: flow`. |
| `target.queue_id` | `string` | With `type: queue`. |
| `target.user_id` | `string` | With `type: user`. |
| `fallback_assistant_id` | `string \| null` | `asst_…` ID. |
| `assistant_request_url` | `string \| null` | When set, this URL is asked (a signed POST, `assistant.request`) which assistant, flow or queue answers each matching call, and with which variables; the route's own target answers when it does not reply in time. Null: off. |
| `assistant_request_timeout_ms` | `integer` | How long the assistant request may take (200–5000 ms) before the route's own target answers. |
| `stream` | `RouteStream \| null` | When set, your own bot answers the route's calls over a media stream (connect mode) and `target` is null; `fallback_assistant_id` takes the calls your bot can't (unreachable, or it drops). Null: off. |
| `stream.url` | `string` | — |
| `stream.format` | `"mulaw_8000" \| "l16_16000" \| "l16_8000"` | — |
| `stream.custom_parameters` | `Record<string, string>` | — |
| `stream.transcribe` | `boolean` | — |
| `stream.language` | `"he" \| "en" \| null` | — |
| `created` | `string` | An ISO-8601 timestamp in UTC. |

Example:

```json
{
  "assistant_request_timeout_ms": 1500,
  "assistant_request_url": null,
  "connection_id": "conn_2Wq8RfLx0bZt7nKp1VdYhC",
  "created": "2026-11-03T09:14:22.000Z",
  "enabled": true,
  "fallback_assistant_id": "asst_3cYbE6uYvGkH8w4ZK1rTqd",
  "id": "rte_5Hn3MpO0qR5sT7uW9xY1zA",
  "livemode": true,
  "match_caller": "",
  "match_did": "+97231234567",
  "name": "Sales line",
  "object": "inbound_route",
  "priority": 100,
  "stream": null,
  "target": {
    "queue_id": "q_4Gk2LmN9pQ4rS6tV8wX0yZ",
    "type": "queue"
  }
}
```

### 400 Bad Request

The request is invalid: a parameter is missing, malformed or unknown, or the version header is unknown. Returns `ErrorEnvelope`.

### 401 Unauthorized

No valid API key was sent. Returns `ErrorEnvelope`.

### 403 Forbidden

The key may not do this (a missing scope, a plan limit, or a compliance block). Returns `ErrorEnvelope`.

### 404 Not Found

No object with this ID (in the path or the body) exists in this organisation and mode. Returns `ErrorEnvelope`.

### 429 Too Many Requests

Too many requests, or no call capacity right now. Retry after the Retry-After delay. Returns `ErrorEnvelope`.

### 500 Internal Server Error

Something went wrong on MoreVoice's side. Retry with the same Idempotency-Key. Returns `ErrorEnvelope`.

## Code samples

**TypeScript**

```ts
import MoreVoice from "@morevoice/sdk";

const mv = new MoreVoice(); // MOREVOICE_API_KEY from the environment

const inboundRoute = await mv.inboundRoutes.retrieve("rte_7Hk2Lm9Qp");
console.log(inboundRoute);
```

**Python**

```python
from morevoice import MoreVoice

client = MoreVoice()  # MOREVOICE_API_KEY from the environment

inbound_route = client.inbound_routes.retrieve("rte_7Hk2Lm9Qp")
print(inbound_route)
```

**cURL**

```sh
curl https://api.morevoice.ai/v1/inbound_routes/rte_7Hk2Lm9Qp \
  -H "Authorization: Bearer $MOREVOICE_API_KEY"
```
