Skip to main content
Glama

AIsa Web Search & Research

Sonar — lightweight search + answer

post_perplexity_sonar
Read-onlyIdempotent

Ask a question and get a written answer with web citations, rather than a list of links to read yourself. Body is OpenAI chat-completions shaped: model (required, sonar) and messages. Returns choices[0].message.content as prose, plus citations (an array of URL strings) and search_results[] with title, url, snippet, date and source, and a usage block. Measured at about 3 seconds. Billed at a flat $0.012 per request. This is the cheapest and fastest of the four Perplexity endpoints — use it for a single factual question. Step up to post_perplexity_sonar_pro for multi-part questions, or post_perplexity_sonar_reasoning_pro when the answer requires working through steps. If you need results you can iterate over rather than prose, use post_tavily_search; post_exa_answer answers the same shape of question with semantic retrieval, at $0.08.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
modelYesThe Sonar model to use.
top_kNoThe number of tokens to keep for top-k filtering.
top_pNoNucleus sampling parameter. The model considers tokens with top_p probability mass.
streamNoWhether to stream the response using server-sent events.
messagesYesA list of messages comprising the conversation so far.
max_tokensNoThe maximum number of tokens to generate in the response.
temperatureNoSampling temperature between 0 and 2. Lower values make output more focused and deterministic.
search_contextNoControls how much search context to use. Affects per-request cost.low
presence_penaltyNoPenalizes new tokens based on whether they appear in the text so far. Positive values increase the likelihood of talking about new topics.
return_citationsNoWhether to return citations and search results in the response.
frequency_penaltyNoPenalizes new tokens based on their existing frequency in the text so far. Positive values decrease the likelihood of repeating the same line verbatim.
search_domain_filterNoLimit search to specific domains.
search_recency_filterNoFilter search results by recency.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.8/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The annotations already cover readOnly/openWorld/idempotent/non-destructive, and the description adds substantial behavioral context: response shape ('choices[0].message.content', 'citations', 'search_results[]', 'usage'), latency ('Measured at about 3 seconds'), and flat pricing ('$0.012 per request'). No contradiction with annotations exists.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is dense but logically organized, front-loading purpose, payload, output, and then adding cost, latency, and sibling routing. Minor redundancy keeps it from a perfect score: 'cheapest and fastest' restates the preceding timing and billing details.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Despite 13 parameters, rich annotations, an output schema, and a large sibling family, the description covers all operational essentials: exact payload requirement, return contract, cost, latency, and when to choose each relevant sibling. The schema handles remaining parameter details.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so baseline is 3. The description adds a critical clarification: 'model (required, `sonar`)', narrowing the schema's wide enum to the intended value for this specific endpoint. It also explains the body shape and return structure. Minor tension: the schema's model enum includes sonar-pro, sonar-reasoning-pro, and sonar-deep-research, while the description routes those to sibling tools, which could confuse a literal reading.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific verb-resource combination: 'Ask a question and get a written answer with web citations,' and distinguishes it from link-list tools with 'rather than a list of links to read yourself.' It clearly identifies the Perplexity Sonar endpoint, matching the tool name and title.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It explicitly states when to use the tool: 'use it for a single factual question,' and names alternatives with explicit conditions: 'Step up to post_perplexity_sonar_pro for multi-part questions, or ... reasoning_pro when the answer requires working through steps. If you need results you can iterate over ... use post_tavily_search; post_exa_answer answers the same shape...' This is exemplary routing guidance.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources