api/javascript/telnyx-numbers-services-javascript/SKILL.md
Configure voicemail, voice channels, and emergency (E911) services for your phone numbers. This skill provides JavaScript SDK examples.
npx skillsauth add team-telnyx/telnyx-toolkit telnyx-numbers-services-javascriptInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
npm install telnyx
import Telnyx from 'telnyx';
const client = new Telnyx({
apiKey: process.env['TELNYX_API_KEY'], // This is the default and can be omitted
});
All examples below assume client is already initialized as shown above.
Returns the dynamic emergency addresses according to filters
GET /dynamic_emergency_addresses
// Automatically fetches more pages as needed.
for await (const dynamicEmergencyAddress of client.dynamicEmergencyAddresses.list()) {
console.log(dynamicEmergencyAddress.id);
}
Creates a dynamic emergency address.
POST /dynamic_emergency_addresses — Required: house_number, street_name, locality, administrative_area, postal_code, country_code
const dynamicEmergencyAddress = await client.dynamicEmergencyAddresses.create({
administrative_area: 'TX',
country_code: 'US',
house_number: '600',
locality: 'Austin',
postal_code: '78701',
street_name: 'Congress',
});
console.log(dynamicEmergencyAddress.data);
Returns the dynamic emergency address based on the ID provided
GET /dynamic_emergency_addresses/{id}
const dynamicEmergencyAddress = await client.dynamicEmergencyAddresses.retrieve(
'182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
);
console.log(dynamicEmergencyAddress.data);
Deletes the dynamic emergency address based on the ID provided
DELETE /dynamic_emergency_addresses/{id}
const dynamicEmergencyAddress = await client.dynamicEmergencyAddresses.delete(
'182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
);
console.log(dynamicEmergencyAddress.data);
Returns the dynamic emergency endpoints according to filters
GET /dynamic_emergency_endpoints
// Automatically fetches more pages as needed.
for await (const dynamicEmergencyEndpoint of client.dynamicEmergencyEndpoints.list()) {
console.log(dynamicEmergencyEndpoint.dynamic_emergency_address_id);
}
Creates a dynamic emergency endpoints.
POST /dynamic_emergency_endpoints — Required: dynamic_emergency_address_id, callback_number, caller_name
const dynamicEmergencyEndpoint = await client.dynamicEmergencyEndpoints.create({
callback_number: '+13125550000',
caller_name: 'Jane Doe Desk Phone',
dynamic_emergency_address_id: '0ccc7b54-4df3-4bca-a65a-3da1ecc777f0',
});
console.log(dynamicEmergencyEndpoint.data);
Returns the dynamic emergency endpoint based on the ID provided
GET /dynamic_emergency_endpoints/{id}
const dynamicEmergencyEndpoint = await client.dynamicEmergencyEndpoints.retrieve(
'182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
);
console.log(dynamicEmergencyEndpoint.data);
Deletes the dynamic emergency endpoint based on the ID provided
DELETE /dynamic_emergency_endpoints/{id}
const dynamicEmergencyEndpoint = await client.dynamicEmergencyEndpoints.delete(
'182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
);
console.log(dynamicEmergencyEndpoint.data);
Returns the non-US voice channels for your account.
GET /channel_zones
// Automatically fetches more pages as needed.
for await (const channelZoneListResponse of client.channelZones.list()) {
console.log(channelZoneListResponse.id);
}
Update the number of Voice Channels for the Non-US Zones.
PUT /channel_zones/{channel_zone_id} — Required: channels
const channelZone = await client.channelZones.update('channel_zone_id', { channels: 0 });
console.log(channelZone.id);
Returns the US Zone voice channels for your account.
GET /inbound_channels
const inboundChannels = await client.inboundChannels.list();
console.log(inboundChannels.data);
Update the number of Voice Channels for the US Zone.
PATCH /inbound_channels — Required: channels
const inboundChannel = await client.inboundChannels.update({ channels: 7 });
console.log(inboundChannel.data);
Retrieve a list of all phone numbers using Channel Billing, grouped by Zone.
GET /list
const response = await client.list.retrieveAll();
console.log(response.data);
Retrieve a list of phone numbers using Channel Billing for a specific Zone.
GET /list/{channel_zone_id}
const response = await client.list.retrieveByZone('channel_zone_id');
console.log(response.data);
Returns the voicemail settings for a phone number
GET /phone_numbers/{phone_number_id}/voicemail
const voicemail = await client.phoneNumbers.voicemail.retrieve('123455678900');
console.log(voicemail.data);
Create voicemail settings for a phone number
POST /phone_numbers/{phone_number_id}/voicemail
const voicemail = await client.phoneNumbers.voicemail.create('123455678900');
console.log(voicemail.data);
Update voicemail settings for a phone number
PATCH /phone_numbers/{phone_number_id}/voicemail
const voicemail = await client.phoneNumbers.voicemail.update('123455678900');
console.log(voicemail.data);
tools
Build cross-platform VoIP calling apps with React Native using Telnyx Voice SDK. High-level reactive API with automatic lifecycle management, CallKit/ConnectionService integration, and push notifications. Use for mobile VoIP apps with minimal setup.
tools
Build browser-based VoIP calling apps using Telnyx WebRTC JavaScript SDK. Covers authentication, voice calls, events, debugging, call quality metrics, and AI Agent integration. Use for web-based real-time communication.
tools
Build VoIP calling apps on iOS using Telnyx WebRTC SDK. Covers authentication, making/receiving calls, CallKit integration, PushKit/APNS push notifications, call quality metrics, and AI Agent integration. Use when implementing real-time voice communication on iOS.
tools
Build cross-platform VoIP calling apps with Flutter using Telnyx WebRTC SDK. Covers authentication, making/receiving calls, push notifications (FCM + APNS), call quality metrics, and AI Agent integration. Works on Android, iOS, and Web.