Multi-step research agent that autonomously searches, reads, and reasons across multiple sources.
The Agent endpoint launches an autonomous research loop. It plans search queries, executes them, reads results, and iterates until it has enough information to produce a comprehensive answer.
How the autonomous research loop works:
Each step is visible in the response via the steps_completed field. More steps mean deeper research but also more time and resources.
| Name | Type | Description |
|---|---|---|
qrequired | string | The research question or task. 1-1000 characters. Be specific for best results — the agent works better with focused questions. |
steps | integer | Maximum number of research steps. 1-20, default: `5`. More steps = deeper research. Each step may involve 1-3 searches and 1-2 scrapes. |
The Agent costs 15 credits per request regardless of step count. This is a flat rate that covers:
The flat rate means you can increase the steps parameter for deeper research without worrying about variable credit costs. Credits are deducted upfront — if the agent fails after deduction, credits are refunded.
Successful agent response:
Agent using each SDK:
This endpoint can return the following errors:
| Name | Type | Description |
|---|---|---|
INVALID_QUERY | 400 | Missing or empty `q` field, query exceeds 1000 characters, or `steps` is outside the 1-20 range. |
INSUFFICIENT_CREDITS | 402 | Not enough credits. Agent costs 15 credits per request. |
USER_RATE_LIMITED | 429 | You've exceeded your plan's per-minute rate limit. |
ENGINE_ERROR | 502 | One or more underlying search/scrape operations failed. The agent will attempt to continue with remaining sources. Credits are refunded only if the entire request fails. |