{
  "openapi": "3.0.1",
  "info": {
    "title": "SERP Rank Tracker Scraper",
    "description": "SERP Rank Tracker Scraper SD - SERP Rank Tracker Scraper is an SEO tool that extracts where your domain ranks on Google and Bing for each keyword and country: position, ranking URL, title, rank change since the last run, top 10 competitors, AI Overview citations.",
    "version": "1.0",
    "x-build-id": "vimyBHrnovvUt3itq"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/neuro-scraper~serp-rank-tracker-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-neuro-scraper-serp-rank-tracker-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/acts/neuro-scraper~serp-rank-tracker-scraper/runs": {
      "post": {
        "operationId": "runs-sync-neuro-scraper-serp-rank-tracker-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor and returns information about the initiated run in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/runsResponseSchema"
                }
              }
            }
          }
        }
      }
    },
    "/acts/neuro-scraper~serp-rank-tracker-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-neuro-scraper-serp-rank-tracker-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "inputSchema": {
        "type": "object",
        "properties": {
          "keywords": {
            "title": "Keywords",
            "type": "array",
            "description": "Keywords to check, one per line, e.g. web scraping api. Commas stay inside a keyword. Each keyword gives one row per search engine.",
            "items": {
              "type": "string"
            }
          },
          "targetDomain": {
            "title": "Target domain",
            "type": "string",
            "description": "Your domain, e.g. apify.com (a full URL is fine; www. is ignored). Subdomains count as matches: docs.apify.com ranks for apify.com."
          },
          "competitorDomains": {
            "title": "Competitor domains (optional)",
            "type": "array",
            "description": "Other domains whose best position is reported in the same row (competitorRanks), e.g. scrapingbee.com.",
            "items": {
              "type": "string"
            }
          },
          "searchEngine": {
            "title": "Search engine",
            "enum": [
              "google",
              "bing",
              "both"
            ],
            "type": "string",
            "description": "Google pages come through Apify's GOOGLE_SERP proxy; Bing through the residential proxy in the chosen country. 'both' gives one row per engine for each keyword.",
            "default": "google"
          },
          "countryCode": {
            "title": "Country code",
            "type": "string",
            "description": "Two-letter country of the search, e.g. us, gb, de, in. Google gets it as gl=; Bing gets a residential IP in that country.",
            "default": "us"
          },
          "languageCode": {
            "title": "Language code",
            "type": "string",
            "description": "Interface / results language, e.g. en, de, fr, es (Google hl=, Bing Accept-Language).",
            "default": "en"
          },
          "googleDomain": {
            "title": "Google domain",
            "type": "string",
            "description": "Google domain to search, e.g. google.com, google.co.uk, google.de.",
            "default": "google.com"
          },
          "depth": {
            "title": "Depth (results checked per keyword)",
            "minimum": 10,
            "maximum": 100,
            "type": "integer",
            "description": "How many organic results to scan per keyword and engine. The Actor follows the engine's own next page (Google start=, Bing's Next link) until this many results, the last page, or the domain is found (see below). Google shows 7-10 results a page.",
            "default": 20
          },
          "stopWhenFound": {
            "title": "Stop when the domain is found",
            "type": "boolean",
            "description": "Stop paging a keyword once the target domain appears (cheaper). Turn off to scan the full depth and list every position of the domain (otherPositions) and of the competitors.",
            "default": true
          },
          "maxKeywords": {
            "title": "Max keywords",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "Safety cap on the number of keywords checked in one run.",
            "default": 100
          },
          "includeCompetitors": {
            "title": "Include top 10 competitors",
            "type": "boolean",
            "description": "Add the top 10 organic results (rank, domain, URL, title) to every row.",
            "default": true
          },
          "detectAIOverview": {
            "title": "Detect AI Overview (Google only)",
            "type": "boolean",
            "description": "Report whether Google showed an AI Overview, its cited sources, and whether your domain is cited. Parsed from the results page; no extra request or charge.",
            "default": true
          },
          "baselineRanks": {
            "title": "Previous rank snapshot (optional)",
            "type": "array",
            "description": "Earlier ranks to compare with, e.g. [{\"keyword\": \"web scraping api\", \"rank\": 7, \"searchEngine\": \"google\"}]. Overrides the saved history for those keywords. rank null = not ranked.",
            "default": []
          },
          "trackHistory": {
            "title": "Remember ranks between runs",
            "type": "boolean",
            "description": "Save each keyword's rank in a named key-value store and report previousRank, rankChange and movement on the next run (schedule the Actor to build a ranking history).",
            "default": true
          },
          "historyStoreName": {
            "title": "History store name",
            "type": "string",
            "description": "Named key-value store that keeps the rank history (letters, digits and dashes). Use one name per project.",
            "default": "serp-rank-tracker-history"
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Used for Bing pages and as fallback for Google link resolution. Residential is the default; when no country is set here, the Country code above is used. Google results pages always use Apify's GOOGLE_SERP proxy.",
            "default": {
              "useApifyProxy": true,
              "apifyProxyGroups": [
                "RESIDENTIAL"
              ]
            }
          }
        }
      },
      "runsResponseSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "actId": {
                "type": "string"
              },
              "userId": {
                "type": "string"
              },
              "startedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "finishedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "status": {
                "type": "string",
                "example": "READY"
              },
              "meta": {
                "type": "object",
                "properties": {
                  "origin": {
                    "type": "string",
                    "example": "API"
                  },
                  "userAgent": {
                    "type": "string"
                  }
                }
              },
              "stats": {
                "type": "object",
                "properties": {
                  "inputBodyLen": {
                    "type": "integer",
                    "example": 2000
                  },
                  "rebootCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "restartCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "resurrectCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "computeUnits": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "options": {
                "type": "object",
                "properties": {
                  "build": {
                    "type": "string",
                    "example": "latest"
                  },
                  "timeoutSecs": {
                    "type": "integer",
                    "example": 300
                  },
                  "memoryMbytes": {
                    "type": "integer",
                    "example": 1024
                  },
                  "diskMbytes": {
                    "type": "integer",
                    "example": 2048
                  }
                }
              },
              "buildId": {
                "type": "string"
              },
              "defaultKeyValueStoreId": {
                "type": "string"
              },
              "defaultDatasetId": {
                "type": "string"
              },
              "defaultRequestQueueId": {
                "type": "string"
              },
              "buildNumber": {
                "type": "string",
                "example": "1.0.0"
              },
              "containerUrl": {
                "type": "string"
              },
              "usage": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "integer",
                    "example": 1
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "usageTotalUsd": {
                "type": "number",
                "example": 0.00005
              },
              "usageUsd": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "number",
                    "example": 0.00005
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}