WebRTC Service - Getting Started
Download OpenAPI specification:Download
At Your Side:
Generate API Keys
Begin by generating the API keys necessary to authenticate API calls with the iotcomms.io WebRTC Service. This ensures secure access and enables proper interaction with the service.
Firewall Configuration
Configure your firewall to allow HTTPS callbacks from the WebRTC Service. These callback URLs are specified during provisioning, so ensure they are accessible to maintain uninterrupted communication.
Prepare WebRTC Applications
Set up WebRTC applications to use either SIP credentials or JWT tokens for authentication. For enhanced security, applications can generate JWT tokens signed with a private key, while the WebRTC Service is provisioned with the corresponding public key to validate these tokens, eliminating the need to manage SIP credentials. Note that the WebRTC Service listens for SIP over WebSocket on the wss: protocol at port 7443.
Configure PSTN or PBX SIP Trunks
Point your PSTN or PBX SIP trunks to the SIP trunks provisioned in the WebRTC Service, enabling the management of inbound and outbound calls through your existing telephony infrastructure.
Provisioning the Service:
Set Up SIP Trunks
Use the iotcomms.io web interface or provisioning API to configure SIP trunks that connect with your remote telephony systems. This setup enables integration with external PSTN or PBX systems for seamless call routing.Provision Device Authentication
You may pre-provision WebRTC application user IDs using the device provisioning page or API, ensuring that applications are registered and configured to interact reliably with the WebRTC Service.Configure Callback Destinations for Service Alarms
Set up callback URLs for receiving service alarms and notifications from the WebRTC Service. These URLs will receive real-time alerts for any service interruptions or alarms, allowing for quick response and troubleshooting.
Testing the Service:
Register WebRTC Application
Start the WebRTC application to initiate a SIP REGISTER request using SIP over WebSocket.Place a Test Call
Trigger a SIP INVITE over WebSocket to place a call to a phone number routed through a configured SIP trunk. This setup allows you to test end-to-end connectivity from the WebRTC application to the trunk destination.Verify in Developer Portal
JWT Authentication
Confirm in the "Logs" view that JWT tokens are being validated successfully, ensuring secure application access.
SIP REGISTER
Check the logs to ensure that the SIP REGISTER request was received from the WebRTC application and correctly authenticated.
SIP INVITE
Verify in the logs that the SIP INVITE request was received from the WebRTC application and correctly routed to the specified trunk destination. This log verification is essential for confirming successful call initiation and routing through the SIP trunk.
This setup ensures that your WebRTC Service is fully configured, operational, and ready to manage browser-based communications reliably.