version: 2.1.3







createChatInviteLink

Use this method to create an additional invite link for a chat. The bot must be an administrator in the chat for this to work and must have the appropriate administrator rights. The link can be revoked using the method revokeChatInviteLink. Returns the new invite link as ChatInviteLink object.

Parameters

chat_id int | string Unique identifier for the target chat or username of the target channel (in the format @channelusername) Optional
name string Invite link name; 0-32 characters Optional
expire_date int Point in time (Unix timestamp) when the link will expire Optional
member_limit int Maximum number of users that can be members of the chat simultaneously after joining the chat via this invite link; 1-99999 Optional
creates_join_request bool True, if users joining the chat via the link need to be approved by chat administrators. If True, member_limit can't be specified Optional
token String You can use this method on another bot with specify this parameter Optional
return_array Boolean Specify the result type , if pass true results will be array otherwise will be object Optional
forgot Boolean You can set to not receive request result, dont set it or pass null for turn it off Optional
answer Boolean You can set to answer to webhook, dont set it or pass null for turn it off Optional

Method errors

ErrorNamedescription
required parameters not found required parameter for this method is not founded. you can see them in log
answer mode not allowed you can use answer mode only once for each webhook update and you already did
answer mode not allowed bc multi you can't use answer mode when multi is on

Method examples

$this->createChatInviteLink(['chat_id' => int | string, 'name' => string, 'expire_date' => int, 'member_limit' => int, 'creates_join_request' => bool]);
$this->createChatInviteLink();

Method alices

Method output :

ChatInviteLink