Getting started
Sending requests
Send POST (or GET) to the one endpoint. Parameters can be JSON, form-encoded, or in the query string — use whatever is easiest from your language.
curl -X POST "https://api.lifebots.cloud/api/bot.html" \
-H "Content-Type: application/json" \
-d '{"action":"im","apikey":"YOUR_API_KEY","botname":"Joe Resident","secret":"bot-secret-123","slname":"Jane Resident","message":"Hi!","dataType":"json"}' Form bodies sent as text/plain are accepted too — that's what LSL's llHTTPRequest sends by default. Avoid GET for anything sensitive: query strings end up in logs.
Parameters on every request
| Name | Required | Description |
|---|---|---|
action | yes | The command to run, e.g. im. |
apikey | yes | Your developer API key. |
botname | yes | The bot's name. |
secret | yes | The bot's Access Code. |
dataType | no | json for a JSON response. Without it the response is URL-encoded (result=OK&…). |
custom | no | Any text; it is echoed back in the response. Handy for matching responses to requests. |
How values are read
- Flags are
1. Most on/off options only switch on with the value1. A JSONtruearrives as the text "true" and is treated as off by most commands. The parameter tables say when a command expects something else, such astrue,onoraccept. - Everything arrives as text. Numbers can be sent as numbers or strings — both work.
- Parameter names are not case-sensitive —
folderIdandfolderidare the same. - Aliases. Many parameters accept other names too (listed under each command). Use the main name in new code.
- UUIDs vs names. Avatars, groups, objects and items are Second Life UUIDs. Where a name is accepted, the parameter table says so; names are looked up first, which can take a few seconds.
- Inventory items are identified by their inventory item UUID, not the asset UUID. Get them from listinventory.
Timing
Commands run inside Second Life. Most answer within a second or two; lookups, teleports and logins can take longer. The API waits up to 60 seconds for the bot, then answers FAIL "Failed to complete command, timed out." Movement commands answer as soon as the bot starts moving.