{
  "openapi": "3.0.1",
  "info": {
    "title": "Google Trends Scraper - Trends API & Trending Now",
    "description": "Google Trends API without a browser: interest over time, interest by country, state, US metro or city, top and rising related queries, comparisons of up to 5 terms, YouTube/News/Shopping search, and Trending now searches with volume and news. Fast, no login, pay per keyword.",
    "version": "0.1",
    "x-build-id": "yUFBAyY0ozxdcI78D"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/eiv~google-trends-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-eiv-google-trends-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/eiv~google-trends-scraper/runs": {
      "post": {
        "operationId": "runs-sync-eiv-google-trends-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/eiv~google-trends-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-eiv-google-trends-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": "One search per line. A keyword (coffee), several separated by commas to compare them on one scale (coffee, tea, matcha - up to 5), a topic ID (/m/02vqfm), or a Google Trends URL copied from your browser (it keeps its own location, dates and category). Each line returns one row per location.",
            "items": {
              "type": "string"
            }
          },
          "startUrls": {
            "title": "Google Trends URLs",
            "type": "array",
            "description": "Google Trends Explore or Trending now URLs, in the URL-list shape other Actors output, so a previous Actor's results can be fed straight in. Same as pasting the URLs into Search terms.",
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "spreadsheetId": {
            "title": "Google Sheet with search terms",
            "type": "string",
            "description": "Optional. The ID or link of a public Google Sheet (shared as \"Anyone with the link can view\"). Search terms are read from its first column; row 1 is the header. A cell can hold a comparison: coffee, tea."
          },
          "geo": {
            "title": "Location",
            "type": "string",
            "description": "Where the searches come from. Empty = worldwide. A country (US, GB, DE), a region (US-CA, GB-ENG) or a US metro area (US-NY-501). Several separated by commas (US, GB, DE) give one row per location for every search term.",
            "default": ""
          },
          "timeRange": {
            "title": "Time range",
            "enum": [
              "today 12-m",
              "now 1-H",
              "now 4-H",
              "now 1-d",
              "now 7-d",
              "today 1-m",
              "today 3-m",
              "today 5-y",
              "all",
              ""
            ],
            "type": "string",
            "description": "The period to analyse. Shorter ranges give finer points: past hour and 4 hours by the minute, past day every 8 minutes, past 7 days hourly, up to 90 days daily, 12 months and 5 years weekly, since 2004 monthly.",
            "default": "today 12-m"
          },
          "customTimeRange": {
            "title": "Custom time range",
            "type": "string",
            "description": "Optional, overrides Time range. Dates as \"YYYY-MM-DD YYYY-MM-DD\" (e.g. 2024-01-01 2024-12-31, from 2004 on), or hours as \"YYYY-MM-DDTHH YYYY-MM-DDTHH\" (UTC, within the past 7 days)."
          },
          "category": {
            "title": "Category",
            "enum": [
              "",
              "3",
              "47",
              "44",
              "22",
              "12",
              "5",
              "7",
              "71",
              "8",
              "45",
              "65",
              "11",
              "13",
              "958",
              "19",
              "16",
              "299",
              "14",
              "66",
              "29",
              "533",
              "174",
              "18",
              "20",
              "67"
            ],
            "type": "string",
            "description": "Limit the searches to one category, e.g. \"jaguar\" in Autos & Vehicles means the car. For a sub-category use Category ID below, or paste a Google Trends URL with cat= in Search terms.",
            "default": ""
          },
          "categoryId": {
            "title": "Category ID",
            "minimum": 0,
            "maximum": 100000,
            "type": "integer",
            "description": "Optional, overrides Category: any of Google Trends' 1,100+ category IDs, e.g. 916 = Coffee & Tea, 390 = Mobile Phones. Find one in a Google Trends URL (cat=916)."
          },
          "searchType": {
            "title": "Search type",
            "enum": [
              "web",
              "images",
              "news",
              "shopping",
              "youtube"
            ],
            "type": "string",
            "description": "Which Google search to measure: web search, image search, Google News, Google Shopping or YouTube search.",
            "default": "web"
          },
          "language": {
            "title": "Language",
            "enum": [
              "en-US",
              "en-GB",
              "de",
              "fr",
              "es",
              "it",
              "pt-BR",
              "nl",
              "pl",
              "ja",
              "ko",
              "zh-CN",
              "ru",
              "tr",
              "hi",
              "id"
            ],
            "type": "string",
            "description": "Language of region names, topic names and date labels. Does not change which searches are counted.",
            "default": "en-US"
          },
          "includeInterestOverTime": {
            "title": "Include the full timeline",
            "type": "boolean",
            "description": "Every point of interest over time (0-100) in each row. Off keeps rows small; the summary columns (average, latest, peak, trend change) are filled either way.",
            "default": true
          },
          "includeInterestByRegion": {
            "title": "Interest by region",
            "type": "boolean",
            "description": "Where the term is most popular (0-100 per region; for a comparison, each term's share of the region). Adds one request per search.",
            "default": true
          },
          "regionResolution": {
            "title": "Region level",
            "enum": [
              "auto",
              "COUNTRY",
              "REGION",
              "DMA",
              "CITY"
            ],
            "type": "string",
            "description": "Level of the region breakdown. Auto = Google's choice (countries for worldwide, states or regions for a country). Metro areas exist for the US only.",
            "default": "auto"
          },
          "includeLowVolumeRegions": {
            "title": "Include low-volume regions",
            "type": "boolean",
            "description": "Also list regions with little search volume, as Google's \"Include low search volume regions\" checkbox does.",
            "default": false
          },
          "includeRelatedQueries": {
            "title": "Related queries",
            "type": "boolean",
            "description": "Top and rising searches related to each term (25 each), with Breakout flags for queries up more than 5,000 %. Adds one request per term.",
            "default": true
          },
          "includeTopics": {
            "title": "Topic suggestions",
            "type": "boolean",
            "description": "Google's Knowledge Graph topics for each term (e.g. coffee -> Coffee, Beverage, /m/02vqfm). Search a topic ID to count every spelling and language of it. Adds one request per distinct term.",
            "default": false
          },
          "trendingCountries": {
            "title": "Trending now: countries",
            "type": "array",
            "description": "Get what is trending on Google right now, one row per trending search, with search volume, growth, start time, category and related searches. One country or region code per line: US, GB, DE, US-CA.",
            "items": {
              "type": "string"
            }
          },
          "trendingHours": {
            "title": "Trending window",
            "enum": [
              "4",
              "24",
              "48",
              "168"
            ],
            "type": "string",
            "description": "Trends that started within this window.",
            "default": "24"
          },
          "trendingCategory": {
            "title": "Trending category",
            "enum": [
              "all",
              "1",
              "2",
              "3",
              "20",
              "4",
              "5",
              "6",
              "7",
              "8",
              "9",
              "10",
              "11",
              "13",
              "14",
              "15",
              "16",
              "17",
              "18",
              "19"
            ],
            "type": "string",
            "description": "Only trends in this category.",
            "default": "all"
          },
          "trendingSort": {
            "title": "Trending sort",
            "enum": [
              "relevance",
              "volume",
              "recency"
            ],
            "type": "string",
            "description": "Order of the trends before the per-country limit is applied: Google's relevance order, highest search volume first, or newest first.",
            "default": "relevance"
          },
          "trendingActiveOnly": {
            "title": "Active trends only",
            "type": "boolean",
            "description": "Skip trends Google marks as ended.",
            "default": false
          },
          "trendingNewsPerTrend": {
            "title": "News articles per trend",
            "minimum": 0,
            "maximum": 10,
            "type": "integer",
            "description": "How many news articles (title, link, source, time, image) to attach to each trending search. 0 = none.",
            "default": 0
          },
          "maxTrendingPerCountry": {
            "title": "Max trending searches per country",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "Trending now rows per country, after filters and sorting. The US often has 400+ trends a day.",
            "default": 50
          },
          "maxItems": {
            "title": "Max results",
            "minimum": 1,
            "maximum": 1000000,
            "type": "integer",
            "description": "Stop after this many rows in total (keyword rows plus trending searches). You pay per row, so this is also your cost cap for the run.",
            "default": 1000
          },
          "proxyConfiguration": {
            "title": "Proxy",
            "type": "object",
            "description": "Leave off. The Actor uses Apify's own addresses and moves to Apify datacenter proxies by itself when Google Trends rate-limits one. Set a proxy only if you must use your own; results do not depend on the address.",
            "default": {
              "useApifyProxy": false
            }
          },
          "maxConcurrency": {
            "title": "Concurrency",
            "minimum": 1,
            "maximum": 20,
            "type": "integer",
            "description": "How many searches run at the same time. Lower it if the log shows rate limits.",
            "default": 5
          },
          "requestTimeoutSecs": {
            "title": "Request timeout",
            "minimum": 5,
            "maximum": 120,
            "type": "integer",
            "description": "How long to wait for one response before trying another address.",
            "default": 30
          },
          "maxRetries": {
            "title": "Retries per request",
            "minimum": 0,
            "maximum": 5,
            "type": "integer",
            "description": "Extra attempts, on fresh addresses, for rate-limited or failed requests.",
            "default": 2
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}