WebRTC Service - Getting Started

Download OpenAPI specification:Download

Getting Started

At Your Side:

  1. 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.

  2. 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.

  3. 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.

  4. 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:

  1. 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.
  2. 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.
  3. 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:

  1. Register WebRTC Application

    Start the WebRTC application to initiate a SIP REGISTER request using SIP over WebSocket.
  2. 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.
  3. 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.