IClient
Interface that may be used to connect and login to the Voximplant Cloud, and make and receive audio and video calls.
Methods
Call
Call(string
username, callSettings)
Create a new call instance. Call must be then started using ICall.Start().
Parameters
username:
string
SIP URI, username or phone number to make call to. Actual routing is then performed by VoxEngine scenario.
callSettings:
Call settings with additional call parameters, such as preferred video codec, custom data, extra headers etc.
Returns
type:
CallConference
CallConference(string
conference, callSettings)
Create call to a dedicated conference without a proxy session.
For details see the video conferencing guide.
Parameters
conference:
string
The number to call. For SIP compatibility reasons it should be a non-empty string even if the number itself is not used by a Voximplant cloud scenario.
callSettings:
Call settings with additional call parameters, such as preferred video codec, custom data, extra headers etc.
Returns
type:
Connect
void
Connect()
Connect to the Voximplant cloud.
Connectivity check is disabled.
Returns
type:
void
Connect
void
Connect(bool
connectivityCheck, ICollection<string>
gateways)
Connect to the Voximplant cloud with additional configuration.
Parameters
connectivityCheck:
bool
Checks whether UDP traffic will flow correctly between a device and the Voximplant cloud. This check reduces connection speed.
gateways:
ICollection<string>
A collection of server names of particular media gateways for connection.
Returns
type:
void
Disconnect
void
Disconnect()
Close the connection with the Voximplant Cloud.
Returns
type:
void
Login
void
Login(string
username, string
password)
Log in to the specified Voximplant application with password.
Parameters
username:
string
Full user name, including app and account name, like someuser@someapp.youraccount.voximplant.com.
password:
string
User password
Returns
type:
void
LoginWithOneTimeKey
void
LoginWithOneTimeKey(string
username, string
hash)
Perform login using one time key that was generated before.
Parameters
username:
string
Full user name, including app and account name, like someuser@someapp.youraccount.voximplant.com.
hash:
string
Hash that was generated using following formula:
MD5(oneTimeKey + "|" + MD5(user + ":voximplant.com:"+password))
Please note that here user is just a user name, without app name, account name or anything else after "@".
So if you pass myuser@myapp.myacc.voximplant.com as a username, you should only use myuser while computing this hash.
Returns
type:
void
LoginWithToken
void
LoginWithToken(string
username, string
token)
Perform log in using the specified username and the AuthParams.AccessToken.
Parameters
username:
string
Full user name, including app and account name, like someuser@someapp.youraccount.voximplant.com.
token:
string
Access token that was obtained in IClient.LoginSuccess event.
Returns
type:
void
RefreshToken
void
RefreshToken(string
username, string
refreshToken)
Perform refresh of the login tokens required for login using AuthParams.AccessToken.
Parameters
username:
string
Full user name, including app and account name, like someuser@someapp.youraccount.voximplant.com.
refreshToken:
string
AuthParams.RefreshToken that was obtained in IClient.LoginSuccess event.
Returns
type:
void
RequestOneTimeKey
void
RequestOneTimeKey(string
username)
Generates one time login key to be used for automated login process.
Parameters
username:
string
Full user name, including app and account name, like someuser@someapp.youraccount.voximplant.com.
Returns
type:
void