apiVersion: v1 kind: MessagePlatformAdapter metadata: name: qqofficial label: en_US: QQ Official API zh_Hans: QQ 官方 API zh_Hant: QQ 官方 API description: en_US: QQ Official API (Webhook / WebSocket) zh_Hans: QQ 官方 API,支持 Webhook 和 WebSocket 两种连接模式 zh_Hant: QQ 官方 API,支援 Webhook 和 WebSocket 兩種連線模式 icon: qqofficial.svg spec: categories: - china help_links: zh: https://link.langbot.app/zh/platforms/qqofficial en: https://link.langbot.app/en/platforms/qqofficial ja: https://link.langbot.app/ja/platforms/qqofficial config: - name: one-click-bind label: en_US: One-Click QR Binding zh_Hans: 一键扫码绑定 zh_Hant: 一鍵掃碼綁定 description: en_US: Scan QR code with mobile QQ to auto-fill AppID and Secret (Token still needs to be filled manually) zh_Hans: 使用手机 QQ 扫码绑定,自动填写 AppID 和密钥(Token 仍需手动填写) zh_Hant: 使用手機 QQ 掃碼綁定,自動填寫 AppID 和密鑰(Token 仍需手動填寫) type: qr-code-login login_platform: qqofficial required: false - name: appid label: en_US: App ID zh_Hans: 应用ID zh_Hant: 應用ID type: string required: true default: "" - name: secret label: en_US: Secret zh_Hans: 密钥 zh_Hant: 密鑰 type: string required: true default: "" - name: token label: en_US: Token zh_Hans: 令牌 zh_Hant: 令牌 description: en_US: Optional. The QR binding cannot return this value; the current adapter implementation does not use it either, so it can be safely left blank. zh_Hans: 可选。扫码绑定无法获取该字段,当前适配器实现也未使用该字段,留空即可。 zh_Hant: 可選。掃碼綁定無法取得此欄位,目前介面卡實作亦未使用,留空即可。 type: string required: false default: "" - name: enable-webhook label: en_US: Enable Webhook Mode zh_Hans: 启用Webhook模式 zh_Hant: 啟用 Webhook 模式 description: en_US: If enabled, the bot will use webhook mode to receive messages. Otherwise, it will use WebSocket mode zh_Hans: 如果启用,机器人将使用 Webhook 模式接收消息。否则,将使用 WebSocket 模式 zh_Hant: 如果啟用,機器人將使用 Webhook 模式接收訊息。否則,將使用 WebSocket 模式 type: boolean required: true default: false - name: enable-stream-reply label: en_US: Enable Stream Reply Mode zh_Hans: 启用流式回复模式 zh_Hant: 啟用串流回覆模式 description: en_US: If enabled, the bot will use streaming mode to reply messages (C2C only) zh_Hans: 如果启用,机器人将使用流式方式回复消息(仅私聊) zh_Hant: 如果啟用,機器人將使用串流方式回覆訊息(僅私聊) type: boolean required: true default: false - name: webhook_url label: en_US: Webhook Callback URL zh_Hans: Webhook 回调地址 zh_Hant: Webhook 回調地址 description: en_US: Copy this URL and paste it into your QQ Official API webhook configuration zh_Hans: 复制此地址并粘贴到 QQ 官方 API 的 Webhook 配置中 zh_Hant: 複製此地址並貼到 QQ 官方 API 的 Webhook 設定中 type: webhook-url required: false default: "" show_if: field: enable-webhook operator: eq value: true execution: python: path: ./qqofficial.py attr: QQOfficialAdapter