Skip to main content
POST
Reference example

Request contract

Complete OpenAPI definition Effective request and pricing declaration (including authentication and referenced schemas):

Cost and request rules

Usage-based billing; Default request estimate: $0.1356 USD (not a fixed price). Account-specific pricing and final settlement may differ. Published reference values are not an account-specific quote or a settled charge. For endpoints supporting X-AISA-Cost-Mode: quote, obtain a free quote for your exact request before execution; reconcile the settled cost with response metadata and Usage Logs. USD amounts use 1,000,000 integer micro-USD per dollar.
  • Default request reference estimate (USD): 0.1356
  • Cost contract: response_usd
  • Published reference multiplier: 1.0
  • Settlement evidence source: response_body

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
date_from
string | null

starting date of the time range
optional field
if you don't specify this field, the API will return all SERPs collected for 365 days starting from the current datetime value;
minimal possible value: 365 days from the current datetime value;
date format: "yyyy-mm-dd"

date_to
string | null

ending date of the time range
optional field
if you don't specify this field, the today's date will be used by default;
date format: "yyyy-mm-dd";
example:
"2021-09-01"

keyword
string

keyword
required field
you can specify up to 700 characters in the keyword field;
all %## will be decoded (plus character ‘+’ will be decoded to a space character);
if you need to use the “%” character for your keyword, please specify it as “%25”;
if you need to use the “+” character for your keyword, please specify it as “%2B”

language_code
string | null

unique language identifier
required field if you don't specify language_name
Note: it is required to specify either language_name or language_code
you can receive the list of available languages with their language_code parameters by making a separate request to the
https://api.dataforseo.com/v3/dataforseo_labs/locations_and_languages
example:
en

language_name
string

full name of the language
required field if you don't specify language_code
Note: it is required to specify either language_name or language_code
you can receive the list of available languages with their language_name parameters by making a separate request to the
https://api.dataforseo.com/v3/dataforseo_labs/locations_and_languages
example:
English

location_code
integer

unique location identifier
required field if you don't specify location_name
Note: it is required to specify either location_name or location_code
you can receive the list of available locations with their location_code by making a separate request to https://api.dataforseo.com/v3/dataforseo_labs/locations_and_languages
example:
2840

location_name
string

full name of the location
required field if you don't specify location_code
Note: it is required to specify either location_name or location_code
you can receive the list of available locations with their location_name by making a separate request to https://api.dataforseo.com/v3/dataforseo_labs/locations_and_languages
example:
United Kingdom

tag
string | null

user-defined task identifier
optional field
the character limit is 255
you can use this parameter to identify the task and match it with the result
you will find the specified tag value in the data object of the response

Example:

Response

object | null

Successful operation

cost
number<double> | null

total tasks cost, USD

status_code
integer | null

general status code you can find the full list of the response codes here

status_message
string | null

general informational message you can find the full list of general informational messages here

tasks_count
integer<int64> | null

the number of tasks in the tasks array

tasks_error
integer<int64> | null

the number of tasks in the tasks array returned with an error

time
string | null

total execution time, seconds

version
string | null

the current version of the API

tasks
(object | null)[] | null

array of tasks