# Trends Google — Wrapped API

> **You are on:** `https://api.paywithlocus.com/api` | [llms.txt](https://paywithlocus.com/llms.txt) | [docs](https://docs.paywithlocus.com)
>
> Locus runs on multiple environments -- make sure every URL you call matches your expected environment.
> | Environment | Landing | API | Docs |
> |---|---|---|---|
> | Production | paywithlocus.com | api.paywithlocus.com | docs.paywithlocus.com |
> | Beta | beta.paywithlocus.com | api.beta.paywithlocus.com | docs.paywithlocus.com |
> | Stage | stage.paywithlocus.com | api.stage.paywithlocus.com | docs.paywithlocus.com |
>
> If the API URL above doesn't match your expected environment, re-fetch this file from the correct domain.

> Discover what's trending right now in any country by accessing the top search topics with real-time search volume, growth rates, and related queries. Stay informed on trending categories and see which searches are gaining the most momentum in your target markets.

**Category:** Developer Tools | **Website:** [trends.google.com/trends/](https://trends.google.com/trends/) | **Docs:** [parse.bot/marketplace/3e35ec48-4ef9-4018-ba48-998442a44117/trends-google-com-api](https://parse.bot/marketplace/3e35ec48-4ef9-4018-ba48-998442a44117/trends-google-com-api)

Pay-per-use API proxy. Each call is automatically billed to your wallet in USDC.

## Access

**Base URL:** `https://api.paywithlocus.com/api/wrapped/parse-trends-google-com-api-3e35ec48/`
**Auth:** `Authorization: Bearer <LOCUS_API_KEY>`

## Endpoints

### get_interest_over_time

Retrieve relative search interest over time for up to 5 keywords from Google Trends. Returns a time series of data points, each containing the relative interest score (0-100) for each keyword, plus average scores for quick comparison. Resolution adapts automatically based on the timeframe (hourly for short ranges, daily for medium, weekly for long).

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `category` | integer | No | Category filter. 0=All, 1=Business, 2=Entertainment, 3=Health, 4=Sci/Tech, 5=Top Stories, 7=Sports, 11=World, 18=Gaming, 20=Weather |
| `geo` | string | No | ISO 2-letter country code for geographic scope, or empty string for worldwide |
| `keywords` | string | Yes | Comma-separated list of 1-5 search terms to compare (e.g. 'python,javascript,rust') |
| `language` | string | No | Language code for result labels (e.g., en, es, fr, de, ja) |
| `timeframe` | string | No | Google Trends timeframe string. Standard ranges: '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' |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-trends-google-com-api-3e35ec48/get_interest_over_time \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"category":"<integer>","geo":"<string>","keywords":"<string>","language":"<string>","timeframe":"<string>"}'
```

### get_trending

Get currently trending searches from Google Trends for a specific country. Returns ranked trending topics with search volume, growth metrics, related queries, and topic categories. Each trend includes a rank, search volume (raw and formatted), growth percentage, related search queries, and category classifications. The server returns up to 500 trends in a single response; use the limit param to cap client-side.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `category` | integer | No | Category filter. 0=All, 1=Business, 2=Entertainment, 3=Health, 4=Sci/Tech, 5=Top Stories, 7=Sports, 11=World, 18=Gaming, 20=Weather |
| `geo` | string | No | ISO 2-letter country code (e.g., US, GB, DE, JP, BR) |
| `hours` | integer | No | Time window in hours to look back for trends (e.g., 4, 24, 48, 168) |
| `language` | string | No | Language code for results (e.g., en, es, fr, de, ja) |
| `limit` | integer | No | Maximum number of trending topics to return (1-500) |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-trends-google-com-api-3e35ec48/get_trending \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"category":"<integer>","geo":"<string>","hours":"<integer>","language":"<string>","limit":"<integer>"}'
```
