> ## Documentation Index
> Fetch the complete documentation index at: https://docs.subconscious.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# API

> The standard Subconscious inference endpoint

The Subconscious Cloud API is the fastest way to access our inference infrastructure. All requests go through `api.subconscious.dev`, our managed gateway that handles authentication, rate limiting, and routing.

## How It Works

<CardGroup cols={3}>
  <Card title="OpenAI & Anthropic compatible" icon="plug">
    Use the standard OpenAI or Anthropic SDK with no custom libraries needed
  </Card>

  <Card title="Global edge" icon="globe">
    Low-latency access from anywhere
  </Card>

  <Card title="Managed infrastructure" icon="server">
    We handle scaling, reliability, and uptime
  </Card>
</CardGroup>

## API Keys

API keys are created and managed from your [Subconscious dashboard](https://subconscious.dev/platform/api-keys).

<CodeGroup>
  ```python Python (OpenAI) theme={null}
  from openai import OpenAI

  client = OpenAI(
      api_key="your-api-key",               # From your dashboard
      base_url="https://api.subconscious.dev/v1",
  )
  ```

  ```python Python (Anthropic) theme={null}
  from anthropic import Anthropic

  client = Anthropic(
      auth_token="your-api-key",            # From your dashboard
      base_url="https://api.subconscious.dev",
  )
  ```
</CodeGroup>

## Billing

Usage is billed per token. See [Pricing](https://www.subconscious.dev/pricing) for current rates.

* Credits are added from your dashboard
* Usage is deducted automatically per request
* Auto-pay is available for uninterrupted service
* Usage dashboards show real-time consumption
