Browse docs

API Reference

Tap to expand
APIUpdated 2026-05-25

Authentication

Authenticate RetainDB API requests with server-side API keys.

Applies to: RetainDB API v1

Use a RetainDB API key from your server-side code.

http
Authorization: Bearer rdb_...

Alternative header:

http
X-API-Key: rdb_...

Environment

bash
RETAINDB_API_KEY="rdb_..."
RETAINDB_PROJECT="production"

Security

  • Never expose keys in the browser.
  • Use separate keys for development and production.
  • Rotate keys if they are pasted into logs, chat, or public tickets.
  • Attach your own authenticated user_id, session_id, agent_id, and task_id.

Next: Memory API.

Was this page helpful?

Your feedback helps us prioritize docs improvements weekly.