.manthu
11/22/2025, 10:48 AMAI Evy
11/22/2025, 10:49 AMAI Evy
11/22/2025, 10:49 AMAI Evy
11/22/2025, 10:49 AMjavascript
import Retell from 'retell-sdk';
const client = new Retell({
apiKey: 'YOUR_RETELL_API_KEY',
}) ;
const phoneNumberResponse = await client.phoneNumber.import({
phone_number: '+14157774444',
termination_uri: 'someuri.pstn.twilio.com',
}) ;
console.log(phoneNumberResponse.inbound_agent_id) ;
When importing, you'll need to provide :
- Your phone number in E.164 format (e.g., +14157774444)
- The termination URI from your telephony provider (for outbound calls)
- Optional authentication credentials if required by your SIP trunk
- Agent IDs for inbound and/or outbound call handling
Once imported, you can bind agents to handle both inbound and outbound calls on your existing number . You can configure different agents for inbound versus outbound calls, or use the same agent for both [(3) ]() [(1) ]() .
The main difference is that with imported numbers, international calling capabilities depend on your telephony provider's settings, whereas Retell-purchased numbers are currently limited to domestic calls only [(3) ]() .
**AI Evy
11/22/2025, 10:49 AM