将电报机器人添加到组
Add Telegram bot to group
我正在与我的机器人进行一对一通信,现在他应该 post 一个提示用户 select 聊天的按钮。这适用于:
InlineKeyboardButton selectGroup = new InlineKeyboardButton("Add to Group");
selectGroup.SwitchInlineQuery = "test";
selectGroup.CallbackData = null;
selectGroup.Url = null;
var keyboard = new InlineKeyboardMarkup(new[]
{
new[] // first row
{
selectGroup
},
});
现在应该将机器人添加到 selected 聊天中。我怎样才能做到这一点?
只需使用 deep-linking 功能:
将带有 link 的 url 按钮发送到 https://telegram.me/botuser?startgroup=foo
我正在与我的机器人进行一对一通信,现在他应该 post 一个提示用户 select 聊天的按钮。这适用于:
InlineKeyboardButton selectGroup = new InlineKeyboardButton("Add to Group");
selectGroup.SwitchInlineQuery = "test";
selectGroup.CallbackData = null;
selectGroup.Url = null;
var keyboard = new InlineKeyboardMarkup(new[]
{
new[] // first row
{
selectGroup
},
});
现在应该将机器人添加到 selected 聊天中。我怎样才能做到这一点?
只需使用 deep-linking 功能:
将带有 link 的 url 按钮发送到 https://telegram.me/botuser?startgroup=foo