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

# Quickstart: Send Your First Request with A2Agent

> Sign up for A2Agent, create an API key, and send your first OpenAI-compatible chat completion request to GLM, Kimi, DeepSeek, Qwen, or MiniMax in under five minutes.

A2Agent gives you a single API key that unlocks every supported Chinese LLM through an OpenAI-compatible endpoint. This guide walks you from account creation to a live chat completion request in four steps — no provider-specific setup required.

<Steps>
  <Step title="Sign Up for an Account">
    Go to [https://a2agent.me/register](https://a2agent.me/register) and create a free account. A2Agent credits your new account with free trial credits automatically — no payment method needed to get started. You can use those credits to explore models and test latency before adding funds.
  </Step>

  <Step title="Create an API Key">
    After signing in at [https://a2agent.me/login](https://a2agent.me/login), open the **API Keys** page from the console navigation. Click **Create Key**, give your key an optional label, and confirm. Copy the key value immediately — it is shown in full only once. Your base URL for all requests is:

    ```text theme={null}
    https://api.a2agent.me
    ```

    You will pass this base URL to any client that requires a custom endpoint.
  </Step>

  <Step title="Make Your First Request">
    With your key in hand, run the following command in your terminal. Replace `YOUR_API_KEY` with the key you just copied.

    ```python theme={null}
    curl https://api.a2agent.me/v1/chat/completions \
      -H "Authorization: Bearer YOUR_API_KEY" \
      -H "Content-Type: application/json" \
      -d '{
        "model": "deepseek-v4-pro",
        "messages": [{"role": "user", "content": "Hello"}]
      }'
    ```

    A successful response returns a JSON object with a `choices` array containing the model's reply. You can swap `"deepseek-v4-pro"` for any model listed on the [Models](/models/overview) page without changing anything else.

    If you prefer a Python or Node.js client, the OpenAI SDK works without any modifications beyond setting the base URL and key:

    ```python theme={null}
    from openai import OpenAI

    client = OpenAI(
        api_key="YOUR_API_KEY",
        base_url="https://api.a2agent.me/v1",
    )

    response = client.chat.completions.create(
        model="deepseek-v4-pro",
        messages=[{"role": "user", "content": "Hello"}],
    )

    print(response.choices[0].message.content)
    ```

    ```javascript theme={null}
    import OpenAI from "openai";

    const client = new OpenAI({
      apiKey: "YOUR_API_KEY",
      baseURL: "https://api.a2agent.me/v1",
    });

    const response = await client.chat.completions.create({
      model: "deepseek-v4-pro",
      messages: [{ role: "user", content: "Hello" }],
    });

    console.log(response.choices[0].message.content);
    ```
  </Step>

  <Step title="Check Your Usage">
    Log in at [https://a2agent.me/login](https://a2agent.me/login) and navigate to the **Usage** section of the console to see a breakdown of requests, token counts, and spend by model. Your remaining balance is displayed at the top of the page.
  </Step>
</Steps>

<Note>
  A2Agent is fully compatible with the OpenAI Chat Completions protocol. Any SDK or tool that lets you configure a custom base URL — including the official `openai` Python and Node.js libraries — works with A2Agent out of the box. Set `base_url` (or `OPENAI_BASE_URL`) to `https://api.a2agent.me/v1` and point `api_key` at your A2Agent key.
</Note>

## Next Steps

<CardGroup cols={2}>
  <Card title="AI Coding Clients" icon="terminal" href="/clients/claude-code">
    Configure Claude Code, Cursor, Continue, and other AI coding tools to use A2Agent as their backend.
  </Card>

  <Card title="All Models" icon="microchip" href="/models/overview">
    Browse the full model list — GLM, Kimi, DeepSeek, Qwen, and MiniMax — with pricing and context-window details.
  </Card>
</CardGroup>
