User Logout
The User Logout API is used to log out an user from the TeleCMI WebRTC SDK. Once the user has logged in and has a valid session, you can use this API to terminate the session cleanly from the SDK.
After the user is authenticated and active on a browser SDK, send a POST request to the following base URL to perform logout.
Base URL
Send your POST method request with valid parameters to the following base URL.
https://rest.connle.com/sbc/logout
Required Parameters
These are the required POST method parameters with description:
Parameter Name | Type | Description |
---|---|---|
agent_id | string | Agent ID assigned to the user (e.g., 1001_1111113 ) |
password | string | Agent's password |
domain | string | Domain the agent is registered to (e.g., sbcind.telecmi.com ) |
Note
Sample JSON Request
Below is the following sample JSON POST method request
{
"agent_id": "1001_1111113",
"password": "password@123",
"domain": "sbcind.telecmi.com"
}
Sample Response
If the provided information is valid, your web server will get a sample response from TeleCMI Platform as given below
{
"code": 200,
"msg": "Logged out successfully",
"sbc_response": {
"jsonrpc": "2.0",
"result": {},
"id": 1
}
}
Properties
These are the list of properties and its description
Property | Type | Description |
---|---|---|
code | number | HTTP status code (e.g., 200 for success) |
msg | string | Status message (e.g., Logged out successfully) |
sbc_response | object | JSON response from the SBC layer |
HTTP status codes
TeleCMI API platform represents the following status code to identity the errors.
Status code | Status Type | Description |
---|---|---|
200 | OK | Logout request received and processed |
401 | Error | Invalid credentials or unauthorized request |
404 | Error | User session not found |