For full API documentation and to download a sample Postman collection, please visit https://api.dragonmetrics.com/.

If a request was invalid or there was a problem with the response, the server will respond with an error object describing the issue.

For example, if you make a request with a begin date of August 1st, 2021, and an end date of July 1, 2021, you'll receive the following response along with an HTTP 422 response code:

{
"error": {
"code": 10000,
"message": "SSL is required to perform this operation.",
"description": "HTTP is not supported. Please send all requests over HTTPS (e.g. https://api.dragonmetrics.com)"
}
}

Code

Message

Description

10000

SSL is required to perform this operation.

HTTP is not supported. Please send all requests over HTTPS

10100

Out of credits

Your account does not have enough API credits to make this request.

10200

Rate limit exceeded

You have made too many requests during this time period. Please wait and try your request again shortly.

10300

Authentication Missing

You must authenticate to access this resource.

10400

Authentication failed

The supplied authentication credentials were not correct.

10500

Not found

The requested resource cannot be found. Please consult the Dragon Metrics API documentation for more information.

10600

POST not allowed

The HTTP POST method is not allowed for this resource

10700

PUT not allowed

The HTTP PUT method is not allowed for this resource

10800

DELETE not allowed

The HTTP DELETE method is not allowed for this resource

10900

GET not allowed

The HTTP GET method is not allowed for this resource

11000

Missing request body

JSON input is required in the request body

11100

Request body is not valid

Request body must be valid JSON

11200

JSON format is not valid

The JSON input in the request body is not in the expected format.

11300

Unsupported Media Type

The Content-Type header must be set to application/json for POST or PUT requests

11400

Validation Failed

One or more submitted fields did not pass validation. Please see the errors object for detailed information.

11500

Unknown validation error

An unknown validation error has occurred. One or more fields in your request may be poorly formed. Please verify all fields and try again.

11600

Internal Error

The server encountered an unexpected condition which prevented it from fulfilling the request.

11700

Missing 'campaign_id' and 'campaign'

Requests must include either the 'campaign_id' and 'campaign' parameter.

11800

'campaign_id' not found

No campaign was found with the value entered for 'campaign_id'

11900

'campaign' not found

No campaign was found with the value entered for 'campaign'

12000

Campaign is paused

The requested campaign is paused. Set campaign status to 'active' to access data.

12100

Limit too high

The value specified for 'limit' is too high. Please use a number less than or equal to 500.

12200

Invalid value for 'limit'

The value for the 'limit' parameter must be an integer between 1 and 500.

12300

Invalid value for 'start'

The value for the 'start' parameter must be an integer greater than or equal to 0

12350

Invalid value for 'start'

The value for the 'start' parameter must be less than the total number of rows available for this request.

12400

Missing 'date'

Requests must include the 'date' parameter

12500

Invalid 'date' format

The value for "date" is not valid. Dates must be formatted as 'dd-mm-yyyy' (e.g. '30-01-2021').

12600

Invalid 'date' value

The value for "date" is not a valid date. Dates must be formatted as 'dd-mm-yyyy' (e.g. '30-01-2021').

12700

'date' is too recent or in the future

Please enter an earlier value for 'date'. SERP data is only available for the previous day HKT (UTC +8).

12800

'date' is too far in past

Detailed SERP ranking data is no longer available for this keyword.

12900

Missing 'search_engine'

Requests must include the 'search_engine' parameter

13000

Invalid 'search_engine' value

Invalid value for 'search_engine'","description":"The value for the 'search_engine' parameter is not valid. Please enter search engine in the format '{SEARCH ENGINE NAME}|{COUNTRY CODE}|{LANGUAGE CODE}|{DEVICE}|{LOCATION}'. For example: 'google|us|en|desktop' See https://help.dragonmetrics.com/en/articles/214242-search_engines-parameter to look up all valid 'search_engine' values.

13100

'search_engine' is not tracking in this campaign

This 'search_engine' is not tracking in the campaign

13200

Missing 'keyword'

Requests must include the 'keyword' parameter

13300

'keyword' not found in this campaign

No keyword was found in this campaign that matches the value in the 'keyword' parameter

13400

'keyword' not tracking for this 'search_engine'

This keyword is not tracking on this search engine for this campaign.

13500

No ranking data

There is no ranking data available for this keyword and search engine on this date.

13600

Invalid search engine

One or more values for 'search_engines' are not valid. Please enter an array of search engines in the format '{SEARCH ENGINE NAME}|{COUNTRY CODE}|{LANGUAGE CODE}|{DEVICE}|{LOCATION}'. For example: 'google|us|en|desktop' See https://help.dragonmetrics.com/en/articles/214242-search_engines-parameter to look up all valid 'search_engines' values.

13700

Search engine not tracking in this campaign

One or more values for 'search_engines' are not tracking in this campaign

13800

