{
  "openapi": "3.0.1",
  "info": {
    "title": "Google Trends Scraper (Fast, No Browser)",
    "description": "Fast Google Trends scraper: interest over time, interest by country, region, city and metro, and top and rising related queries for any keyword or comparison. Web, YouTube, News, Image and Shopping search. Same output fields as the classic Google Trends Scraper.",
    "version": "0.0",
    "x-build-id": "2mYNwVyfCCmUFhFT1"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/rakish_bobby_gwr~google-trends-fast-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-rakish_bobby_gwr-google-trends-fast-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/rakish_bobby_gwr~google-trends-fast-scraper/runs": {
      "post": {
        "operationId": "runs-sync-rakish_bobby_gwr-google-trends-fast-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/rakish_bobby_gwr~google-trends-fast-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-rakish_bobby_gwr-google-trends-fast-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": {
          "searchTerms": {
            "title": "Search terms",
            "type": "array",
            "description": "Keywords or topics to analyze. Each entry becomes one dataset item. To compare up to 5 terms on one relative scale, write them comma-separated in one entry and enable \"Compare comma-separated terms\".",
            "items": {
              "type": "string"
            }
          },
          "isMultiple": {
            "title": "Compare comma-separated terms",
            "type": "boolean",
            "description": "If enabled, an entry like \"chatgpt, gemini, claude\" is analyzed as one comparison (up to 5 terms, same 0-100 scale), exactly like adding comparisons on trends.google.com. If disabled, the comma is part of the keyword.",
            "default": false
          },
          "startUrls": {
            "title": "Google Trends URLs",
            "type": "array",
            "description": "Paste explore URLs copied from trends.google.com. The URL's own terms, location, time range, category and search type are used, so the settings below do not apply to these URLs.",
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "spreadsheetId": {
            "title": "Google Sheet ID with search terms",
            "type": "string",
            "description": "Optional. ID of a Google Sheet shared as \"Anyone with the link can view\". Terms are read from the first column; row 1 is treated as the header."
          },
          "timeRange": {
            "title": "Time range",
            "enum": [
              "",
              "now 1-H",
              "now 4-H",
              "now 1-d",
              "now 7-d",
              "today 1-m",
              "today 3-m",
              "today 12-m",
              "today 5-y",
              "all"
            ],
            "type": "string",
            "description": "Period to analyze. Defaults to the past 12 months, like trends.google.com.",
            "default": ""
          },
          "customTimeRange": {
            "title": "Custom time range",
            "pattern": "^(\\d{4}-\\d{2}-\\d{2}(T\\d{2})? \\d{4}-\\d{2}-\\d{2}(T\\d{2})?)?$",
            "type": "string",
            "description": "Overrides the time range above. Format \"YYYY-MM-DD YYYY-MM-DD\", for example \"2025-01-01 2025-06-30\". For hourly data inside the last 7 days use \"YYYY-MM-DDTHH YYYY-MM-DDTHH\"."
          },
          "geo": {
            "title": "Location",
            "type": "string",
            "description": "Country to analyze; leave empty for worldwide. You can also type a region code such as \"US-CA\" or a US metro code such as \"US-NY-501\". Worldwide returns interest by country; a country returns interest by subregion and city (plus metro areas for the US).",
            "default": ""
          },
          "category": {
            "title": "Category",
            "type": "string",
            "description": "Restrict the analysis to a category, like the category filter on trends.google.com. You can also type any numeric category ID.",
            "default": ""
          },
          "property": {
            "title": "Search type",
            "enum": [
              "",
              "images",
              "news",
              "froogle",
              "youtube"
            ],
            "type": "string",
            "description": "Which Google search to analyze: Web Search (default), Image Search, News Search, Google Shopping or YouTube Search.",
            "default": ""
          },
          "language": {
            "title": "Language",
            "type": "string",
            "description": "Language of region, city and topic names in the results, as a locale code such as \"en-US\", \"de\" or \"tr\".",
            "default": "en-US"
          },
          "includeInterestOverTime": {
            "title": "Interest over time",
            "type": "boolean",
            "description": "Timeline of search interest on a 0-100 scale (field interestOverTime_timelineData).",
            "default": true
          },
          "includeInterestByRegion": {
            "title": "Interest by region",
            "type": "boolean",
            "description": "Search interest by country, subregion, city and US metro area (fields interestBy*).",
            "default": true
          },
          "includeRelatedQueries": {
            "title": "Related queries",
            "type": "boolean",
            "description": "Top and rising related search queries (fields relatedQueries_top and relatedQueries_rising).",
            "default": true
          },
          "maxItems": {
            "title": "Maximum results",
            "minimum": 0,
            "type": "integer",
            "description": "Stop after this many search terms or URLs. 0 means no limit.",
            "default": 0
          },
          "maxConcurrency": {
            "title": "Max concurrency",
            "minimum": 1,
            "maximum": 20,
            "type": "integer",
            "description": "How many search terms are processed in parallel.",
            "default": 5
          },
          "maxRequestRetries": {
            "title": "Max retries per search term",
            "minimum": 0,
            "maximum": 10,
            "type": "integer",
            "description": "How many times a search term is retried on a fresh IP address when Google rate-limits the request.",
            "default": 5
          },
          "viewedFrom": {
            "title": "Proxy country",
            "pattern": "^([A-Za-z]{2})?$",
            "type": "string",
            "description": "Optional two-letter country code for the proxy IP address, for example \"us\". Usually not needed: the location filter above decides which data you get."
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Google Trends rate-limits datacenter IP addresses quickly. Residential proxies are the default and recommended.",
            "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}