Skip to content
This repository was archived by the owner on Jun 2, 2019. It is now read-only.
This repository was archived by the owner on Jun 2, 2019. It is now read-only.

how to get new_chat_member when a user joined to telegram group in telegram bot? #458

@ali9776

Description

@ali9776

I'm trying to send a message to user, who joined to a group, with my telegram bot. I add bot to the group and bot is admin in group. and I set the Group Privacy off. I get user with new_chat_member when user joined to group, but the message send to user infinitely. And the update which is for when a member join to group is pending. how I should answer the incoming update when a user join to telegram group?

if(isset($arrayMessage['message'])) {
if (isset($arrayMessage['message']['new_chat_member'])) {
$text= "hello";
$url= "https://api.telegram.org/bot".$token."/sendMessage?chat_id=".$chat_id."&text=".$text;
file_get_contents($url);
}
}
I'm using laravel .

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions