{
  "openapi": "3.0.1",
  "info": {
    "title": "Google Trends Scraper - Compare and Trending Now",
    "description": "Google Trends without a browser: interest over time, interest by region, related queries and true multi-keyword comparison on one 0-100 scale. Plus Trending Now per country with volume, growth and news. Export JSON, CSV or Excel, schedule it, call it as an MCP tool. Pay only for reports with data.",
    "version": "0.1",
    "x-build-id": "ls5mK9aLJpMLsbUU3"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/automation_craft~google-trends-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-automation_craft-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/automation_craft~google-trends-scraper/runs": {
      "post": {
        "operationId": "runs-sync-automation_craft-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/automation_craft~google-trends-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-automation_craft-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": {
          "scrapeTrendingNow": {
            "title": "Scrape Trending Now",
            "type": "boolean",
            "description": "Get the searches trending right now in each country listed under <b>Trending geos</b>, with search volume, growth %, start time, related keywords, and news articles. Fast (seconds) and needs no proxy. One flat $0.02 charge per country, however many trends come back."
          },
          "trendingGeos": {
            "title": "Trending geos",
            "type": "array",
            "description": "Country codes to get trending searches for: <code>US</code>, <code>GB</code>, <code>IN</code>, <code>DE</code>, <code>JP</code>… One charge per country.",
            "items": {
              "type": "string"
            }
          },
          "trendingHours": {
            "title": "Trending window (hours)",
            "minimum": 1,
            "maximum": 191,
            "type": "integer",
            "description": "How far back to look for trending searches, in hours. 4 = happening right now, 24 = today (default), 168 = past week. Google accepts 1-191.",
            "default": 24
          },
          "includeTrendingNews": {
            "title": "Attach news articles to trends",
            "type": "boolean",
            "description": "Attach related news articles (title, URL, source, image) to each trending item. Free, no extra charge.",
            "default": true
          },
          "maxTrendingItems": {
            "title": "Max trending items per geo",
            "minimum": 1,
            "type": "integer",
            "description": "Maximum trending items returned per country. Google provides up to ~480; the price per country is the same either way.",
            "default": 100
          },
          "keywords": {
            "title": "Keywords (analyzed individually)",
            "type": "array",
            "description": "Search terms to analyze. Each gets its own report: interest over time with summary stats, interest by region, and related queries. Each term is scored on its own 0-100 scale (use <b>Compare keywords</b> below if you need terms on ONE scale). Max 20 per run. $0.03 per report that contains data; failures and empty results are free.",
            "items": {
              "type": "string"
            }
          },
          "compareKeywords": {
            "title": "Compare keywords (shared scale)",
            "type": "array",
            "description": "2-5 terms compared in a single Google Trends query, so their values share one 0-100 scale and are directly comparable, like the compare view on trends.google.com. Produces one comparison item with per-term stats, regional breakdown, and related queries. $0.05 when it contains data.",
            "items": {
              "type": "string"
            }
          },
          "timeframe": {
            "title": "Timeframe",
            "type": "string",
            "description": "Time range for keyword analysis: <code>now 1-H</code>, <code>now 4-H</code>, <code>now 1-d</code>, <code>now 7-d</code>, <code>today 1-m</code>, <code>today 3-m</code>, <code>today 12-m</code> (default), <code>today 5-y</code>, <code>all</code>, or a custom range like <code>2024-01-01 2024-12-31</code>.",
            "default": "today 12-m"
          },
          "geo": {
            "title": "Geo (keyword analysis)",
            "type": "string",
            "description": "Where to measure keyword interest: a country (<code>US</code>), a region (<code>US-CA</code>), or empty for worldwide.",
            "default": "US"
          },
          "category": {
            "title": "Category id",
            "minimum": 0,
            "type": "integer",
            "description": "Google Trends category id to narrow keyword results (0 = all categories). Find ids in the trends.google.com URL after <code>cat=</code>.",
            "default": 0
          },
          "property": {
            "title": "Search property",
            "enum": [
              "",
              "images",
              "news",
              "youtube",
              "froogle"
            ],
            "type": "string",
            "description": "Which Google surface to measure: Web Search (default), Image Search, Google News, YouTube, or Google Shopping.",
            "default": ""
          },
          "includeInterestOverTime": {
            "title": "Interest over time",
            "type": "boolean",
            "description": "Include the interest-over-time series plus computed stats (average, peak, peak date, latest, direction).",
            "default": true
          },
          "includeInterestByRegion": {
            "title": "Interest by region",
            "type": "boolean",
            "description": "Include the breakdown of which regions search the term most.",
            "default": true
          },
          "includeRelatedQueries": {
            "title": "Related queries",
            "type": "boolean",
            "description": "Include top and rising related queries. (Related topics are not offered: Google returns empty topic lists to automated sessions.)",
            "default": true
          },
          "language": {
            "title": "Language",
            "type": "string",
            "description": "Language for trending results: <code>en</code>, <code>de</code>, <code>ja</code>…",
            "default": "en"
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Proxy used for keyword analysis. Keep the default (Apify residential): Google rate-limits Trends per IP, and residential rotation is what makes keyword reports reliable. Datacenter proxies will fail with 429 errors. Trending Now never uses a 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
                  }
                }
              },
              "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}