Get the pages that rank for one query

The tool lists the site's pages that showed for one query, per engine, over the window. It uses the same page-and-query join as get_page_queries, with the sides flipped, and the same coverage limits. More than one row means several of the site's pages compete for the query. detect_keyword_cannibalization classifies that across the whole site.

get_query_pages

The tool lists the site's pages that showed for one query, per engine, over the window.

It uses the same page-and-query join as get_page_queries, with the sides flipped, and the same coverage limits. More than one row means several of the site's pages compete for the query. detect_keyword_cannibalization classifies that across the whole site.

Parameters

ParameterTypeRequiredNotes
sitestringYesThe site to look up, as a bare domain ("example.com") or a URL. The tool strips the scheme, www, path, and trailing slash. The site must belong to a workspace you own. Call list_sites first if you are not sure of the exact domain.
querystringYesThe search query to look up; matched case-insensitively.
windowDaysintegerNoLength of the current window, in days. Defaults to 28.
tostringNoLast day of the current window (YYYY-MM-DD). Defaults to the most recent date either engine has data for.
minImpressionsintegerNoMinimum window impressions for a page to be returned. Defaults to 1.
limitintegerNoMaximum rows to return, sorted by relevance. Defaults to 50.
searchVertical"web" | "image" | "video"NoWhich Google search type to read: web (the default), image, or video. Bing Webmaster Tools does not split search types on any traffic report, so image and video return Google only. The response records that Bing was left out, in unsupportedInputs. A missing Bing number then means Bing was not measured. Defaults to "web".
Full input JSON SchemaTypes, defaults and validation rules
json
{  "$schema": "https://json-schema.org/draft/2020-12/schema",  "type": "object",  "properties": {    "site": {      "type": "string",      "minLength": 1,      "description": "The site to look up, as a bare domain (\"example.com\") or a URL. The tool strips the scheme, www, path, and trailing slash. The site must belong to a workspace you own. Call list_sites first if you are not sure of the exact domain."    },    "query": {      "type": "string",      "minLength": 1,      "description": "The search query to look up; matched case-insensitively."    },    "windowDays": {      "default": 28,      "description": "Length of the current window, in days.",      "type": "integer",      "exclusiveMinimum": 0,      "maximum": 365    },    "to": {      "description": "Last day of the current window (YYYY-MM-DD). Defaults to the most recent date either engine has data for.",      "type": "string"    },    "minImpressions": {      "default": 1,      "description": "Minimum window impressions for a page to be returned.",      "type": "integer",      "minimum": 0,      "maximum": 9007199254740991    },    "limit": {      "default": 50,      "description": "Maximum rows to return, sorted by relevance.",      "type": "integer",      "exclusiveMinimum": 0,      "maximum": 500    },    "searchVertical": {      "default": "web",      "description": "Which Google search type to read: web (the default), image, or video. Bing Webmaster Tools does not split search types on any traffic report, so image and video return Google only. The response records that Bing was left out, in unsupportedInputs. A missing Bing number then means Bing was not measured.",      "type": "string",      "enum": [        "web",        "image",        "video"      ]    }  },  "required": [    "site",    "query"  ]}

Response

Full output JSON SchemaEvery field the response can contain
json
{  "$schema": "https://json-schema.org/draft/2020-12/schema",  "type": "object",  "properties": {    "site": {      "type": "string"    },    "workspaceId": {      "type": "string",      "format": "uuid",      "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"    },    "searchVertical": {      "type": "string",      "enum": [        "web",        "image",        "video"      ]    },    "query": {      "type": "string"    },    "currentWindow": {      "type": "object",      "properties": {        "start": {          "type": "string"        },        "end": {          "type": "string"        }      },      "required": [        "start",        "end"      ],      "additionalProperties": false    },    "rows": {      "type": "array",      "items": {        "type": "object",        "properties": {          "label": {            "type": "string"          },          "google": {            "anyOf": [              {                "type": "object",                "properties": {                  "clicks": {                    "type": "integer",                    "minimum": -9007199254740991,                    "maximum": 9007199254740991                  },                  "impressions": {                    "type": "integer",                    "minimum": -9007199254740991,                    "maximum": 9007199254740991                  },                  "position": {                    "anyOf": [                      {                        "type": "number"                      },                      {                        "type": "null"                      }                    ]                  },                  "measuredDays": {                    "type": "integer",                    "minimum": -9007199254740991,                    "maximum": 9007199254740991                  }                },                "required": [                  "clicks",                  "impressions",                  "position",                  "measuredDays"                ],                "additionalProperties": {}              },              {                "type": "null"              }            ]          },          "bing": {            "anyOf": [              {                "type": "object",                "properties": {                  "clicks": {                    "type": "integer",                    "minimum": -9007199254740991,                    "maximum": 9007199254740991                  },                  "impressions": {                    "type": "integer",                    "minimum": -9007199254740991,                    "maximum": 9007199254740991                  },                  "position": {                    "anyOf": [                      {                        "type": "number"                      },                      {                        "type": "null"                      }                    ]                  },                  "measuredDays": {                    "type": "integer",                    "minimum": -9007199254740991,                    "maximum": 9007199254740991                  }                },                "required": [                  "clicks",                  "impressions",                  "position",                  "measuredDays"                ],                "additionalProperties": {}              },              {                "type": "null"              }            ]          },          "totalClicks": {            "type": "integer",            "minimum": -9007199254740991,            "maximum": 9007199254740991          },          "totalImpressions": {            "type": "integer",            "minimum": -9007199254740991,            "maximum": 9007199254740991          }        },        "required": [          "label",          "google",          "bing",          "totalClicks",          "totalImpressions"        ],        "additionalProperties": {}      }    },    "unsupportedInputs": {      "type": "array",      "items": {        "type": "object",        "properties": {          "field": {            "type": "string"          },          "engine": {            "anyOf": [              {                "type": "string"              },              {                "type": "null"              }            ]          },          "reason": {            "type": "string"          }        },        "required": [          "field",          "reason"        ],        "additionalProperties": {}      }    },    "lastSyncedAt": {      "anyOf": [        {          "type": "string"        },        {          "type": "null"        }      ]    }  },  "required": [    "site",    "workspaceId",    "searchVertical",    "query",    "currentWindow",    "rows",    "unsupportedInputs"  ],  "additionalProperties": false}

On This Page