Skip to main content

Overview

Destined Voice API uses Bearer token authentication. Include your API key in the Authorization header of every request.

Getting Your API Key

  1. Sign up at destined.ai
  2. Navigate to Settings > API Keys
  3. Click Create API Key
  4. Copy and store your key securely
Keep your API key secret. Never commit it to version control or expose it in client-side code.

Using the API Key

With the SDK

import { SDK } from "@destined-ai/voice";

const client = new SDK({
  bearerToken: process.env.DESTINED_API_KEY,
});

With cURL

curl -X GET "https://api.destined.ai/v1/speakers" \
  -H "Authorization: Bearer YOUR_API_KEY"

With fetch

const response = await fetch("https://api.destined.ai/v1/speakers", {
  headers: {
    "Authorization": `Bearer ${process.env.DESTINED_API_KEY}`,
    "Content-Type": "application/json",
  },
});

Public Endpoints

Some endpoints don’t require authentication:
EndpointDescription
GET /healthAPI health check
GET /v1/speakersList available speakers

Error Responses

Authentication errors return a 401 Unauthorized response:
{
  "detail": "Invalid or expired API key"
}
Common authentication issues:
ErrorCauseSolution
401 UnauthorizedMissing or invalid API keyCheck your API key is correct
403 ForbiddenInsufficient permissionsContact support
429 Too Many RequestsRate limit exceededWait and retry