# SwitchInlineQueryChosenChat

> This object represents an inline button that switches the current user to inline mode in a chosen chat, with an optional default inline query

**Category:** Telegram Bot API — Types (A-Z)  
**URL:** https://docs.botlify.cloud/switchinlinequerychosenchat  
**Platform:** Botlify Cloud (https://botlify.cloud)  

---

This object represents an inline button that switches the current user to inline mode in a chosen chat, with an optional default inline query.

## Fields

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| query | String | Optional | The default inline query to be inserted in the input field. If left empty, only the bot's username will be inserted. |
| allow_user_chats | Boolean | Optional | True, if private chats with users can be chosen |
| allow_bot_chats | Boolean | Optional | True, if private chats with bots can be chosen |
| allow_group_chats | Boolean | Optional | True, if group and supergroup chats can be chosen |
| allow_channel_chats | Boolean | Optional | True, if channel chats can be chosen |

> [!TIP]
> **Botlify Cloud Runtime**
> Credentials are auto-injected in .env — always load them with getenv(): BOT_TOKEN, ADMIN_CHAT_ID, BOT_USERNAME. Main database: database.db (SQLite, WAL mode). Runtime errors: error.log. Quick test: send to $ADMIN_CHAT_ID. Full details: Runtime Reference.
