Skip to content

Commit 7fa80db

Browse files
authored
feat(docs): add ban management (#1580)
1 parent 21920a1 commit 7fa80db

File tree

5 files changed

+133
-0
lines changed

5 files changed

+133
-0
lines changed

payloads/management/v3.6/configuration-api/index.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,3 +31,6 @@ export { default as getLicenseID } from "./responses/other/getLicenseID.json"
3131
export { default as listChannels } from "./responses/other/listChannels.json"
3232
export { default as checkProductLimitsForPlan } from "./responses/other/checkProductLimitsForPlan.json"
3333
export { default as getProductSource } from "./responses/other/getProductSource.json"
34+
35+
export { default as listCustomerBans } from "./responses/bans/listCustomerBans.json"
36+
export { default as unbanCustomer } from "./responses/bans/unbanCustomer.json"
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
[
2+
{
3+
"ip": "192.168.8.1",
4+
"agent_id": "[email protected]",
5+
"created_at": "2025-08-07T06:51:43.000000Z",
6+
"expires_at": "2025-08-14T06:51:43.000000Z"
7+
},
8+
{
9+
"ip": "10.42.42.1",
10+
"customer_id": "18405023-fdd0-4d67-b641-299e3823888c",
11+
"agent_id": "[email protected]",
12+
"thread_id": "T00M0307QQ",
13+
"created_at": "2025-08-07T06:55:10.000000Z",
14+
"expires_at": "2025-08-14T06:55:10.000000Z"
15+
}
16+
]
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{}

src/pages/management/changelog/index.mdx

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,12 @@ Use [**Update an account**](/authorization/global-accounts-api#tag/Accounts/path
3232

3333
- The `X-Author-Id` mechanism for bot authorization is no longer supported. The only way to authorize bots is by using bot authorization tokens.
3434

35+
### Customer bans
36+
37+
- The customer bans management methods have been added:
38+
- [**List customer bans**](/management/configuration-api/v3.6/#list-customer-bans)
39+
- [**Unban customer**](/management/configuration-api/v3.6/#unban-customer)
40+
3541
### Groups
3642

3743
- The "At least one Agent must have the `normal` priority" requirement was removed from the [**Create Group**](/management/configuration-api/v3.6/#create-group) method's `agent_priorities` parameter.

src/pages/management/configuration-api/v3.6/index.mdx

Lines changed: 107 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ All configurations set by this API will have action in system after max 2 minute
3737
| **Agents** | [`create_agent`](#create-agent) [`get_agent`](#get-agent) [`list_agents`](#list-agents) [`update_agent`](#update-agent) [`delete_agent`](#delete-agent) [`suspend_agent`](#suspend-agent) [`unsuspend_agent`](#unsuspend-agent) [`request_agent_unsuspension`](#request-agent-unsuspension) [`approve_agent`](#approve-agent) |
3838
| **Auto access** | [`add_auto_access`](#add-auto-access) [`list_auto_access`](#list-auto-access) [`delete_auto_access`](#delete-auto-access) [`update_auto_access`](#update-auto-access) |
3939
| **Bots** | [`create_bot_template`](#create-bot-template) [`create_bot`](#create-bot) [`delete_bot_template`](#delete-bot-template) [`delete_bot`](#delete-bot) [`update_bot_template`](#update-bot-template) [`update_bot`](#update-bot) [`list_bot_templates`](#list-bot-templates) [`get_bot`](#get-bot) [`list_bots`](#list-bots) [`issue_bot_token`](#issue-bot-token) [`reset_bot_template_secret`](#reset-bot-template-secret) [`reset_bot_secret`](#reset-bot-secret) |
40+
| **Customer bans** | [`list_customer_bans`](#list-customer-bans) [`unban_customer`](#unban-customer) |
4041
| **Groups** | [`create_group`](#create-group) [`get_group`](#get-group) [`list_groups`](#list-groups) [`update_group`](#update-group) [`delete_group`](#delete-group) |
4142
| **Properties** | [`register_properties`](#register-properties) [`unregister_properties`](#unregister-properties) [`publish_properties`](#publish-properties) [`list_properties`](#list-properties) [`update_license_properties`](#update-license-properties) [`delete_license_properties`](#delete-license-properties) [`list_license_properties`](#list-license-properties) [`update_group_properties`](#update-group-properties) [`delete_group_properties`](#delete-group-properties) [`list_groups_properties`](#list-groups-properties) |
4243
| **Tags** | [`create_tag`](#create-tag) [`delete_tag`](#delete-tag) [`list_tags`](#list-tags) [`update_tag`](#update-tag) |
@@ -1854,6 +1855,112 @@ curl -X POST \
18541855

18551856
</Section>
18561857

1858+
# Customer bans
1859+
1860+
Customers can be banned for a specific period of time. During the ban, they can’t connect to or interact with the [Customer Chat API](/messaging/customer-chat-api). Banning is only possible via the [Agent Chat API](/messaging/agent-chat-api).
1861+
1862+
## Methods
1863+
1864+
| HTTP method | The Groups API endpoint |
1865+
| ----------- | ---------------------------------------------------------------- |
1866+
| `POST` | `https://api.livechatinc.com/v3.6/configuration/action/<action>` |
1867+
1868+
| Required header | Value |
1869+
| --------------- | ------------------ |
1870+
| `Content-Type` | `application/json` |
1871+
1872+
<Section>
1873+
1874+
<Text>
1875+
1876+
### List Customer Bans
1877+
1878+
Returns all active bans for a customer.
1879+
1880+
#### Specifics
1881+
1882+
| | |
1883+
| -------------------------------- | -------------------------------------------------------------------- |
1884+
| Method URL | `https://api.livechatinc.com/v3.6/configuration/action/list_customer_bans` |
1885+
| Required scopes | `banlist_read` |
1886+
| [Batch support](#batch-requests) | No |
1887+
1888+
#### Request
1889+
1890+
Empty request payload.
1891+
1892+
</Text>
1893+
1894+
<Code>
1895+
1896+
<CodeSample path={'REQUEST'}>
1897+
1898+
```shell
1899+
curl -X POST \
1900+
https://api.livechatinc.com/v3.6/configuration/action/list_customer_bans \
1901+
-H 'Authorization: Bearer <your_access_token>' \
1902+
-H 'Content-Type: application/json' \
1903+
-d '{}'
1904+
```
1905+
1906+
</CodeSample>
1907+
1908+
<CodeResponse type="configuration" version="v3.6" json="listCustomerBans"/>
1909+
1910+
</Code>
1911+
1912+
</Section>
1913+
1914+
<Section>
1915+
1916+
<Text>
1917+
1918+
### Unban Customer
1919+
1920+
Lifts a ban from a customer.
1921+
1922+
#### Specifics
1923+
1924+
| | |
1925+
| -------------------------------- | -------------------------------------------------------------------- |
1926+
| Method URL | `https://api.livechatinc.com/v3.6/configuration/action/unban_customer` |
1927+
| Required scopes | `banlist_write` |
1928+
| [Batch support](#batch-requests) | No |
1929+
1930+
#### Request
1931+
1932+
| Parameter | Data type | Required | Notes |
1933+
| ---------------------------------- | --------- | -------- | ---------------------------------------------------------------------------- |
1934+
| `ip` | `string` | Yes* | Group name (up to 180 chars) |
1935+
| `customer_id` | `string` | Yes* | The code of the group languange |
1936+
1937+
**1)** Exactly one of `ip` and `customer_id` is required.
1938+
1939+
</Text>
1940+
1941+
<Code>
1942+
1943+
<CodeSample path={'REQUEST'}>
1944+
1945+
```shell
1946+
curl -X POST \
1947+
https://api.livechatinc.com/v3.6/configuration/action/unban_customer \
1948+
-H 'Authorization: Bearer <your_access_token>' \
1949+
-H 'Content-Type: application/json' \
1950+
-d '{
1951+
"ip": "192.168.1.1"
1952+
}'
1953+
```
1954+
1955+
</CodeSample>
1956+
1957+
<CodeResponse type="configuration" version="v3.6" json="unbanCustomer"/>
1958+
1959+
</Code>
1960+
1961+
</Section>
1962+
1963+
18571964
# Groups
18581965

18591966
Groups let you organize your work by creating teams with Agent and Bot members. You can use groups to do configuration based on shared settings (language, working hours, department) and to separate chat routing. It's worth mentioning that one Agent can belong to multiple groups at the same time. It's possible to configure routing priorities for Agents and Bots specifically per group.

0 commit comments

Comments
 (0)