> For the complete documentation index, see [llms.txt](https://docs.webscrapingapi.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.webscrapingapi.com/yandex-search-api/getting-started/api-parameters.md).

# API Parameters

{% hint style="warning" %}
**IMPORTANT!** The `engine` parameter should **always be set to `yandex`**&#x66;or this API!&#x20;
{% endhint %}

In order to make it easy for everyone to interact with our Yandex API, the request customisation part takes place inside the URL, by using query parameters. We've listed the supported parameters for the Yandex API below:

<table><thead><tr><th width="184">Parameter</th><th width="101" align="center">Type</th><th>Description</th></tr></thead><tbody><tr><td><code>api_key</code><br> <mark style="color:red;background-color:red;">Required</mark> </td><td align="center"><code>string</code></td><td><a href="/pages/VopedZ5NaYVQTeO70jba#the-api-key">The API key</a> required to authorise requests.</td></tr><tr><td><code>engine</code><br> <mark style="color:red;background-color:red;">Required</mark> </td><td align="center"><code>string</code></td><td>The engine of the SERP API. Needs to be set to <mark style="color:green;"><strong><code>yandex</code></strong></mark> for requests to Yandex.com.</td></tr><tr><td><code>text</code><br> <mark style="color:red;background-color:red;">Required</mark> </td><td align="center"><code>string</code></td><td>The keywords that you are searching for (the query).</td></tr><tr><td><code>yandex_domain</code></td><td align="center"><code>string</code></td><td>The Yandex domain from where the search is performed.</td></tr><tr><td><code>device</code></td><td align="center"><code>string</code></td><td>The device used for your Yandex search. Can be set to <code>desktop</code>, <code>mobile</code> or <code>tablet</code>.</td></tr><tr><td><code>lr</code></td><td align="center"><code>string</code></td><td>The country code from where you want to perform the ID of the country or region to search. Determines the rules for ranking documents.</td></tr><tr><td><code>lang</code></td><td align="center"><code>string</code></td><td>The language to use for the search.</td></tr><tr><td><code>p</code></td><td align="center"><code>int</code></td><td><p>The page number. Count starts from <code>0</code>.</p><p>Examples:<br><code>p=1</code> (default) - first page of results<br><code>p=2</code> - second page of results<br><code>p=4</code> - fourth page of results, etc.</p></td></tr><tr><td><code>within</code></td><td align="center"><code>string</code></td><td>Time range to search. Available values are:<br><code>77</code> - Past 24 hours<br><code>1</code> - Past 2 weeks<br>[%pm] - Past month</td></tr></tbody></table>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.webscrapingapi.com/yandex-search-api/getting-started/api-parameters.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
