🌑

帮帮技术站

tg群组个人邀请个人-邀请链接问题

  1. setwebhook接口查验是否设置成功
    1
    2
    3
    4
    5
    https://api.telegram.org/botp{my_bot_token}/getMe
    https://api.telegram.org/bot{my_bot_token}/getWebhookInfo

    my_bot_token = 111:23233

  2. 消息CHAT_MEMBER设置为接收
    @Bean
    @Singleton
    fun defaultBotOptions( env: Environment): DefaultBotOptions {
        val defaultBotOptions=if (env.activeNames.contains("prod")) DefaultBotOptions() else DefaultBotOptions().apply {
            this.proxyHost="127.0.0.1"
            this.proxyPort=33210
            this.proxyType= DefaultBotOptions.ProxyType.HTTP
        }
        //允许消息更新
        val allowedUpdates=listOf(AllowedUpdatesType.CHAT_MEMBER.code
            ,AllowedUpdatesType.MESSAGE.code
            , AllowedUpdatesType.EDITED_MESSAGE.code
            ,AllowedUpdatesType.CALLBACK_QUERY.code
        )
        defaultBotOptions.allowedUpdates=allowedUpdates
        return defaultBotOptions
    }

— Sep 3, 2023

Search