FNLB Devs

Developer Portal

API

Bot Commands

Commands are how you change cosmetics, run emotes, and trigger bot behavior over HTTP. They use the same names as in-game bot commands, without a category prefix.

Run a command

POST /bots/{botId}/commands/run accepts:

FieldRequiredDescription
commandyesCommand name, 1–255 characters.
argsnoOne string or an array of up to 25 strings.
localenoReply language. See the route schema for allowed values.

OAuth2 tokens need the commands.run scope. API tokens and sessions are accepted when the route lists them.

curl -X POST "https://api.fnlb.net/v1/bots/BOT_ID/commands/run" \
  -H "Authorization: Bearer FNLB_YOUR_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"command":"outfit","args":"Renegade Raider","locale":"en"}'

Response

A successful call returns HTTP 200 with a reply object, not the updated party:

{
  "nonce": "…",
  "botName": "Alpha",
  "content": "Set outfit to Renegade Raider.",
  "format": 1
}
formatMeaning
0Neutral
1Success
2Info
3Warning
4Error

The bot can answer with format: 4 while HTTP stays 200. Treat content and format as the command outcome. Read party state from the gateway if you need cosmetics on members.

Chat messages

POST /bots/{botId}/chat/messages sends text the bot delivers in party chat. It also requires commands.run. The body has content and optional locale. The same reply shape as command run is returned. Use commands for bot actions. Use chat when you need a custom message string.

Rate limit

This route allows about 250 requests per 10 minutes per IP with an API token, and 1000 with an OAuth2 access token. See Rate limits.