Getting started
HTTP API
Control your own bots with one simple request: send an action, your API key and the bot's secret to a single URL. Works from any language — including LSL scripts inside Second Life.
The endpoint
POST https://api.lifebots.cloud/api/bot.htmlYour first request
Check that a bot is online:
curl -X POST "https://api.lifebots.cloud/api/bot.html" \
-H "Content-Type: application/json" \
-d '{
"action": "status",
"apikey": "YOUR_API_KEY",
"botname": "Joe Resident",
"secret": "bot-secret-123",
"dataType": "json"
}'Response
{
"result": "OK",
"status": "ONLINE",
"online": "1",
"slname": "Joe Resident",
"uuid": "a2e76fcd-9360-4f6d-a924-000000000000",
"location": "Sandbox Island/128.42/127.9/25.03"
}Which API should I use?
| HTTP API (this page) | OAuth API | |
|---|---|---|
| Built for | Your own bots | Apps used by many LifeBots users |
| Sign-in | Your API key + the bot's secret | Each user approves your app |
| Works from LSL | Yes | Not practical |
| Style | One URL, action= | REST + JSON |
Building for other people's bots? See the OAuth API.
What you can do
Bot & webhooks | Log the bot in and out, check it is online, and register webhooks for its events. (5) |
Chat & messages | IMs, local chat, typing indicators, script dialogs and teleport offers. (6) |
Movement | Teleport, walk, steer, fly and sit. Coordinates are region-local metres. (18) |
Avatars & friends | Look up names and profiles, manage friends, and track avatars. (12) |
Groups | Any group the bot is in — invite, eject, roles, chat and notices. The bot needs the matching group powers. (17) |
Inventory | Browse, give, organise and create items, notecards and scripts. (26) |
Appearance & animation | Outfits, attachments, animations, gestures and sounds. (22) |
Objects | Find, touch and take objects; see who is nearby. (6) |
Money | Balance and payments. (3) |
Parcels | Parcel details and ejecting avatars from land the bot manages. (2) |
Region & estate | Region info, and estate-manager actions: kick, ban, restart, return, broadcast. (8) |
Next steps
- Get your API key and the bot's secret
- Learn how to send parameters — one rule (send flags as
1) saves a lot of debugging - Handle responses and errors
- Browse the 125 commands