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

# Quickstart

> Create and embed your first TruGen AI Teammate in minutes.

This guide walks you through creating an AI Teammate via API and embedding it in your application. You'll need an API key from the [TruGen Developer Portal](https://app.trugen.ai) before you start.

<Steps>
  <Step title="Create an Agent">
    Use the Create Agent API to spin up a new AI Teammate.

    <Note>Replace `<api-key>` with your actual API key from the [Developer Portal](https://app.trugen.ai).</Note>

    <CodeGroup>
      ```bash Request theme={null}
      curl --request POST \
        --url https://api.trugen.ai/v1/agent/api \
        --header 'Content-Type: application/json' \
        --header 'x-api-key: <api-key>' \
        --data '{
          "avatar_ids": ["ava_ae61c9e28b"],
          "name": "My First Agent",
          "system_prompt": "You are a friendly and helpful assistant.",
          "email": "you@yourdomain.com",
          "config": {
            "timeout": 240
          },
          "is_active": true
        }'
      ```
    </CodeGroup>

    The response includes an `id` — save it for the next step.

    <CodeGroup>
      ```json Response theme={null}
      {
        "id": "agt_12345example",
        "name": "My First Agent"
      }
      ```
    </CodeGroup>
  </Step>

  <Step title="Embed the Agent">
    Paste the agent `id` into the iframe below and drop it into any web page.

    <CodeGroup>
      ```html HTML theme={null}
      <iframe
        src="https://app.trugen.ai/embed?agentId=<agent-id>"
        width="100%"
        height="600"
        frameborder="0"
        allow="camera; microphone; autoplay"
      ></iframe>
      ```
    </CodeGroup>

    <Note>Replace `<agent-id>` with the `id` returned in Step 1.</Note>

    Your agent is now live — open the page in a browser and start a conversation.
  </Step>
</Steps>

## What's Next?

<CardGroup cols={2}>
  <Card title="Avatars" icon="user" href="/docs/avatars/gallery">
    Browse stock avatars and find the right face for your agent.
  </Card>

  <Card title="Templates" icon="shapes" href="/docs/agents/templates">
    Use templates to define persona, tone, knowledge, and session behaviour at scale.
  </Card>

  <Card title="Knowledge Base" icon="database" href="/docs/agents/knowledge-base">
    Connect your content so agents give accurate, grounded answers.
  </Card>

  <Card title="API Reference" icon="book" href="/api-reference">
    Explore all endpoints for agents, templates, tools, and knowledge base.
  </Card>
</CardGroup>
