# List SIP inbound trunks

> GET https://api.nabrah.ai/api/ext/sip-inbound

Group: SIP inbound. Page: https://www.nabrah.ai/en/docs/api-reference/sip-inbound/list-sip-inbound-trunks

Lists every inbound SIP trunk configured for the project that owns your API key. Inbound trunks let incoming SIP/phone calls reach a Nabrah agent: when a call arrives on one of the trunk's numbers, it is answered and routed to the bound agent. The response includes each trunk's id (use it as the path parameter for the GET/DELETE single-trunk endpoints), its display name, associated phone numbers, allowed source addresses, and the SIP digest credentials stored for the project. Authenticate with the `X-API-Key` header; the project is inferred from the key, so no project_id is required.

## What inbound trunks do

Inbound trunks terminate calls into your project.

- **Direction**: Inbound means Nabrah receives calls. A telephony/SIP provider delivers a call to a Nabrah number and the configured agent answers it. This is distinct from outbound trunks, which let an agent place calls out through your own provider.
- **Credentials are per-project**: The `auth_username` and `auth_password` returned here are the digest credentials your SIP provider uses to authenticate when delivering calls to Nabrah. They are stored and scoped to the project tied to your API key.

## Listing returns full records

Each item in `items` is a complete SipInboundResponse.

To retrieve one trunk on its own, call GET /api/ext/sip-inbound/{sip_id} with an `id` value taken from this list.

## Authorization

- `X-API-Key` (string, header, required): your workspace API key.

## Response

### 200 Successful Response

Content type: `application/json`

```json
{
  "items": [
    {
      "name": "string",
      "numbers": "string",
      "id": "00000000-0000-4000-8000-000000000000",
      "project_id": "00000000-0000-4000-8000-000000000000",
      "created_by_email": "string",
      "allowed_addresses": [
        "string"
      ],
      "auth_username": "string",
      "auth_password": "string"
    }
  ]
}
```

## Request examples

### cURL

```bash
curl --request GET \
  --url 'https://api.nabrah.ai/api/ext/sip-inbound' \
  --header 'X-API-Key: <your-api-key>'
```

### Python

```python
import requests

url = "https://api.nabrah.ai/api/ext/sip-inbound"
headers = {"X-API-Key": "<your-api-key>"}

response = requests.get(url, headers=headers)
response.raise_for_status()
print(response.json())
```

### JavaScript

```javascript
const response = await fetch("https://api.nabrah.ai/api/ext/sip-inbound", {
  method: "GET",
  headers: { "X-API-Key": "<your-api-key>" },
});

const data = await response.json();
console.log(data);
```

### Go

```go
package main

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

func main() {
	req, _ := http.NewRequest("GET", "https://api.nabrah.ai/api/ext/sip-inbound", nil)
	req.Header.Set("X-API-Key", "<your-api-key>")

	res, err := http.DefaultClient.Do(req)
	if err != nil {
		panic(err)
	}
	defer res.Body.Close()

	out, _ := io.ReadAll(res.Body)
	fmt.Println(string(out))
}
```
