Platform

Platform

  • Getting Started
  • API

›WebRTC JS SDK

Getting Started

  • Create Your App

Quick Starts

  • 555 Samples

Mobile SDK (v1.0)

  • Overview
  • IOS SDK

    • Getting started
    • Installation Guide
    • How to do user authentication
    • How to subscribe for notifications
    • How to initiate or accept PSTN call
    • How to initiate or accept video call
    • How to set log level for SDK
    • Release Notes

    Android SDK

    • Getting started
    • Installation Guide
    • How to do user authentication
    • How to subscribe for notifications
    • How to initiate or accept PSTN call
    • How to initiate or accept video call
    • How to set log level for SDK
    • Release Notes

Mobile SDK (v2.0)

  • Overview
  • IOS SDK

    • Getting started
    • Installation Guide
    • How to do user authentication
    • How to subscribe for notifications
    • How to initiate or accept PSTN call
    • How to initiate or accept VIDEO call
    • How to initiate or join ANONYMOUS VIDEO call
    • Release Notes
    • Reference code - How to initiate or accept PSTN Call
    • Reference code - How to initiate or accept Video Call
    • Reference code - How to initiate or join Anonymous Video Call

    Android SDK

    • Getting started
    • Installation Guide
    • How to do user authentication
    • How to subscribe for notifications
    • How to initiate or accept PSTN call
    • How to intiate or accept Video Call
    • How to intiate or accept ANONYMOUS VIDEO Call
    • Release Notes
    • Reference code - How to initiate or accept PSTN Call
    • Reference code - How to initiate or accept Video Call
    • Reference code - How to initiate or join Anonymous Video Call

    React Native SDK

    • Getting started
    • Installation Guide
    • How to do user authentication
    • How to subscribe for notifications
    • How to initiate or accept PSTN call
    • Release Notes

WebRTC JS SDK

  • Overview
  • Getting Started
  • How to do user authentication
  • How to subscribe for notifications
  • How to initialize SDK
  • How to initiate or accept PSTN call
  • How to initiate or accept video call
  • How to create a screen share session
  • Release Notes

SDK Initialization

Initialize SDK configuration

Update the basic user configuration with IrisRtcConfig.updateConfig API. Mandatory config parameters required are :

var sdkConfig = {
    "urls": {
        "eventManager": "<EVM_URL>",
    },
    "useAnonymousLogin": "<True or false>",
    "logLevel": "< 1 to 3 >",
    "reconnectInterval": "<Time interval in milliseconds>"
}
IrisRtcConfig.updateConfig(sdkConfig);

Establish RTC connection

A successful RTC (websocket) connection is required for a user to initiate a create new session or join a session on invite from other user, this RTC connection is used to manage the connection with 555 backend. It also involves making the necessary REST API calls with event manager and other components to get the resources required for the connection. Instantiate IrisRtcConnection class as

var Connection = new IrisRtcConnection();

Call connect API to with JWT token, routing id of the user and event manager url.

Parameters
tokenjson web token for event manager REST call
routingIdUser's routing Id from Identity manager.
evmUrlEvent Manager URL to get the RTC server info
Connection.connect(token, routingId, evmUrl);

Disconnect from RTC Connection

To disconnect from RtcConnection, use

Connection.close();


Callbacks for RTC Connection

onConnected

This callback is called when the connection is established/successful.

Connection.onConnected = () => {
    // Connection is done
};

onDisconnected

This callback is called when the connection is disconnected.

Connection.onDisconnected = () => {
    // Connection is closed
};

onConnectionError

This callback is called when there is an error.

Connection.onConnectionError = (errorCode, errorMessage) => {
    // Error in connecting
};
Parameters
errorCodeError Code
errorMessageError description

onNotification

This callback is called when notification is received for this RTC connection instance.

Connection.onNotification = (notificationInfo) => {
    // An invite to join a session is received
};
Parameters
notificationInfoNotification payload
← How to subscribe for notificationsHow to initiate or accept PSTN call →
  • Initialize SDK configuration
  • Establish RTC connection
    • Callbacks for RTC Connection
Docs
Getting StartedGuidesAPI Reference
More
BlogGitHub
555 Platform
Copyright © 2024 555 Platform ™
555docs-v0.0.94