Skip to main content
  1. Create an API key in the app.
  2. List the available bots.
  3. Send one chat request.
  4. Check your credits.

1. Create an API key

In the app, go to Settings -> API Access and create a key for the workspace you want to bill. Keys are only shown once. Save the value when it appears.

2. List bots

curl https://behaviq.io/v1/bots
Pick the id of the bot you want to use.

3. Send a chat request

curl https://behaviq.io/v1/bots/YOUR_BOT_ID/chat \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "message": "Write a short de-escalation script for a tense customer interaction."
  }'
The response includes sessionId, responseId, and text.

4. Keep the conversation going

Reuse the same sessionId in later requests if you want context carried forward.
curl https://behaviq.io/v1/bots/YOUR_BOT_ID/chat \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "sessionId": "YOUR_SESSION_ID",
    "message": "Make that a little calmer."
  }'

5. Check credits

curl https://behaviq.io/v1/credits \
  -H "Authorization: Bearer YOUR_API_KEY"
For the full schema, use the API reference.