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

> ## Agent Instructions
> - Base URLs: models `https://api.aisa.one/v1` (Gemini GenerateContent: `https://api.aisa.one/v1beta`); data APIs `https://api.aisa.one/apis/v1`. The `servers` of each operation in https://aisa.one/openapi.yaml is authoritative.
> - Auth: `Authorization: Bearer $AISA_API_KEY`. Never print, log, or commit the key.
> - MCP (preferred for agents): `https://mcp.aisa.one/mcp`, signed in with OAuth, so there is no key to paste.
> - Agent Skill: `npx skills add AIsa-team/agent-skills --skill aisa`. Fallback with the AIsa CLI: `aisa skills install aisa`.
> - Spending: docs, https://aisa.one/models, https://aisa.one/api, `/v1/models`, and MCP `search`, `list_categories`, `get_details`, `batch_quote`, and the `account` operation are free. Quote the exact calls before running them (MCP `batch_quote`, CLI `aisa quote --json`). If the quote reports `auto_execute_eligible: true`, run it unless the user set a tighter limit or asked only for a quote. Otherwise, tell the user in one message the planned calls, the quoted price, and a total USD budget for the task, then wait for approval. Direct HTTP calls follow the stricter rule at https://aisa.one/docs/get-started/cli.md#direct-http-fallback. Do not make paid calls to test availability. Full rule: https://aisa.one/llms.txt

# Perplexity Search

> Citation-backed web answers and deep research reports for autonomous agents. Four tiers of Perplexity Sonar — fast answers, synthesis, multi-step reasoning, and exhaustive deep research — all through one AIsa API key.

[View on GitHub →](https://github.com/AIsa-team/agent-skills/tree/main/search-research/perplexity-search)

**Citation-backed web answers and deep research for autonomous agents.** Access the full Perplexity Sonar family with one `AISA_API_KEY` — from sub-second lookups to exhaustive research reports.

## Install

```bash npx skills theme={null}
npx skills add AIsa-team/agent-skills --skill perplexity-search
```

```bash AIsa CLI theme={null}
npm install -g @aisa-one/cli
aisa skills install perplexity-search
```

Start a new agent session after installing so the skill loads.

## What can agents do with it?

> [card] Fast factual answers
>
> "What shipped in OpenAI's latest release?" — answered in seconds with citations.

> [card] Comparative analysis
>
> "Compare the top three AI coding agents in 2026 across pricing and features."

> [card] Multi-step reasoning
>
> "Walk through the tradeoffs of using x402 vs. traditional API keys."

> [card] Deep research reports
>
> "Generate a 2,000-word structured report on agentic browser frameworks."

> [card] Real-time news
>
> "Summarize this week's AI infrastructure announcements."

> [card] Decision support
>
> "Should we adopt this library? Cite adoption, issues, and alternatives."

## Model tiers

| Model | Use when you need… |
| - | - |
| `sonar` | Fast, cited answers to simple questions (sub-second) |
| `sonar-pro` | Synthesis, comparisons, longer answers with more sources |
| `sonar-reasoning-pro` | Multi-step analytical reasoning, tradeoff analysis, technical deep-dives |
| `sonar-deep-research` | Exhaustive long-form reports; accepts multi-minute processing |

## Quick start

```bash theme={null}
export AISA_API_KEY="your-key"
```

### Sonar (fast answers)

```bash theme={null}
curl -X POST "https://api.aisa.one/apis/v1/perplexity/sonar" \
  -H "Authorization: Bearer $AISA_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "sonar",
    "messages": [{"role": "user", "content": "What is the Model Context Protocol?"}]
  }'
```

### Sonar Pro (synthesis)

```bash theme={null}
curl -X POST "https://api.aisa.one/apis/v1/perplexity/sonar-pro" \
  -H "Authorization: Bearer $AISA_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "sonar-pro",
    "messages": [{"role": "user", "content": "Compare the performance of top AI coding agents in 2026."}]
  }'
```

### Sonar Reasoning Pro (analysis)

```bash theme={null}
curl -X POST "https://api.aisa.one/apis/v1/perplexity/sonar-reasoning-pro" \
  -H "Authorization: Bearer $AISA_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "sonar-reasoning-pro",
    "messages": [{"role": "user", "content": "Analyze the tradeoffs of adopting x402 vs. traditional billing."}]
  }'
```

### Sonar Deep Research

```bash theme={null}
curl -X POST "https://api.aisa.one/apis/v1/perplexity/sonar-deep-research" \
  -H "Authorization: Bearer $AISA_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "sonar-deep-research",
    "messages": [{"role": "user", "content": "Create a 2,000-word deep research report on autonomous browser agents."}]
  }'
```

> [!TIP]
>
> Deep research accepts longer processing times and the Python client implements automatic retry logic. For time-sensitive requests, downgrade to `sonar-pro` or `sonar-reasoning-pro` rather than waiting for a long timeout.

## Python client

```bash theme={null}
# Fast
python3 scripts/perplexity_search_client.py sonar --query "What is MCP?"

# Synthesis
python3 scripts/perplexity_search_client.py sonar-pro --query "Compare AI coding agents 2026"

# Analytical reasoning
python3 scripts/perplexity_search_client.py sonar-reasoning-pro --query "x402 tradeoffs"

# Deep research (accepts long processing)
python3 scripts/perplexity_search_client.py sonar-deep-research --query "Agentic payments landscape"

# Optional system message to control output formatting
python3 scripts/perplexity_search_client.py sonar-pro \
  --query "Explain RAG" \
  --system "Answer in bullet points with citations inline as [1], [2]..."
```

## Endpoint reference

| Endpoint | Method | Purpose |
| - | - | - |
| `/perplexity/sonar` | POST | [Sonar — fast answers](https://aisa.one/docs/api-reference/perplexity/post_perplexity-sonar.md) |
| `/perplexity/sonar-pro` | POST | [Sonar Pro — synthesis](https://aisa.one/docs/api-reference/perplexity/post_perplexity-sonar-pro.md) |
| `/perplexity/sonar-reasoning-pro` | POST | [Sonar Reasoning Pro](https://aisa.one/docs/api-reference/perplexity/post_perplexity-sonar-reasoning-pro.md) |
| `/perplexity/sonar-deep-research` | POST | [Sonar Deep Research](https://aisa.one/docs/api-reference/perplexity/post_perplexity-sonar-deep-research.md) |

## Get started

1. Sign up at [aisa.one](https://aisa.one) and create an API key in the console.
2. Set it in your shell: `export AISA_API_KEY="your-key"`.
3. Install the skill with one of the commands under [Install](#install), then start a new agent session.

## Related

> [card] [Perplexity API reference](https://aisa.one/docs/api-reference/perplexity/post_perplexity-sonar.md)
>
> All four Sonar endpoints with interactive playgrounds.

> [card] [Pricing](https://aisa.one/docs/guides/pricing.md#models)
>
> Per-token rates for each Sonar variant.

> [card] [Error Codes](https://aisa.one/docs/api-reference/errors.md)
>
> Handling timeouts and upstream errors.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.