# Bot Commands

HTTP API commands are being sent to the bot by calling a special HTTP URL:

<https://api.mysmartbots.com/api/bot.html>

The request can be either **GET** or **POST**. Read the [Doing HTTP API Calls](/doc/c3b7db06-2d0c-4caa-a9c3-6d402c6190d8) page for more info.

# Testing

You can compose and test your queries using SmartBots API Testing Suite:  
<https://www.mysmartbots.com/api/testing.html>

# Available bot HTTP commands

| Command | Description |
|---------|-------------|
| **Status** |             |
| [status](/doc/e46902b7-2834-4d89-a130-4483dc227100) | Returns the online status of the bot. |
| [login](/doc/0733c8d1-c74a-44c7-b620-a1763adb6bba) | Initiates bot login sequence. |
| [logout](/doc/5fa386d2-3b31-45db-be18-1d6a348b74c5) | Initiates bot logout sequence. |
| [set_http_callback](/doc/402de21d-d431-45b8-91bd-9068ae34ba0c) | Specifies your HTTP callback script to receive bot events (invitations, IMs etc). |
| **Messaging** |             |
| [im](/doc/a71a1198-a109-4264-ba82-598a3cd68a0c) | Sends an Instant Message to a specific user. |
| [reply_dialog](/doc/467e522b-d328-44fc-b50f-a3b0578d53a0) | Virtually "presses" a pop-up dialog button (which was displayed by an in-world script). |
| [say_chat_channel](/doc/d0268d9d-8fb8-4fc3-bc22-cbf91fd8fec2) | Says message over a specific chat channel. |
| [typing_start](/doc/38b16fbc-dd0b-4365-a08c-617f356c325d) | Sends "typing" in chat to a specific user. |
| [typing_stop](/doc/bf3d0bad-def4-422b-8195-c891a45d3c63) | Stops sending "typing" in chat to a specific user. |
| **Friendship** |             |
| [cancel_friendship](/doc/dbaa3ec8-77eb-4cbc-9733-a336b9cebdf4) | Removes an avatar from the bots friend list. |
| [edit_friendship](/doc/734f0a6b-85c0-4b82-b965-0ab42f480b86) | Enables/Disables friend abilities such as Online Status, Show On Map, or Edit Rights |
| [friends](/doc/1bd41e11-4ad1-423f-a3ba-81b890b8d0a3) | Lists the bot’s friends. |
| [friendship_offer_accept](/doc/eafc7dac-15c7-433d-bca6-a7c891dd8ed1) | Accept (or reject) a friendship offer sent by other avatar. |
| [offer_friendship](/doc/e3420957-274c-4a74-93d3-aced80a0d975) | Offers friendship to a resident. |
| **Inventory** |             |
| [inventory_delete](/doc/7e95f0cd-0757-4d17-8143-5212b0fb3b5d) | Deletes an item from the bot's inventory. |
| [inventory_give](/doc/435299d9-ecd8-447b-8d51-65f7d50f35c6) | Commands bot to send an inventory item or folder to specific avatar. |
| [inventory_list](/doc/3994c314-5979-4a22-9e7e-ac051b5783a8) | Returns a list ofthe bot's inventory folder contents. |
| [inventory_offer_accept](/doc/58aebece-bc8b-43b8-8c47-599d7a091366) | Accept (or reject) an inventory invitation sent by other avatar or in-world script. |
| [inventory_to_prim](/doc/e1a46c69-8ce0-4bf3-aa9b-9627ab1c8bfc) | Put an item from inventory to in-world prim |
| [notecard_create](/doc/60be94ae-e307-4322-b596-94007a1e2ad9) | Create a notecard in the bot's inventory. |
| [`notecard_edit`](https://n) | Edit a notecard in the bot's inventory. |
| [notecard_read](/doc/16d96c2b-ceb9-418a-85e9-98f19b4fd9b2) | Edit a notecard in the bot's inventory. |
| [texture_upload](/doc/f56f8bcf-afc0-40ba-baef-898ad3cea5a0) | Uploads and creates a new texture in inventory |
| **Appearance** |             |
| [rebake](/doc/826aaab5-2139-442b-8864-9c1b214fc4d5) | Commands bot to rebake its appearance (reload its clothing and skin textures). |
| [takeoff](/doc/49c5e35c-281b-4e40-913d-44d2a6bb21c7) | Removes a clothing item, body part or attachment (the opposite of the wear command). |
| [wear](/doc/c2d514d5-ad4e-43e8-9225-058297074e1e) | Commands bot to wear a clothing item, body part or attach an object. |
| **Group control** |             |
| [group_activate](/doc/2f026762-ca11-4669-827b-1f5dc84065d4) | Activates a specific group (for example, to get build rights on the parcel). |
| [`group_role_activate`](/doc/activate_role-lEvBkA2wJ8) | Changes the active group tag/title to the corresponding role UUID. |
| [group_info_2](/doc/0cdf0c71-439a-4a30-b04c-18a8ca2608bf) | Returns the information about Second Life group, along with roles and titles. |
| [group_join](/doc/69f2ee74-336e-4750-a827-f13a0f386357) | Tries to join a group by UUID. |
| [group_leave](/doc/f54a7c78-f7af-41db-a2e3-46d4f7ea96f8) | Commands bot to leave the group specified by a UUID. |
| [`group_list_2`](/doc/group_list2-UH2HnoZbxe) | Returns the bot's groups list as JSON, along with roles and titles. |
| [`group_list_roles`](/doc/list_group_roles-i8kFKeI1rf) | Returns a list the roles in given group. |
| [group_offer_accept](/doc/418259b8-c928-478f-84af-045a02118fa8) | Accept (or reject) a group invitation sent by other avatar. |
| [group_visibility](/doc/51cfd1bf-5b7a-4a99-9bcd-2d786cd9523a) | Controls the group visibility in bot profile. |
| *Older commands:* |             |
| [group_info](/doc/b7d8d004-1e16-4d54-8281-5ec43f1f97e4) | Returns the information about Second Life group.<br>*(Usage of* @[*group_info_2*](mention://681348aa-9776-43aa-a46d-ae1e1b3f5cad/document/686d61ff-676b-4836-9747-c38fa63aafc8) *is recommended)* |
| [listgroups](/doc/fb5fa76c-0a89-48a8-a54d-05c6da350ff4) | Returns a list of the Second Life groups the bot is member of (plain LSL-friendly version) |
| [listgroups_extended](/doc/abd4b582-1aa1-4093-a2ac-29ddb3de4dda) | Returns the bot's groups list, with additional details.<br>*(Usage of* `*group_list_2*` *isrecommended)* |
| *activate_group* | Older name and alias for `group_activate` |
| *activate_role* | Older name and alias for `group_role_activate` |
| list_group_roles | Older name and alias for [`group_list_roles`](/doc/list_group_roles-i8kFKeI1rf) |
| **Group members and communications** |             |
| [group_invite](/doc/0a83d8a0-a785-48f0-bb84-96572b4fc1dc) | Sends a group invitation to a specific resident. |
| [group_eject](/doc/2f81c539-153a-4954-bf69-25e46f4dcc0d) | Ejects residents from the group. |
| [`group_member_setrole`](/doc/setrole-MzTqnfg5FF) | Puts member of a group in a specific role.<br>*(older name and alias:* `*setrole*`*)* |
| [send_notice](/doc/6562e0cb-5c2e-4fec-baca-3275b94fa140) | Sends a notice to the group. |
| [send_group_im](/doc/f2b03fdf-c263-4aae-9627-ec748067b80d) | Sends a message to group chat. |
| **Money** |             |
| [get_balance](/doc/a1628fb5-5cea-4d5e-b7af-45ea8ba3cc90) | Returns avatar L$ balance. |
| [give_money](/doc/428c9d5f-e20d-477a-b472-353f1185398f) | Commands bot to send money (L$) to specific avatar. |
| [give_money_object](/doc/7b553b12-c86b-4956-8507-e844e6df0a37) | Commands bot to send money (L$) to a specific object. |
| **Avatar info** |             |
| [avatar_info](/doc/1c66471c-96e5-4227-b38e-989d9e5b5074) | Returns the specific avatar's info. |
| [avatar_groups](/doc/8a79b7d7-5212-42fe-a950-05e69fa09d33) | Returns a list of a resident's groups. |
| [avatar_picks](/doc/9cab3d11-7875-43d6-9774-6b4148597411) | Returns a list of a resident's picks. |
| [key2name](/doc/76a3ba45-7cf1-48a8-8707-dfed5d8f9047) | Returns avatar Second Life name by UUID. |
| [name2key](/doc/88619a93-265a-4959-b98f-ffd4af0eeb36) | Returns avatar UUID by Second Life name. |
| [offer_teleport](/doc/e8f24120-5a55-472a-8ecb-5f05bb6f3cd6) | Sends a teleport offer to the resident. |
| `get_managers` | HTTP API/Bot Commands/get managers |
| **Movement** |             |
| [move](/doc/64913e82-9abb-4486-9b3b-ae72417d99a1) | Start or stop bot movement and rotations. |
| [walkto](/doc/4834d951-1efa-4e6b-8179-6524e01b8d0e) | Walk to a position within the current region. |
| [fly](/doc/ee61637f-0bb5-41c4-a384-1ad965b9b424) | Commands the bot to fly. |
| [sit](/doc/e35ff974-1aac-4025-8746-b723735be48c) | Commands bot to sit on a specific prim. |
| [teleport](/doc/586092da-aad8-4cdd-9bec-21fbb157923d) | Teleports bot to specific location. |
| [teleport_offer_accept](/doc/8e48e9b4-f6b4-470a-b3e2-799ac9c02f51) | Accept (or reject) a teleport offer sent by other avatar. |
| **World interaction** |             |
| [attachments](/doc/373ec568-c3d8-4f9c-985a-caba32d84a4f) | Returns a list of the bot's attachments (including HUD objects). |
| [bot_location](/doc/c14dcb6a-0378-4028-bdb7-d99fd5749e0e) | Returns the current location of the bot. |
| [inworld_prim_take](/doc/2ddb6e16-a004-4bdf-8225-f1a5f009db31) | Takes or copies in-world prim into bot's inventory. |
| [find_objects](/doc/c0c3eb6b-4182-4d05-8c85-5c350b88689c) | Returns the list of objects rezzed in the region. |
| [nearbyavatars_scan](/doc/91636875-4c5f-4c4f-b532-a8b3e58a8641) | Scans current region for other avatars. |
| [touch_attachment](/doc/948f1cea-c224-4fe3-b75e-3ae1fed08f40) | Touches an object attached to the bot (HUD or attachment). |
| [touch_prim](/doc/a5931ee1-12d5-4f5f-8e03-3d933c945f0f) | Touches a prim in-world. |
| [touch_prim_coord](/doc/aa541bfc-3e7b-4cf2-b698-9da256f7eb75) | Touches a prim in-world by using its coordinates. |
| **Region (sim) control** |             |
| [sim_access](/doc/9e85afb0-9738-4180-b03a-a1c2db59a391) | Control access to the sim. |
| [sim_managers](/doc/cff8733a-38d4-41ec-98cc-034d3a3a34fe) | Control managers of the sim. |
| [sim_info_current](/doc/0cb0c4c7-f41b-4713-ae21-22d8459b3602) | Gets the settings and access info of the current sim (the region the bot is currently in). |
| [sim_kick](/doc/b0a47d83-2245-4106-aa7f-90dd0feeb632) | Kicks resident (without banning from the sim) |
| [sim_restart](/doc/d059711c-a0fe-4027-b3ba-4761a1734e19) | Begins the sim restart routine. Also used to cancel the restart routine previously started. |
| [sim_return](/doc/f09c398d-b44d-4edd-9578-451961546ecc) | Returns objects of the specific resident from the sim. |
| [sim_send_message](/doc/99157029-c3c0-4df2-8c41-31fee302afcc) | Sends a message to all visitors of the sim. |
| [region_info](/doc/496c334c-1c35-4bf2-adcb-a6732ecca4bf) | Gets the region info of a sim. |
| **Parcel control** |             |
| [parcel_buy](/doc/bdf8c005-9431-464b-b503-ed7d0858fe39) | Purchases the parcel at specific point of the region |
| [parcel_eject](/doc/2001941f-c94d-4dc7-8bc2-2d14ee8bb24d) | Ejects avatar from bot's current parcel |
| [parcel_info](/doc/6e3d1d7c-a262-4cbc-8bbd-b3c4ed76cbfe) | Returns a lot of information about a parcel. |
| [parcel_info_update](/doc/95b243a3-c5b0-419b-964a-ffc65fa83cf4) | Update parcel details, including the name, description and selling options |
| [parcel_list](/doc/6ca0b589-d5bd-4241-b385-42465fc52b9c) | Retrieves all parcels of the current sim |


---

# Restrictions

API frequency restrictions may be applied for numerous subsequent queries (especially messaging ones: [im](/doc/a71a1198-a109-4264-ba82-598a3cd68a0c), [send_group_im](/doc/f2b03fdf-c263-4aae-9627-ec748067b80d) etc). We suggest maintaining about 3 seconds delay between the subsequent queries since SL also caps delivery at this rate.


:::info
SmartBots API query returns the following error message when you hit the frequency restriction:  
**Frequent API requests throttled**

:::

---

**Documents**

- [Appearance](https://www.mysmartbots.com/docs/s/dev/doc/appearance-CLXnf3TmVa)
- [Friendship](https://www.mysmartbots.com/docs/s/dev/doc/friendship-FdksyobjB0)
- [Group management](https://www.mysmartbots.com/docs/s/dev/doc/group-management-QEHhVgfjpu)
- [Group membership](https://www.mysmartbots.com/docs/s/dev/doc/group-membership-HtkjpmSJzt)
- [Status](https://www.mysmartbots.com/docs/s/dev/doc/status-9GoZXpdBPC)
- [World interaction](https://www.mysmartbots.com/docs/s/dev/doc/world-interaction-8WFJaETEu4)
- [Inventory](https://www.mysmartbots.com/docs/s/dev/doc/inventory-cukw98ksCF)
- [Avatar](https://www.mysmartbots.com/docs/s/dev/doc/avatar-EgZrWkRRNp)
- [Avatar info](https://www.mysmartbots.com/docs/s/dev/doc/avatar-info-Jr62tpOuqk)
- [Land management](https://www.mysmartbots.com/docs/s/dev/doc/land-management-hLJLY1NdF2)
- [Sim management](https://www.mysmartbots.com/docs/s/dev/doc/sim-management-VxEiyjNH3D)
- [Scripting](https://www.mysmartbots.com/docs/s/dev/doc/scripting-Hb8kbyNy1s)
- [Messaging](https://www.mysmartbots.com/docs/s/dev/doc/messaging-wh98SNBoWM)
- [Movement](https://www.mysmartbots.com/docs/s/dev/doc/movement-9UePIxIwWv)