Telemarketing Capability (iOS-SDK)
ZhiChi Customer Service provides enterprises with a complete set of intelligent customer service solutions. The ZhiChi Telemarketing SDK supports all telemarketing-related functions. By simply providing the account to be used, tasks like telemarketing, outbound calls, call monitoring, and call recording can be completed. The ZhiChi telemarketing SDK has the following features:- Provide the complete process of login - use - logout.
- There are 2 types of login modules: external login with token synchronization and regular username/password login.
- Supports basic functions such as call phone registration, call record inquiry, call monitoring, and agent status switching.
Relevant restrictions and precautions:
- The new version of the iOS SDK supports iOS 11 and above, and is compatible with both iPhone and iPad.
- IOS requires microphone permission; otherwise, the call function cannot work.
- The SDK cannot be used at the same time as the call function in the Zhichi Customer Service APP and the call function in the Zhichi PC workstation.
Process Description
Integration Process Diagram
File Description
The SDK includes (SobotTelemarketingSDK.framework, SobotCallLib.framework, SobotCommon.framework, SobotCall.bundle, and SobotCommon.bundle), SobotTMDemo, and Doc-related documentation. | File |Description| |:----|:----|:----|:----| | SobotTelemarketingSDK.framework | Sobot Telemarketing SDK Code Library | | SobotCommon.framework | Base dependency library for ZhiChi code | | SobotCallLib.framework | janus and webstomp dependency libraries | | SobotCommon.bundle | Resource library for basic toolkits, including image files, multilingual files, and colors | | SobotCall.bundle | SDK resource library, including image files, multilingual files, and colors | | SobotTMApi.h | This file provides access functions | | SobotTMParameter.h | Basic UI configuration parameter class | | SobotCallCacheEntity.h | Basic function parameter class (domain name, color, language, display mode, etc.) | | SobotTMHomeV6Controller.h | Telemarketing Entry Interface | | SobotTMClient.h | Basic Functions |Integration Method
Manual Integration
Download link: iOS_CallTM Unzip [iOS_SDK], and add the necessary files SobotTelemarketingSDK.framework, SobotCommon.framework, SobotCallLib.framework, SobotCommon.bundle, and SobotCall.bundle to your project.CocoaPods Integration
Add the following to your Podfile:Quick Start
Step 1 Permission Settings
Permissions to be addedStep 2 Initialization and Domain Setup
Domain Name Description:- The default SaaS platform domain name is: https://api.sobot.com.
- If you are a Tencent Cloud service, please set it to: https://www.soboten.com.
- If you are using a localized deployment, please use your own service domain name.
Example code:
Step 3 Start the ZhiChi page
Method 1: Use the method we provide to automatically complete login and redirect to the page. Method:
Example code:
Example:
Example code:
Function Description
Open API
Initialization
The first step in using the open API is to set the initialization configuration.
Example:
Request Parameters
See the description of SobotCallCacheEntity for details.Callback Function
For details, see the SobotTMResultBlock description.Login Operation
Login
- The return values of this interface will continue to add attributes. Please use the correct compatibility coding method to ensure that the calling code does not throw errors when return value attributes are added.
Example:
Request Parameters
Callback Function
See the SobotTMResultBlock description for details.Check In
- The return values of this interface will keep adding attributes. Please use the correct compatible coding method to ensure that the calling code will not throw errors when return value attributes are added!
- The system gets the latest agent ID in this interface. If you change the ID, the new ID will take effect after you sign in again.
- Calling the check-in interface from one end will cause other ends to disconnect (not offline agents);
- Support the login status of the agent server = offline, online, and all other status check-ins. But when the agent server’s working status = calling, ringing, in a call, on hold, or in wrap-up, check-in is not allowed.
Example:
Request Parameters
Return Value of Success Callback Function
Skill Group Information QueueAgentCheckin
Callback Function
See the SobotTMResultBlock description for details.Check Out
- The return values of this interface will keep adding attributes. Please use the correct compatibility coding method to ensure that the calling code does not throw errors when return value attributes are added!
- The agent’s working status must be “Ready”, “Busy”, or “Locked”. Otherwise, it is not allowed.
Example:
Callback Function
For details, see the SobotTMResultBlock description.Busy Status
- The return values of this interface will continue to add attributes. Please use the correct compatibility coding method to ensure that the calling code does not throw errors when return value attributes are added!
Example:
Request Parameters
Callback Function
See the SobotTMResultBlock description for details.Idle Placement
- The return values of this interface will continue to add attributes. Please use the correct compatible coding method to ensure that the calling code will not throw errors when return value attributes are added!
Example:
Callback Function
See the SobotTMResultBlock description for details.Query Agent’s Login Information
- The return values of this interface will continue to add attributes. Please use the correct compatible coding method to ensure that the calling code does not throw errors when return value attributes are added!
- Call this interface after logging in successfully.
Example:
Return Value
Callback Function
See the SobotTMResultBlock description for details.Query the available answering methods for the seat
- The return values of this interface will continue to add attributes. Please use the correct compatible coding method to ensure that the calling code does not throw errors when return value attributes are added!
- Call this interface after logging in successfully.
Example:
Return Value
Callback Function
For details, see the SobotTMResultBlock description.Query Available Extension Numbers for Agent Seats
- The return values of this interface will keep adding attributes. Please use the correct compatibility method to code, ensuring that the calling-end code will not throw errors when return value attributes are added!
- Call this interface after logging in successfully.
Example:
Return Value
Ext Description
Callback Function
See the description of SobotTMResultBlock for more details.Query the login status of the agent
- The return values of this interface will continue to add attributes. Please use the correct compatibility coding method to ensure that the calling code will not throw errors when return value attributes are added!
- Call this interface after logging in successfully.
Example:
Callback Function
See the SobotTMResultBlock description for details.Query Available Busy Reasons for Agent Seats
- The return values of this interface will continue to add attributes. Please use the correct compatibility method for encoding, ensuring that the code on the calling side does not throw errors when return value attributes are added!
Example:
Return Value
AgentBusyStatus
Callback Function
For details, see the SobotTMResultBlock description.Query the skill groups that the agent can sign in to
- The return values of this interface will continue to add attributes. Please use the correct compatibility coding method to ensure that the calling code does not throw errors when return value attributes are added!
Example:
Return Value
Callback Function
For details, see the SobotTMResultBlock description.Reset Offline (Log Out)
- The return values of this interface will keep adding attributes. Please use the correct compatible coding method to ensure that the calling code does not throw errors when return value attributes are added!
Example:
Callback Function
See the SobotTMResultBlock description for details.Call Operation
Outbound Call
- The return values of this interface will continue to add attributes. Please use the correct compatibility method for coding to ensure that the calling code does not throw errors when return value attributes are added!
Example:
Request Parameters
Callback Function
For details, see the SobotTMResultBlock description.Answer the Call
- The return values of this interface will keep adding attributes. Please use the correct compatibility coding method to ensure that the calling code won’t throw errors when new attributes are added to the return values!
Example:
Callback Function
See the SobotTMResultBlock description for details.Hang Up
- The return values of this interface will continue to add attributes. Please use the correct compatibility coding method to ensure that the calling code does not throw errors when return value attributes are added!
Example:
Callback Function
See the SobotTMResultBlock description for details.Keep
- The return values of this interface will continue to add attributes. Please use the correct compatibility coding method to ensure that the calling code does not throw errors when return value attributes are added!
- Temporarily suspend the call between the agent and the customer. After holding, the customer will hear hold music, and the agent side will be muted.
- This operation supports 3 answering methods: SIP phone, web page, and mobile phone.
Example:
Callback Function
See the description of SobotTMResultBlock for more details.Cancel Hold
- The return values of this interface will continue to add attributes. Please use the correct compatibility coding method to ensure that the calling code does not throw errors when return value attributes are added!
- Restore the suspended call between the agent and the customer. After canceling the hold, the customer and the agent resume normal conversation.
Example:
Callback Function
See the SobotTMResultBlock description for details.Mute
- The return values of this interface will continue to add attributes. Please use the correct compatibility coding method to ensure that the calling code does not throw errors when return value attributes are added!
- Turn off the microphone of the operator’s station so that others cannot hear the sound from the current station. For example: Agent A consults with Agent B, and both Agent A and Agent B can operate to mute their own microphones.
- The listener does not support this operation (the initiator’s microphone is always off during monitoring).
- This operation supports 3 answering methods: SIP phone, web page, and mobile phone.
Example:
Callback Function
See the SobotTMResultBlock description for details.Unmute
- The return values of this interface will continue to add attributes. Please use the correct compatibility coding method to ensure that the calling code does not throw errors when return value attributes are added!
- Restore the microphone on the agent side so that others and the agent can resume normal calls.
Example:
Callback Function
See the SobotTMResultBlock description for details.Query Sound Playback Type
Switch between the earpiece and speaker.Example:
Return Value
Set Sound Playback Type
Switch between the earpiece and speaker.Example:
Return Value
Callback Function
See the SobotTMResultBlock description for details.Send Satisfaction
- The return values of this interface will keep adding attributes. Please use the correct compatible coding method to ensure that the calling code will not throw errors when return value attributes are added!
- After the agent sends the satisfaction survey, the system disconnects all agent-side calls (including monitoring; three-way calls, etc.), keeps the customer-side call, and plays the satisfaction evaluation. At the same time, it hangs up all agent-side calls.
Example:
Callback Function
See the SobotTMResultBlock description for details.Extend the Tidying Duration
- The return values of this interface will continue to add attributes. Please use the correct compatibility coding method to ensure that the calling code does not throw errors when return value attributes are added!
- When the agent’s phone status is in wrap-up, you can extend the wrap-up duration; 30-900 seconds.
Example:
Request Parameters
Callback Function
See the SobotTMResultBlock description for details.Finish Arranging
- The return values of this interface will keep adding attributes. Please use the correct compatibility coding method to ensure that the calling code will not throw errors when return value attributes are added!
- When the agent’s phone status is in the “organizing” state, you can end the organizing state early.
Example:
Callback Function
For details, see the SobotTMResultBlock description.Finish organizing and set to busy
- The return values of this interface will keep adding attributes. Please code with proper compatibility to ensure that the calling code won’t throw errors when new attributes are added to the return values!
- When the agent’s phone status is in wrap-up, they can end the wrap-up status early and switch to Do Not Disturb mode.
Example:
Return Value of Callback Function
See the SobotTMResultBlock description for details.Send Button
- The return values of this interface will continue to add attributes. Please use the correct compatibility coding method to ensure that the calling code does not throw errors when return value attributes are added!
Example:
Request Parameters
Callback Function Return Value
See the SobotTMResultBlock description for details.Auxiliary Operations
Query the Outbound Routing Rules for Seats
- The return values of this interface will continue to add attributes. Please use the correct compatible coding method to ensure that the calling code does not throw errors when return value attributes are added!
- After the agent signs in, the agent can check the outbound routing rules set in the “Outbound Routing” for agents.
Example
Return Value of Callback Function
For details, see the SobotTMResultBlock description.Return Value obj Description
Table 1 explicitRule Explanation of Explicit Rule Array
Table 2 explicitSchema Dynamic External Schema Array Description
Table 3 explicitNumbers Description of the explicit number array
Modify the Outbound Routing Rules for Seats
- The return values of this interface will keep adding attributes. Please use the correct compatible coding method to ensure that the calling code won’t throw errors when new attributes are added to the return values!
- When the agent’s phone is idle, the system can switch to the last used outbound rule for that agent.
Example:
Request Parameters
Return Value of Callback Function
See the description of SobotCallResultBlock for details.Return Value
Table 1 explicitRule Array of Explicit Rules Description
Table 2 explicitSchema Dynamic External Schema Array Description
Table 3 explicitNumbers Description of the explicit number array
General Attribute Description
Unified Callback Interface SobotCallResultBlock
All interfaces uniformly use this rule to return results. It has returned to the main thread, and you can directly refresh the UI.
When the status is successful, please use the following listener to get the real-time status of the agent and call events:
Event description reference Call Event (TS).
Listen for call events
● SobotTMParameter Class Description
The configuration takes effect immediately. Use the following function in SobotTMApi.h to configure. Initialization and direct configuration will override the previous setting value;
Setup method: