# Perplexity LLM Responses: Models

`GET /v1/ai/perplexity/llm_responses/models`

The Perplexity model ids you can send as `model_name`.

Family: AI answers API

## Price

Unit: request

Free. This route never charges your wallet.

## Description

Lists every Perplexity model we serve, whether it's a reasoning model, and whether it can be queued with task_post. Free.

| Model | Input per 1M tokens | Output per 1M tokens | Web search per 1,000 | Reasoning |
|---|---|---|---|---|
| `sonar` | $1.0 | $1.0 | $5.0 | no |
| `sonar-pro` | $3.0 | $15.0 | $6.0 | no |
| `sonar-reasoning-pro` | $2.0 | $8.0 | $6.0 | yes |

## Authentication

HTTP Basic auth: any login, with your `dg_` API key as the password. A `Bearer` token header with the key also works.

## Request

No request body.

_None._

### Example request

```bash
curl -X GET "https://api.dataforgaio.com/v1/ai/perplexity/llm_responses/models" \
  -u "api:$DATAFORGAIO_API_KEY"
```

## Response

| Field | Type | Description |
|---|---|---|
| `version` | string | Response format version, for example `0.1.20261203`. |
| `status_code` | integer | Status of the request as a whole. 20000 when it was accepted; each task has its own `status_code`. |
| `status_message` | string | Plain-language request status. |
| `time` | string | Time the whole request took, for example `1.8410 sec.` |
| `cost` | number | Sum of every task's `cost`, in USD. |
| `tasks_count` | integer | Number of tasks in `tasks`. |
| `tasks_error` | integer | Tasks whose `status_code` is 40000 or higher. |
| `tasks` | array<object> | One entry per task you sent, in the order you sent them. |
| `tasks.id` | string | Task id (a UUID). For task_post, use it with task_get. |
| `tasks.status_code` | integer | Outcome of this task. 20000 means data came back; 20100 means queued. See the status codes table. |
| `tasks.status_message` | string | Plain-language status. For 40501 it names the field that failed. |
| `tasks.time` | string | Time this task took on our side, for example `1.8203 sec.` |
| `tasks.cost` | number | What this task was charged, in USD. 0 when it returned no data. |
| `tasks.result_count` | integer | Number of entries in `result`. |
| `tasks.path` | array<string> | The route this task ran on, split into segments, starting with `v1`. |
| `tasks.data` | object | The task you sent, echoed back. Utility routes echo their query parameters. |
| `tasks.result` | array<object>\|null | One entry per model. |
| `tasks.result.model_name` | string | Send this as `model_name`. |
| `tasks.result.reasoning` | boolean | True for reasoning models. They ignore `temperature` and `top_p`. |
| `tasks.result.web_search_supported` | boolean | Whether the model can search the web. True for every model we serve. |
| `tasks.result.task_post_supported` | boolean | Whether the model can be queued with task_post. |
| `tasks.receipt_id` | string\|null | Id of the ledger receipt for this task: what was fetched, at which level, and what was charged. Null for utility routes and failed checks. |
| `tasks.fetch_level` | string\|null | The fetch level that delivered the data: `standard`, `rendered` or `protected`. Null when the route doesn't fetch pages or nothing was fetched. one of `standard`, `rendered`, `protected` |
| `tasks.upgraded` | boolean | True when Auto-upgrade moved the request past the included level (or, for SERP, to the live path) and the charge reflects that. |
| `tasks.upgrade_reason` | string\|null | Why the request upgraded, in our level names and HTTP facts, for example `403 at standard; challenge page at rendered`. Null when it didn't upgrade. |
| `tasks.cache_hit` | boolean | True when the data came from the shared result cache instead of a new fetch. |

### Example response

```json
{
  "version": "0.1.20261203",
  "status_code": 20000,
  "status_message": "Ok.",
  "time": "0.4210 sec.",
  "cost": 0,
  "tasks_count": 1,
  "tasks_error": 0,
  "tasks": [
    {
      "id": "8cbb5b5c-8e15-5c82-9959-45f93cdad009",
      "status_code": 20000,
      "status_message": "Ok.",
      "time": "0.4210 sec.",
      "cost": 0,
      "result_count": 3,
      "path": [
        "v1",
        "ai",
        "perplexity",
        "llm_responses",
        "models"
      ],
      "data": {},
      "result": [
        {
          "model_name": "sonar",
          "reasoning": false,
          "web_search_supported": true,
          "task_post_supported": false
        },
        {
          "model_name": "sonar-pro",
          "reasoning": false,
          "web_search_supported": true,
          "task_post_supported": false
        },
        {
          "model_name": "sonar-reasoning-pro",
          "reasoning": true,
          "web_search_supported": true,
          "task_post_supported": false
        }
      ],
      "receipt_id": null,
      "fetch_level": null,
      "upgraded": false,
      "upgrade_reason": null,
      "cache_hit": false
    }
  ]
}
```

## Errors

| Code | When |
|---|---|
| 40100 | No credentials were sent (HTTP 401). |
| 40101 | The API key is missing, malformed or revoked (HTTP 401). |
| 40202 | Too many requests for this key (HTTP 429, with `Retry-After`). |

## Migrating

Replaces DataForSEO `/v3/ai_optimization/perplexity/llm_responses/models`. Same request body and response envelope; change the base URL and the key.

## Related

- [Perplexity LLM Responses: Live](https://dataforgaio.com/docs/api/ai-perplexity-llm-responses-live.md): One answer from a Perplexity model for your prompt, with the sources it cited, the searches it ran and the tokens it used.