Invalid value for 'sort'

The value for the 'sort' is not valid. Please use the format '{FIELD}|{DIRECTION}', where {FIELD} is the sort field, and {DIRECTION} is either 'asc' or 'desc'. Not all fields are valid for sorting. Please see API documentation for more details.

13900

Invalid format for ‘tags’

‘tags’ must be an array of strings

14000

Invalid value for ‘tags’

One or more values in the ‘tags’ array is not found in this campaign

14100

Invalid value for 'site'

No site was found with the requested value. The ‘site’ field must match either the main tracking URL or a tracking competitor exactly as it was originally entered. You can look up the campaign site using the list campaigns endpoint and competitors using the list competitors endpoint.

14200

Invalid value for 'all_ranking_urls'

The value for 'all_ranking_urls' is not valid. Acceptable values are true or false.

14300

Missing 'begin_date'

Requests must include the 'begin_date' parameter

14400

Invalid 'begin_date' format

The value for "begin_date" is not valid. Dates must be formatted as 'dd-mm-yyyy' (e.g. '30-01-2021').

14500

Invalid 'begin_date' value

The value for "begin_date" is not a valid date. Dates must be formatted as 'dd-mm-yyyy' (e.g. '30-01-2021').

14600

'begin_date' is too recent or in the future

Please enter an earlier value for 'begin_date'. SERP data is only available for the previous day HKT (UTC +8).

14700

Missing 'end_date'

Requests must include the 'end_date' parameter

14800

Invalid 'end_date' format

The value for "end_date" is not valid. Dates must be formatted as 'dd-mm-yyyy' (e.g. '30-01-2021').

14900

Invalid 'end_date' value

The value for "end_date" is not a valid date. Dates must be formatted as 'dd-mm-yyyy' (e.g. '30-01-2021').

15000

'end_date' is too recent or in the future

Please enter an earlier value for 'end_date'. SERP data is only available for the previous day HKT (UTC +8).

15100

Begin date must be before end date

The requested date range is not valid. The begin date must be before the end date.

15200

Invalid value for 'first_and_last_only'

The value for 'first_and_last_only' is not valid. Acceptable values are true or false.

15300

Invalid value for 'sites'

One or more values in the 'sites' array was not found in this campaign. Each value in the 'sites' array must match either the main tracking URL or a tracking competitor exactly as it was originally entered. You can look up the campaign site using the list campaigns endpoint and competitors using the list competitors endpoint.

15310

Invalid value for 'sites'

'sites' must be an array of strings

15350

Maximum of 10 sites may be entered

Please enter a maximum of 10 values for the 'sites' arrray

15400

Invalid format for ‘tags_dimension’

‘tags_dimension’ must be an array of strings

15500

Invalid format for ‘tags_filter’

‘tags_filter’ must be an array of strings

15600

Invalid value for ‘tags_dimension’

One or more values in the ‘tags_dimension’ array is not found in this campaign

15700

Invalid value for ‘tags_filter’

One or more values in the ‘tags_filter’ array is not found in this campaign

15800

Cannot filter by tag set as dimension

Values in the ‘tags_dimension’ array cannot be included the ‘tags_filter’ array

15900

Invalid value for 'group_by_subdomain'

The value for 'group_by_subdomain' is not valid. Acceptable values are true or false.

16000

Validation Failed

search_engines must not be included if keyword_level_search_engine_tracking is set to true.

16100

Validation Failed

search_engines must be included if keyword_level_search_engine_tracking is set to false.

16150

Invalid site scope

site_scope must be one of the following values: 'root domain', 'exact url','subdomain / subfolder','root domain only'.

16200

‘settings’ is required

The ‘settings’ object is required

16300

Not enough keyword credits

There are not enough keyword credits to perform the requested action

16400

Maximum records exceeded

A maximum of 2,500 records may be sent in each request.

16500

‘search_engines’ must not be included

search_engines must not be included if keyword_level_search_engine_tracking is set to false for the campaign

16600

‘search_engines’ is required

search_engines must be included if keyword_level_search_engine_tracking is set to true for the campaign

16700

‘search_engines’ cannot be empty

search_engines must not be empty if keyword_level_search_engine_tracking is set to true for the campaign

16800

‘keywords’ is required

The ‘keywords’ array is required

16900

‘keyword’ is required

The field ‘keyword’ is required

17000

‘competitors’ is required

The ‘competitors’ object is required for this request

17100

Invalid value for 'competitors'

One or more values in the 'competitors' array was not found in this campaign. Each value in the 'competitors' array must match a tracking competitor exactly as it was originally entered. You can look up competitors using the list competitors endpoint.

17200

Invalid competitor URLs

One or more values in the 'competitors' array is not a valid URL.

17300

Invalid value for ‘tag’

No tag was found in this campaign matching the value of the ‘tag’ field.

Did this answer your question?