1
0
mirror of https://github.com/Bayselonarrend/OpenIntegrations.git synced 2025-04-21 12:17:20 +02:00

207 lines
4.6 KiB
Plaintext
Raw Normal View History

2024-10-15 10:50:56 +03:00
---
2024-10-15 10:16:04 +03:00
sidebar_position: 1
---
2024-10-15 10:50:56 +03:00
import Tabs from '@theme/Tabs';
import TabItem from '@theme/TabItem';
2024-10-15 10:16:04 +03:00
# Get channel list
Gets a list of available channels
`Function GetChannelList(Val Token, Val ExcludeArchived = False, Val Cursor = "") Export`
2024-10-15 15:15:47 +03:00
| Parameter | CLI option | Type | Required | Description |
|-|-|-|-|-|
| Token | --token | String | ✔ | Bot token |
| ExcludeArchived | --notarchived | Boolean | ✖ | Indicator of excluding archived channels |
| Cursor | --cursor | String | ✖ | Pointer from the previous request, if the result rows > 100 |
2024-10-15 10:16:04 +03:00
Returns: Map Of KeyAndValue - serialized JSON response from Slack
<br/>
2024-10-15 21:15:56 +03:00
```bsl title="1C:Enterprise/OneScript code example"
2024-10-15 10:16:04 +03:00
Token = "xoxb-6965308400114-696804637...";
Result = OPI_Slack.GetChannelList(Token);
```
2024-10-20 22:36:03 +03:00
<Tabs>
<TabItem value="bash" label="Bash" default>
```bash
oint slack GetChannelList \
2024-10-22 08:59:24 +03:00
--token "***"
2024-10-20 22:36:03 +03:00
```
</TabItem>
<TabItem value="bat" label="CMD/Bat" default>
```batch
oint slack GetChannelList ^
2024-10-22 08:59:24 +03:00
--token "***"
2024-10-20 22:36:03 +03:00
```
</TabItem>
</Tabs>
2024-10-15 10:16:04 +03:00
```json title="Result"
{
"ok": true,
"channels": [
{
"id": "C06UD92DF1Q",
"name": "general",
"is_channel": true,
"is_group": false,
"is_im": false,
"is_mpim": false,
"is_private": false,
"created": 1713202497,
"is_archived": false,
"is_general": true,
"unlinked": 0,
"name_normalized": "general",
"is_shared": false,
"is_org_shared": false,
"is_pending_ext_shared": false,
"pending_shared": [],
"context_team_id": "T06UD92BS3C",
"updated": 1724394518358,
"parent_conversation": null,
"creator": "U06UABH3APP",
"is_ext_shared": false,
"shared_team_ids": [
"T06UD92BS3C"
],
"pending_connected_team_ids": [],
"is_member": false,
"topic": {
"value": "",
"creator": "",
"last_set": 0
},
"purpose": {
"value": "This is the one channel that will always include everyone. It’s a great spot for announcements and team-wide conversations.",
"creator": "U06UABH3APP",
"last_set": 1713202497
},
"properties": {
"use_case": "welcome"
},
"previous_names": [],
"num_members": 1
},
{
"id": "C06UFNUTKUL",
"name": "slack-api-librarry",
"is_channel": true,
"is_group": false,
"is_im": false,
"is_mpim": false,
"is_private": false,
"created": 1713202541,
"is_archived": false,
"is_general": false,
"unlinked": 0,
"name_normalized": "slack-api-librarry",
"is_shared": false,
"is_org_shared": false,
"is_pending_ext_shared": false,
"pending_shared": [],
"context_team_id": "T06UD92BS3C",
"updated": 1724394515808,
"parent_conversation": null,
"creator": "U06UABH3APP",
"is_ext_shared": false,
"shared_team_ids": [
"T06UD92BS3C"
],
"pending_connected_team_ids": [],
"is_member": true,
"topic": {
"value": "",
"creator": "",
"last_set": 0
},
"purpose": {
"value": "This channel is for everything #slack-api-librarry. Hold meetings, share docs, and make decisions together with your team.",
"creator": "U06UABH3APP",
"last_set": 1713202541
},
"properties": {
"tabs": [
{
"id": "files",
"label": "",
"type": "files"
}
],
"use_case": "project"
},
"previous_names": [],
"num_members": 2
},
{
"id": "C06UW6XHU5V",
"name": "testconvd9226ab3-0341-4abb-97c4-a185b7ace9e8",
"is_channel": true,
"is_group": false,
"is_im": false,
"is_mpim": false,
"is_private": false,
"created": 1713701752,
"is_archived": true,
"is_general": false,
"unlinked": 0,
"name_normalized": "testconvd9226ab3-0341-4abb-97c4-a185b7ace9e8",
"is_shared": false,
"is_org_shared": false,
"is_pending_ext_shared": false,
"pending_shared": [],
"context_team_id": "T06UD92BS3C",
"updated": 1724394515915,
"parent_conversation": null,
"creator": "U06UG1CAYH2",
"is_ext_shared": false,
"shared_team_ids": [
"T06UD92BS3C"
],
"pending_connected_team_ids": [],
"is_member": false,
"topic": {
"value": "",
"creator": "",
"last_set": 0
},
"purpose": {
"value": "",
"creator": "",
"last_set": 0
},
"previous_names": [],
"num_members": 0
},
{
"id": "C06UWD6523Z",
"name": "testconvdfd146d0-f8c0-4e9f-9df8-56cc13c7e1dc",
"is_channel": true,
"is_group": false,
"is_im": false,
"is_mpim": false,
"is_private": false,
"created": 1713712534,
"is_archived": true,
"is_general": false,
"unlinked": 0,
"name_normalized": "testconvdfd146d0-f8c0-4e9f-9df8-56cc13c7e1dc",
"is_shared": false,
...
```