Integrate the Telephony SDK

Integrate the Telephony SDK into your application

Prerequisites

Get Started

Integrate the iOS SDK

Add this line to your Podfile near the line pod 'SudoUser'

pod 'SudoTelephony'

Install pod dependencies by running the following command in your project directory:

pod install --repo-update

This will update the local CocoaPods repository and install the latest version of the Telephony SDK.

In order to instantiate a Telephony client, make sure you have followed instructions for Getting Started, User SDK and Sudo SDK (see Prerequisites above)

To instantiate a client in your application, add the following

import SudoTelephony

let userClient = // ... see "Users" docs
let profilesClient = // ... see "Sudos" docs
let callingProviderConfig = // .. Optional. see "Voice Call" docs
let telephonyClient = try! DefaultSudoTelephonyClient(
    sudoUserClient: userClient, 
    sudoProfilesClient: profilesClient,
    callProviderConfiguration: callingProviderConfig
)

If you are integrating voice calling into your application, you must pass in a CallProviderConfiguration. Failure to do so will result in errors being returned when attempting to make a voice call.

You only need one client instance for a given user per device. Instantiating multiple clients with the same configuration and using them at the same time may cause unexpected runtime errors to occur.

See it in action. Be sure to take a look at the open source iOS sample app on GitHub that our team published as a reference for integrating the Telephony SDK into your app as quickly and seamlessly as possible.

Integrate the Android SDK

Add this line to the dependencies section of the app module build.gradle and run gradle sync

dependencies {
    api 'com.sudoplatform:sudotelephony:$latest_version'
}

The latest version of the SDK can be found at SDK Releases.

In order to instantiate a Telephony client, make sure you have followed instructions for Getting Started, User SDK and Sudo SDK (see Prerequisites above).

To instantiate a client in your application, add the following

val userClient = // ... see "Users" docs
val profilesClient = // ... see "Sudos" docs

val telephonyClient = DefaultSudoTelephonyClient(
    appContext, 
    userClient, 
    profilesClient
)

You only need one client instance for a given user per device. Instantiating multiple clients with the same configuration and using them at the same time may cause unexpected runtime errors to occur.

See it in action. Be sure to take a look at the open source Android sample app on GitHub that our team published as a reference for integrating the Telephony SDK into your app as quickly and seamlessly as possible.

Last updated