Skip to main content

Base URL

Authentication

All API requests require authentication using an API key in the Authorization header:

Response Format

All API responses are returned in JSON format unless otherwise specified.

Success Response

Error Response

HTTP Status Codes

Rate Limiting

API requests are rate-limited based on your subscription plan. Rate limit information is included in response headers:
  • X-RateLimit-Limit: Maximum requests allowed
  • X-RateLimit-Remaining: Remaining requests in current window
  • X-RateLimit-Reset: Time when the rate limit resets (Unix timestamp)

Pagination

List endpoints support pagination using query parameters:
  • page: Page number (default: 1)
  • limit: Items per page (default: 20, max: 100)
Response includes pagination metadata:

Endpoints Overview

Text-to-Speech

  • POST /tts-synthesize - Convert text to speech

Speech-to-Text

  • POST /stt - Transcribe audio to text
  • GET /stt/languages - Get supported languages

Voices

  • GET /voices - List all voices

Memory & RAG

  • POST /memory/ingest - Store a single memory (user/knowledge/hive)
  • POST /memory/ingest/batch - Batch-store up to 100 memories
  • POST /memory/documents/extract - Upload a document (PDF, DOCX, XLSX, images) for extraction + OCR + chunked ingest
  • POST /memory/search - Hybrid semantic + keyword recall
  • POST /memory/context - Assemble an LLM-ready context string for RAG
  • GET /memory/collections - List collections in the workspace
  • POST /memory/collections - Create a team/knowledge/hive collection
  • GET /memory/usage - Monthly spend breakdown and wallet balance
Memory endpoints are billed pay-as-you-go from the workspace wallet (see Memory Pricing for rates). Every billable response includes x-credit-balance, x-credit-charged, and x-billing-tx headers so you can track spend in real time. When the wallet is empty, billable endpoints return 402 INSUFFICIENT_CREDITS with a structured details.shortfall body so your client can prompt for top-up.

LLM Chat

  • POST /v1/chat/completions - OpenAI-compatible chat completions

Billing & Usage

Each workspace has its own USD wallet. All service operations (TTS, STT, LLM, Memory) deduct from the workspace wallet. Funds are added via the Dashboard. Only workspace owners can access billing endpoints.
  • GET /billing/usage-logs - Per-operation deduction history (TTS, STT, LLM, Memory)
  • GET /billing/transactions - Payment history (top-ups, subscriptions)
All billing endpoints require billing:manage permission (workspace owner only). Non-owners receive 403 Forbidden.

SDKs

We provide official SDKs for popular programming languages:

JavaScript/TypeScript

npm install 60db

Python

pip install 60db