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

# List Agents

> Retrieve all agents for the authenticated user.

<RequestExample>
  ```bash cURL theme={null}
  curl -X GET https://api.thinnest.ai/v2/agents \
    -H "Authorization: Bearer $THINNESTAI_API_KEY"
  ```

  ```python Python theme={null}
  import requests

  url = "https://api.thinnest.ai/v2/agents"
  headers = {
      "Authorization": "Bearer " + "YOUR_THINNESTAI_API_KEY",
  }

  response = requests.get(url, headers=headers)
  print(response.json())
  ```

  ```javascript JavaScript theme={null}
  const response = await fetch("https://api.thinnest.ai/v2/agents", {
    method: "GET",
    headers: {
      "Authorization": "Bearer " + "YOUR_THINNESTAI_API_KEY",
    },
  });

  const data = await response.json();
  console.log(data);
  ```

  ```go Go theme={null}
  package main

  import (
      "fmt"
      "io"
      "net/http"
  )

  func main() {
      req, _ := http.NewRequest("GET", "https://api.thinnest.ai/v2/agents", nil)
      req.Header.Set("Authorization", "Bearer YOUR_THINNESTAI_API_KEY")

      resp, err := http.DefaultClient.Do(req)
      if err != nil { panic(err) }
      defer resp.Body.Close()
      body, _ := io.ReadAll(resp.Body)
      fmt.Println(string(body))
  }
  ```
</RequestExample>

***

## Query Parameters

<ParamField query="limit" type="integer" default="50">
  Maximum number of agents to return (1–100)
</ParamField>

<ParamField query="offset" type="integer" default="0">
  Number of agents to skip for pagination
</ParamField>

***

## Response `200`

<ResponseExample>
  ```json 200 theme={null}
  {
    "agents": [
      {
        "id": "ag_c47e7c97_b2f2",
        "name": "Sales Agent",
        "model": "gpt-4o",
        "agentType": "simple",
        "voiceEnabled": false,
        "createdAt": "2026-03-07T10:00:00Z"
      },
      {
        "id": "ag_d58f8d08_c3g3",
        "name": "Phone Support",
        "model": "claude-3-5-sonnet-20241022",
        "agentType": "simple",
        "voiceEnabled": true,
        "createdAt": "2026-03-06T08:30:00Z"
      },
      {
        "id": "ag_e69g9e19_d4h4",
        "name": "Order Workflow",
        "model": "gpt-4o",
        "agentType": "graph",
        "voiceEnabled": false,
        "createdAt": "2026-03-05T14:15:00Z"
      }
    ],
    "total": 3
  }
  ```
</ResponseExample>

### Response Fields

<ResponseField name="agents" type="array">
  List of agent summaries
</ResponseField>

<ResponseField name="agents[].id" type="string">
  Agent public ID (format: ag\_\*)
</ResponseField>

<ResponseField name="agents[].name" type="string">
  Agent display name
</ResponseField>

<ResponseField name="agents[].model" type="string">
  LLM model identifier
</ResponseField>

<ResponseField name="agents[].agentType" type="string">
  simple, graph, or workflow
</ResponseField>

<ResponseField name="agents[].voiceEnabled" type="boolean">
  Whether voice/phone is enabled
</ResponseField>

<ResponseField name="agents[].createdAt" type="string">
  ISO 8601 creation timestamp
</ResponseField>

<ResponseField name="total" type="integer">
  Total number of agents
</ResponseField>

***

## Errors

| Code  | Description                       |
| ----- | --------------------------------- |
| `401` | Missing or invalid authentication |
