messages.updateDialogFilter

Update folder

Example

const {Api, TelegramClient} = require('telegram');
const {StringSession} = require('telegram/sessions');

const session = new StringSession('');
const client = new TelegramClient(session, apiId, apiHash, {});

(async function run() {
    const result = await client.invoke(new Api.messages.updateDialogFilter({
        id: 5100686,
        filter: new Api.DialogFilter({...}),
        }));
    console.log(result); // prints the result
})();

TL schema

boolFalse#bc799737 = Bool;
boolTrue#997275b5 = Bool;
---functions---
messages.updateDialogFilter#1ad4a04a flags:# id:int filter:flags.0?DialogFilter = Bool;

Parameters

Name

Type

Description

flags

id

filter

Folder info

Result

Bool

Possible errors

Code

Type

Description

400

FILTER_ID_INVALID

The specified filter ID is invalid

Can bots use this methd ?

yes

Telegram allows placing chats into folders, based on their type, mute status, or other custom criteria, thanks to folder blacklists and whitelists.

Last updated