1
0
mirror of https://github.com/Bayselonarrend/OpenIntegrations.git synced 2025-12-01 22:29:52 +02:00
Files
OpenIntegrations/docs/en/md/Slack/Channel-management/Set-channel-topic.mdx
Vitaly the Alpaca (bot) cdef2d02ab Main build (Jenkins)
2025-10-21 21:43:05 +03:00

105 lines
2.5 KiB
Plaintext
Vendored

---
sidebar_position: 11
description: Set channel topic and other functions to work with Slack in the Open Integration Package, a free open-source integration library for 1C:Enterprise 8, OneScript and CLI
keywords: [1C, 1С, 1С:Enterprise, 1С:Enterprise 8.3, API, Integration, Services, Exchange, OneScript, CLI, Slack]
---
import Tabs from '@theme/Tabs';
import TabItem from '@theme/TabItem';
# Set channel topic
Sets the channel topic
`Function SetChannelTopic(Val Token, Val Channel, Val Topic) Export`
| Parameter | CLI option | Type | Required | Description |
|-|-|-|-|-|
| Token | --token | String | ✔ | Bot token |
| Channel | --channel | String | ✔ | Channel ID |
| Topic | --theme | String | ✔ | Channel topic |
Returns: Map Of KeyAndValue - serialized JSON response from Slack
<br/>
```bsl title="1C:Enterprise/OneScript code example"
Token = "xoxb-6965308400114-696804637...";
Channel = "C09MRB3P6N6";
Topic = "TestTopic";
Result = OPI_Slack.SetChannelTopic(Token, Channel, Topic);
```
<Tabs>
<TabItem value="bash" label="Bash" default>
```bash
oint slack SetChannelTopic \
--token "***" \
--channel "C09LEMNRUD9" \
--theme "TestTopic"
```
</TabItem>
<TabItem value="bat" label="CMD/Bat" default>
```batch
oint slack SetChannelTopic ^
--token "***" ^
--channel "C09LEMNRUD9" ^
--theme "TestTopic"
```
</TabItem>
</Tabs>
```json title="Result"
{
"ok": true,
"channel": {
"id": "C09LEMNRUD9",
"created": 1760521294,
"creator": "U06UG1CAYH2",
"is_org_shared": false,
"is_im": false,
"context_team_id": "T06UD92BS3C",
"updated": 1760521297864,
"name": "testconvf0560358-c9cc-406f-b690-d00904ee0015",
"name_normalized": "testconvf0560358-c9cc-406f-b690-d00904ee0015",
"is_channel": true,
"is_group": false,
"is_mpim": false,
"is_private": false,
"is_archived": false,
"is_general": false,
"is_shared": false,
"is_ext_shared": false,
"unlinked": 0,
"is_pending_ext_shared": false,
"pending_shared": [],
"parent_conversation": null,
"purpose": {
"value": "",
"creator": "",
"last_set": 0
},
"topic": {
"value": "TestTopic",
"creator": "U06UG1CAYH2",
"last_set": 1760521297
},
"shared_team_ids": [
"T06UD92BS3C"
],
"pending_connected_team_ids": [],
"is_member": false,
"previous_names": []
}
}
```