Docs / API reference

POST/v1/data/google-trends/interest

Google Trends Interest

Compare Google Trends interest over time for one to five terms or topics.

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.

Compare Google Trends interest over time for one to five terms or topics.

Getting Started

Send your API key as a bearer token. Start with the smallest request below.

Send the smallest useful request and read the structured 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"
      }
    }
  ]
}

Options

Query and Target

Set the search term, identifier, or source URL that defines the request.

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": [
    "web scraping",
    "data extraction"
  ],
  "geo": "IN",
  "timeframe": "today 12-m",
  "hl": "en-US",
  "timezone": -330
}'
Example response
{
  "success": true,
  "source": "google_trends",
  "operation": "interest",
  "keywords": [
    "cake"
  ],
  "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"
      }
    }
  ]
}

Location and Language

Localize results with country, language, coordinates, or delivery-location fields.

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": "",
  "timeframe": "today 12-m",
  "hl": "en-US",
  "timezone": -330
}'
Example response
{
  "success": true,
  "source": "google_trends",
  "operation": "interest",
  "keywords": [
    "cake"
  ],
  "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"
      }
    }
  ]
}

Filters and Sorting

Narrow or order the returned records.

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,
  "property_name": ""
}'
Example response
{
  "success": true,
  "source": "google_trends",
  "operation": "interest",
  "keywords": [
    "cake"
  ],
  "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"
      }
    }
  ]
}

Request Controls

Set device, timeout, and request-specific controls.

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,
  "timeout_ms": 30000
}'
Example response
{
  "success": true,
  "source": "google_trends",
  "operation": "interest",
  "keywords": [
    "cake"
  ],
  "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"
      }
    }
  ]
}

Response

Read success first, then consume the endpoint-specific records and pagination fields shown below.

Error Handling

Handle 401 for authentication, 422 for invalid input, 429 for limits, and retry only transient failures.

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"
      }
    }
  ]
}