1
0
mirror of https://github.com/Bayselonarrend/OpenIntegrations.git synced 2025-11-29 22:27:42 +02:00
Files
OpenIntegrations/docs/en/md/VKTeams/Chat-management/Set-chat-title.mdx
Vitaly the Alpaca (bot) 4de7fa4268 Main build (Jenkins)
2024-12-16 19:38:57 +03:00

71 lines
1.5 KiB
Plaintext
Vendored

---
sidebar_position: 12
---
import Tabs from '@theme/Tabs';
import TabItem from '@theme/TabItem';
# Set chat title
Sets new chat title
`Function SetChatTitle(Val Token, Val ChatID, Val Text) Export`
| Parameter | CLI option | Type | Required | Description |
|-|-|-|-|-|
| Token | --token | String | ✔ | Bot token |
| ChatID | --chatid | String, Number | ✔ | Chat ID |
| Text | --text | String | ✔ | Title text |
Returns: Map Of KeyAndValue - serialized JSON response from VK Teams
<br/>
:::tip
To call this method, the bot must be an administrator in the chat room.
Method at API documentation: [GET ​​/chats/setTitle](https://teams.vk.com/botapi/#/chats/get_chats_setTitle)
:::
<br/>
```bsl title="1C:Enterprise/OneScript code example"
Token = "001.3501506236.091...";
ChatID = "689203963@chat.agent";
Text = "New title";
Result = OPI_VKTeams.SetChatTitle(Token, ChatID, Text);
```
<Tabs>
<TabItem value="bash" label="Bash" default>
```bash
oint vkteams SetChatTitle \
--token "***" \
--chatid "689203963@chat.agent" \
--text "New title"
```
</TabItem>
<TabItem value="bat" label="CMD/Bat" default>
```batch
oint vkteams SetChatTitle ^
--token "***" ^
--chatid "689203963@chat.agent" ^
--text "New title"
```
</TabItem>
</Tabs>
```json title="Result"
{
"ok": true
}
```