Ollabear Ollabear
Sign in Open dashboard

API Reference

Base URL: https://app.ollabear.com. The external/integration surface is documented here; dashboard-only endpoints are out of scope.

Authentication

CredentialHeaderWho
Personal Access TokenAuthorization: Bearer pat_…server-to-server / automations — use this for the REST API
Widget keyX-API-Key: qk_…the embedded widget (browser); origin-locked
Session cookieCookie: qchat_session=…the dashboard

Mint a PAT in Settings → API Tokens. The token value is shown once.

Scopes

ScopeGrants
conversations_read / conversations_writeread / update conversations
messages_writepost messages
webhooks_read / webhooks_writemanage webhooks

write implies read. Out-of-scope use returns 403.

Integrations API (/v1/integrations)

# List open conversations
curl -H "Authorization: Bearer pat_live_…" \
  "https://app.ollabear.com/v1/integrations/conversations?status=open&limit=50"

# Post a message
curl -X POST -H "Authorization: Bearer pat_live_…" -H "Content-Type: application/json" \
  -d '{"content":"Your order ships today."}' \
  https://app.ollabear.com/v1/integrations/conversations/{id}/messages

# Update status / tags
curl -X PATCH -H "Authorization: Bearer pat_live_…" -H "Content-Type: application/json" \
  -d '{"status":"closed"}' \
  https://app.ollabear.com/v1/integrations/conversations/{id}/status
MethodPathScope
GET/v1/integrations/conversationsconversations_read
GET/v1/integrations/conversations/{id}conversations_read
POST/v1/integrations/conversations/{id}/messagesmessages_write
PATCH/v1/integrations/conversations/{id}/statusconversations_write
PATCH/v1/integrations/conversations/{id}/tagsconversations_write
GET/v1/integrations/webhooks/eventswebhooks_read
POST/v1/integrations/webhookswebhooks_write
DELETE/v1/integrations/webhooks/{id}webhooks_write

Webhooks (outbound)

Register a webhook to receive events. The signing secret is returned once.

curl -X POST -H "Authorization: Bearer pat_live_…" -H "Content-Type: application/json" \
  -d '{"url":"https://hooks.example.com/ollabear","events":["message.created","conversation.closed"]}' \
  https://app.ollabear.com/v1/integrations/webhooks

Each delivery carries X-Webhook-Signature: <hex HMAC-SHA256(rawBody, secret)> and X-Webhook-Event. Delivery is synchronous, ≤ 60/min per webhook, SSRF-guarded. Verify the signature before trusting the payload:

import crypto from 'node:crypto';
const expected = crypto.createHmac('sha256', SECRET).update(rawBody).digest('hex');
const ok = crypto.timingSafeEqual(Buffer.from(expected), Buffer.from(req.headers['x-webhook-signature']));

Event payload (message.created):

{
  "event": "message.created",
  "project_id": "…",
  "conversation_id": "…",
  "message": { "id":"…","role":"visitor","content":"Where is my order?","created_at":"2026-06-18T10:00:00Z" }
}

Widget API (/v1/widget)

Called by the embedded widget with X-API-Key: qk_… and an allowed Origin (set at onboarding / Shopify install). POST /v1/widget/conversations starts a conversation; POST /v1/widget/conversations/{id}/messages sends a visitor message (the AI reply arrives over the websocket).

Shopify

GET /shopify/install?shop=acme.myshopify.com → OAuth. The four mandatory webhooks (app/uninstalled, customers/data_request, customers/redact, shop/redact) are verified via X-Shopify-Hmac-Sha256 = base64(HMAC-SHA256(rawBody, app secret)) and return 200 on a valid signature.

Shopify’s OAuth HMAC (hex, sorted query params) and webhook HMAC (base64, raw body) are different schemes — don’t reuse verification code across them.

Errors

StatusMeaning
400malformed request
401missing/invalid credential (or qk_ used where pat_ is required)
403authenticated but missing scope/role
404not found / not visible to your workspace
429rate-limited

Timestamps are RFC 3339 UTC; IDs are UUIDs; pagination is cursor-based (next_cursor?cursor=). The machine-readable OpenAPI 3.1 spec is the source of truth — generate clients from it.