Skip to content

Testing calls

Before you start, make sure that:

Place the call as you would in live mode, with two differences:

  • from_number is your sandbox reference number.
  • to_number must be a verified number.

The person you call sees your sandbox virtual number as the caller ID.

import os
from teler import Client
client = Client(os.environ["TELER_API_KEY"]) # test API key
call = client.voice.calls.create(
from_number="+91XXXXXXXXXX", # sandbox reference number
to_number="+91XXXXXXXXXX", # a verified number
flow_url="https://your-domain.com/flow",
status_callback_url="https://your-domain.com/webhook",
)
print(call.id)

For a SIP Trunk, import the sandbox reference number into your AI agent platform or SIP system and place calls from it. The same verified-number rule applies.

Every Voice App and SIP Trunk created in the sandbox mode gets a 4-digit PIN. The PIN tells Teler which app or trunk the call is for.

  1. From a verified number, dial your sandbox virtual number.
  2. When prompted, enter the 4-digit PIN of the Voice App or SIP Trunk you want to test.
  3. Teler routes the call the way that app or trunk is configured: it fetches the Voice App’s Call Flow, or forwards the call over the SIP Trunk’s inbound route.