Skip to content

createNewSupergroupChat

Function · TDLib 1.8.67 · d1085f9c

Creates a new supergroup or channel and sends a corresponding messageSupergroupChatCreate. Returns the newly created chat

createNewSupergroupChat(
  title: string,
  is_forum: Bool,
  is_channel: Bool,
  description: string,
  location: ChatLocation,
  message_auto_delete_time: int32,
  for_import: Bool
) → Chat

title

string

Title of the new chat; 1-128 characters

is_forum

Bool

Pass true to create a forum supergroup chat

is_channel

Bool

Pass true to create a channel chat; ignored if a forum is created

description

string

Chat description; 0-255 characters

location

ChatLocation

Chat location if a location-based supergroup is being created; pass null to create an ordinary supergroup chat

message_auto_delete_time

int32

Message auto-delete time value, in seconds; must be from 0 up to 365 * 86400 and be divisible by 86400. If 0, then messages aren't deleted automatically

for_import

Bool

Pass true to create a supergroup for importing messages using importMessages