Test Calls

Test an Edesy termination trunk outbound and inbound, and test a saved SIP destination, from the portal or with the test-call API, before using the phone network.

2 min read

Edesy has three built-in tests: an outbound test that rings a phone through your trunk, an inbound test that calls your trunk's inbound target, and a destination test that calls a saved SIP destination. Each places a real call, so you can check the Edesy side on its own before your PBX or the phone network is involved.

What each test checks#

Test Where What it proves
Outbound test Trunk page → Test & connectivity Edesy can place a call through this trunk to the phone network
Inbound test Trunk page → Test & connectivity Your trunk-level inbound SIP URI answers, or your inbound webhook returns valid VoiceML
Destination test SIP → Inbound destinations → Test call The saved SIP URI is reachable and your agent or PBX answers
Connectivity Trunk page → Connectivity Registration state (credentials) or the allowlist (IP mode)

Outbound test#

  1. Open the trunk page.
  2. In Outbound test call, enter a destination number in E.164, such as +91XXXXXXXXXX.
  3. Start the test. The panel shows status, duration and hangup cause.
curl -X POST https://voice-api.edesy.in/v1/trunks/TRUNK_ID/test-call \
  -H "Authorization: Bearer sk_YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"direction": "outbound", "destination": "+91XXXXXXXXXX", "from": "+91YYYYYYYYYY"}'

from is optional and must be a number you own. The response is {"kind": "call", "call_sid": "..."}; poll GET/v1/calls/:call_sid for live status.

Inbound test#

Set an inbound target on the trunk first (SIP URI or webhook). Then:

curl -X POST https://voice-api.edesy.in/v1/trunks/TRUNK_ID/test-call \
  -H "Authorization: Bearer sk_YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"direction": "inbound"}'

For a SIP target, Edesy calls it and you get a call_sid. For a webhook target, Edesy probes the URL and returns {"kind": "probe", "reachable": true, "http_status": 200, "valid_voiceml": true} without placing a call.

Destination test#

curl -X POST https://voice-api.edesy.in/v1/sip-destinations/DEST_ID/test-call \
  -H "Authorization: Bearer sk_YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"from": "+91YYYYYYYYYY"}'

The caller ID defaults to your first active number. The answered leg hears a short announcement.

HTTP error Code Meaning
429 rate_limited More than 5 test calls in an hour
402 insufficient_balance Top up the wallet
422 no_caller_id You have no active number to call from
403 caller_id_not_owned The from number is not yours
400 sip_uri_missing The destination has no URI

Check connectivity#

curl https://voice-api.edesy.in/v1/trunks/TRUNK_ID/status \
  -H "Authorization: Bearer sk_YOUR_API_KEY"

The response shows mode (registration or ip_allowlist), registered, the registered contact and expires_in for credentials trunks, or allowed_ips for IP trunks.

FAQ#

Are test calls billed?#

Yes, at the normal Rs 0.50/min rate. They are limited to 5 per hour per workspace.

The outbound test works but my PBX's calls fail. What does that mean?#

The Edesy side is fine. Check your PBX's auth, caller ID and number format, and look up the SIP response code in Common SIP Response Codes.

The destination test fails at once. Where do I look?#

Usually the far end rejects Edesy: its IP allowlist is missing Edesy's signalling IP, it expects credentials, or the URI has no user part.

Was this page helpful?