Docs / API reference

POST/v1/data/google-trends/interest

Google Trends Interest

Return Google Trends interest-over-time timeline values for one to five keywords or topic IDs, with geo, timeframe, locale, timezone, and vertical-property controls.

Execution model

Live request

Runtime depends on endpoint, target, pagination, rendering mode, and active plan limits.

Credit weight

Live catalog

Current weights are managed from the Data API Weights admin table and shown on pricing before use.

Parameters

NameTypeRequirementDescription
keywordsstring[]RequiredOne to five search terms or Google Trends topic IDs to compare.
geostringOptionalGoogle Trends geo code such as IN or US. Leave empty for worldwide.
timeframestringOptionalGoogle Trends timeframe, e.g. today 12-m, now 7-d, or today 5-y.
hlstringOptionalGoogle Trends locale.
timezonenumberOptionalTimezone offset in minutes.
property_name"" | "images" | "news" | "youtube" | "froogle"OptionalGoogle Trends vertical property. Empty means Web Search.
timeout_msnumberOptionalProvider request timeout in milliseconds (5000-90000).

Response fields

FieldTypeDescription
successbooleanWhether the request completed successfully.
timelinearrayInterest-over-time points with per-keyword values and has_data flags.
total_pointsnumberNumber of timeline points returned.
time_takennumberAPI response time in seconds.

Request and response

curl -X POST "https://api.datablue.dev/v1/data/google-trends/interest" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "keywords": [
    "cake",
    "milk"
  ],
  "geo": "IN",
  "timeframe": "today 12-m",
  "hl": "en-US",
  "timezone": -330
}'
Example response
{
  "success": true,
  "source": "google_trends",
  "operation": "interest",
  "keywords": [
    "cake",
    "milk"
  ],
  "geo": "IN",
  "timeframe": "today 12-m",
  "hl": "en-US",
  "timezone": -330,
  "property_name": "",
  "total_points": 2,
  "time_taken": 1.24,
  "timeline": [
    {
      "time": "1752537600",
      "formatted_time": "Jul 2025",
      "formatted_axis_time": "Jul 2025",
      "values": {
        "cake": 62,
        "milk": 77
      },
      "has_data": {
        "cake": true,
        "milk": true
      },
      "formatted_values": {
        "cake": "62",
        "milk": "77"
      }
    },
    {
      "time": "1753142400",
      "formatted_time": "Jul 2025",
      "formatted_axis_time": "Jul 2025",
      "values": {
        "cake": 58,
        "milk": 74
      },
      "has_data": {
        "cake": true,
        "milk": true
      },
      "formatted_values": {
        "cake": "58",
        "milk": "74"
      }
    }
  ]
}