List phone numbers
curl --request GET \
--url https://api.nixflex.com/v1/phone-numbersimport requests
url = "https://api.nixflex.com/v1/phone-numbers"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.nixflex.com/v1/phone-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.nixflex.com/v1/phone-numbers",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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.nixflex.com/v1/phone-numbers"
req, _ := http.NewRequest("GET", url, nil)
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.nixflex.com/v1/phone-numbers")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.nixflex.com/v1/phone-numbers")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_bodyPhone numbers
List phone numbers
GET /v1/phone-numbers
GET
/
v1
/
phone-numbers
List phone numbers
curl --request GET \
--url https://api.nixflex.com/v1/phone-numbersimport requests
url = "https://api.nixflex.com/v1/phone-numbers"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.nixflex.com/v1/phone-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.nixflex.com/v1/phone-numbers",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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.nixflex.com/v1/phone-numbers"
req, _ := http.NewRequest("GET", url, nil)
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.nixflex.com/v1/phone-numbers")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.nixflex.com/v1/phone-numbers")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_bodyReturns every phone number belonging to your account.
Sorted by
Request
# All numbers
curl https://api.nixflex.com/v1/phone-numbers \
-H "Authorization: Bearer KEY_ID:KEY_SECRET"
# Filter to one agent
curl "https://api.nixflex.com/v1/phone-numbers?agent_id=agent_125207e452f8714a" \
-H "Authorization: Bearer KEY_ID:KEY_SECRET"
Query parameters
| Parameter | Type | Notes |
|---|---|---|
agent_id | string | Optional. Only return numbers attached to this agent |
Response
200 OK:
{
"phone_numbers": [
{
"phone_number": "+447446466847",
"agent_id": "agent_125207e452f8714a",
"provider": "twilio",
"twilio_number_sid": "PN451e0ddf654327e36baab58dfbcd30d6",
"inbound_enabled": true,
"outbound_enabled": true,
"custom_prompt": null,
"created_at": "2026-05-03T01:59:31.548911+00:00"
}
],
"count": 1
}
Response fields
| Field | Type | Notes |
|---|---|---|
phone_number | string | E.164 format |
agent_id | string | The agent this number answers with |
provider | string | The carrier this number is on: twilio or telnyx |
twilio_number_sid | string | Twilio numbers only. null on numbers from other carriers |
inbound_enabled | boolean | Whether the number accepts incoming calls |
outbound_enabled | boolean | Whether the number can place outgoing calls |
custom_prompt | string | Per-number prompt override, or null if unset |
created_at | string | ISO 8601 timestamp |
created_at descending. Returns an empty array (not 404) if no numbers exist.
This endpoint is not paginated and returns up to 1,000 numbers in a single
response. If you hold more than 1,000, use
agent_id to narrow the result.⌘I