POST
/
api
/
v1
/
phone-numbers
/
import
curl -X POST https://api.ravan.ai/api/v1/phone-numbers/import/ \
  -H "X-Api-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "phone": "+14155550100",
    "type": "sip",
    "name": "Office Main Line",
    "termination_uri": "sip:trunk@provider.com",
    "sip_username": "myuser",
    "sip_password": "mysecret"
  }'
{
  "success": true,
  "message": "Phone number imported successfully",
  "data": {
    "id": "019d2a1b-4c5e-7f8a-9b0c-1d2e3f4a5b6c",
    "phone": "+14155550100",
    "type": "sip",
    "name": "Office Main Line",
    "termination_uri": "sip:trunk@provider.com",
    "sip_username": "myuser",
    "sip_password": "mysecret",
    "status": "active",
    "created_at": "2026-03-20T14:30:00Z"
  }
}

Authorizations

X-Api-Key
string
required
Your Agni API key. Find it in your support@ravan.ai under Settings → API Keys.

Body

phone
string
required
Phone number to import in E.164 format (e.g. +14155550100).
type
string
required
Type of telephony connection — e.g. sip, pstn.
name
string
Friendly name for the imported number (e.g. "Office Main Line").
termination_uri
string
SIP termination URI for routing calls (e.g. sip:trunk@provider.com).
sip_username
string
SIP authentication username.
sip_password
string
SIP authentication password.

Response

success
boolean
Whether the request succeeded.
message
string
Human-readable status message.
data
object
The imported phone number record.
curl -X POST https://api.ravan.ai/api/v1/phone-numbers/import/ \
  -H "X-Api-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "phone": "+14155550100",
    "type": "sip",
    "name": "Office Main Line",
    "termination_uri": "sip:trunk@provider.com",
    "sip_username": "myuser",
    "sip_password": "mysecret"
  }'
{
  "success": true,
  "message": "Phone number imported successfully",
  "data": {
    "id": "019d2a1b-4c5e-7f8a-9b0c-1d2e3f4a5b6c",
    "phone": "+14155550100",
    "type": "sip",
    "name": "Office Main Line",
    "termination_uri": "sip:trunk@provider.com",
    "sip_username": "myuser",
    "sip_password": "mysecret",
    "status": "active",
    "created_at": "2026-03-20T14:30:00Z"
  }
}

Authorizations

X-Api-Key
string
header
required

Body

application/json
phone
string

Phone number to import (E.164 format)

type
string

Type of phone number (e.g. sip, pstn)

name
string

Friendly name for the number

termination_uri
string

SIP termination URI

sip_username
string

SIP username for authentication

sip_password
string

SIP password for authentication

Response

Successful response

success
boolean
message
string
data
object