Skip to main content
GET
/
v1
/
public
/
mobile-numbers
Get Mobile Numbers
curl --request GET \
  --url https://api.eigi.ai/v1/public/mobile-numbers \
  --header 'X-API-Key: <api-key>'
import requests

url = "https://api.eigi.ai/v1/public/mobile-numbers"

headers = {"X-API-Key": "<api-key>"}

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

print(response.text)
const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};

fetch('https://api.eigi.ai/v1/public/mobile-numbers', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://api.eigi.ai/v1/public/mobile-numbers",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-Key: <api-key>"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

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

func main() {

url := "https://api.eigi.ai/v1/public/mobile-numbers"

req, _ := http.NewRequest("GET", url, nil)

req.Header.Add("X-API-Key", "<api-key>")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.get("https://api.eigi.ai/v1/public/mobile-numbers")
.header("X-API-Key", "<api-key>")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.eigi.ai/v1/public/mobile-numbers")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<api-key>'

response = http.request(request)
puts response.read_body
{
  "user_id": "<string>",
  "purchased_mobile_numbers": [
    {
      "mobile_number": "<string>",
      "telephony_provider": "<string>"
    }
  ]
}
{
"detail": "<string>"
}
{
"detail": "<string>"
}
{
"detail": "<string>"
}

Overview

Get the list of mobile phone numbers purchased or rented by the API key owner. These numbers can be assigned to agents for inbound/outbound telephony calls.

Authentication

X-API-Key
string
required
Your eigi.ai API key. Must be prefixed with vk_.

Response

user_id
string
Your user ID.
purchased_mobile_numbers
array
Array of mobile number objects, each containing:
  • mobile_number (string): Phone number in E.164 format (e.g., +919876543210)
  • telephony_provider (string): Provider (PLIVO or TWILIO)

Authorizations

X-API-Key
string
header
required

API key for authentication. Get your API key from the eigi.ai Dashboard under Settings → API Keys.

Response

Successfully retrieved mobile numbers

user_id
string

User ID

purchased_mobile_numbers
object[]

List of purchased mobile numbers