接入 Viber 渠道
客户在 Viber 上发送的消息会以聊天的形式进入 Click2Reply,客服的回复也会通过 Viber 发回。
在客服应用中接入
Section titled “在客服应用中接入”- 在客服应用中,打开 设置 > 即时通讯应用 并选择 Viber。
- 填写下方字段。
- 在 新聊天发送至 下,选择负责此渠道的分组,然后连接。
在 Viber Admin Panel 中创建机器人,并复制其身份验证令牌。
| 字段 | 键 | |
|---|---|---|
| Auth Token | auth_token | 必填、密钥 |
密钥会加密存储,之后不再显示,仅显示其提示。
通过 API 接入
Section titled “通过 API 接入”使用拥有 channels.manage 的令牌,一次调用即可连接;group_id 为可选:
curl -sS -X POST "https://api.click2reply.com/v1/channels/connections" \ -H "Authorization: Bearer $C2R_TOKEN" \ -H "Content-Type: application/json" \ -d '{"channel":"viber","name":"Viber support","credentials":{"auth_token":"<auth_token>"}}'返回结果为 { connections, manual_steps }:连接信息,以及每个仍需手动完成的步骤(以代码和需粘贴的值表示,例如 Webhook URL)。