WSS errors and Active Stream Monitoring
Active Stream Monitoring
Check how many streams are live on your account.
Authentication
HTTP Basic Auth — API Key as username, API Token as password.
Example request
curl -u '<api_key>:<api_token>' -X GET \
'https://api.in.exotel.com/v1/Accounts/<AccountSid>/ActiveStreams'
Example response
This endpoint returns XML (legacy v1 format), not JSON — unlike most other AgentStream examples in this section.
<?xml version="1.0" encoding="UTF-8"?>
<TwilioResponse>
<Stream>
<ActiveStreamCount>0</ActiveStreamCount>
<ThrottleLimit>100</ThrottleLimit>
</Stream>
</TwilioResponse>
Path is case-sensitive: use ActiveStreams (not activestreams).
Try It
WSS close codes
| Code | Meaning | Common cause |
|---|---|---|
1000 | Normal closure | Clean disconnect |
1001 | Endpoint going away | Server restart |
1002–1003 | Protocol / data error | Malformed frames |
1006 | Abnormal closure | Network drop · TLS failure · server crash |
1007–1009 | Payload / policy / size | Chunk out of bounds |
1011 | Server error | Unhandled exception |
1012–1013 | Restart / retry | Transient — retry |
1006 checklist
- WSS URL reachable from the public internet
- TLS certificate valid for the hostname
- Firewall allows Exotel egress IPs (ask support for the current list)
- Handshake completes within ~10 s
Support payload
When opening a ticket, include:
- Account SID
- Call SID / Stream SID
- Approximate timestamp (IST)
- WSS close code and server logs around the failure
error/detailedstatusfrom Passthru if present