| **login** \[_mxid_] | Get instructions on how to log in. Admins can use the _mxid_ parameter to log in as another user. |
| **register**<_phone_><_fullname_> | Register to Telegram. |
| **logout** | Log out from Telegram. |
| **login-matrix** | Replace your Telegram account's Matrix puppet with your own Matrix account. |
| **ping-matrix** | Pings the server with the stored matrix authentication. |
| **ping** | Check if you're logged into Telegram. |
| **ping-bot** | Get info of the message relay Telegram bot. |
| **username**<_newusername_> | Change your Telegram username. |
| **session**<`list`\|`terminate`> \[_hash_] | View or delete other Telegram sessions. |
## Creating portals
Commands to make connections to Telegram chats.
| Command | Usage |
|------------------------|-------|
| **bridge** \[_id_] | Bridge the current Matrix room to the Telegram chat with the given ID. The ID must be the prefixed version that you get with the `/id` command of the Telegram-side bot. |
| **create** \[_type_] | Create a Telegram chat of the given type for the current Matrix. _type_ is either `group`, `supergroup` or `channel`. Defaults to `group` |
| **pm**<_identifier_> | Open a private chat with the given Telegram user. _identifier_ is either the internal ID, the username or the phone number of the Telegram user. **N.B.** The phone numbers you start chats with must already be in your contacts. |
| **join**<_link_> | Join a chat with an invite link. _link_ is a complete t.me invite link, e.g. https://t.me/telegram |
## Portal management
Commands to manage the Telegram chats linked to portals. These can only be used in portal rooms and will directly affect the Telegram chat linked to the portal.
Most of these commands require some admin privileges in the Telegram chat: The bot will inform you if you do not have sufficient permissions.
| Command | Usage |
|--------------------------------|-------|
| **invite-link** | Get a Telegram invite link to the current chat. |
| **upgrade** | Upgrade a normal Telegram group to a supergroup. |
| **group-name**<_name_\|`-`> | Change the username of a supergroup/channel. To disable, use a dash (`-`) as the name. |
| **delete-portal** | Remove all users from the current portal room and forget the portal. Only works for group chats; to delete a private chat portal, simply leave the room. |
| **unbridge** | Remove puppets from the current portal room and forget the portal. |
### Portal configuration
Some bridge settings can be set on a per-portal basis. The `!tg config` command is used for that.