npm package: @gamal.dev/n8n-nodes-google-trends
Description: Google Trends node for n8n
Author: n8n
Latest version: 1.0.0

# n8n-nodes-google-trends

This is an n8n community node that lets you use Google Trends API in your n8n workflows.

[n8n](https://n8n.io/) is a [fair-code licensed](https://docs.n8n.io/reference/license/) workflow automation platform.

[Installation](#installation)  
[Operations](#operations)  
[Credentials](#credentials)  
[Compatibility](#compatibility)  
[Usage](#usage)  
[Resources](#resources)  

## Installation

Follow the [installation guide](https://docs.n8n.io/integrations/community-nodes/installation/) in the n8n community nodes documentation.

1. Go to **Settings > Community Nodes**.
2. Select **Install**.
3. Enter `n8n-nodes-google-trends` in **Enter npm package name**.
4. Agree to the [risks](https://docs.n8n.io/integrations/community-nodes/risks/) of using community nodes: select **I understand the risks of installing unverified code from a public source**.
5. Select **Install**.

After installing the node, you can use it like any other node in n8n.

## Operations

* **Interest Over Time**: Get search interest data over time for keywords
* **Related Queries**: Get related search queries for keywords  
* **Related Topics**: Get related topics for keywords

## Credentials

This node doesn't require any credentials as it uses Google Trends' public API.

## Compatibility

* Minimum n8n version: 0.175.0
* Credentials: Not required

## Usage

### Interest Over Time

Get search interest data over time for one or more keywords:

1. Select **Interest Over Time** operation
2. Enter keywords (separate multiple with commas: `bitcoin, ethereum`)
3. Optionally set start/end dates
4. Optionally set geography (e.g., `US`, `GB`, `DE`)
5. Optionally set category ID

### Related Queries

Get related search queries for keywords:

1. Select **Related Queries** operation  
2. Enter keywords
3. Configure other optional parameters

### Related Topics

Get related topics for keywords:

1. Select **Related Topics** operation
2. Enter keywords  
3. Configure other optional parameters

## Parameters

* **Operation**: Choose between Interest Over Time, Related Queries, or Related Topics
* **Keywords**: One or more keywords (comma-separated for multiple)
* **Start Time**: Start date for data collection (optional)
* **End Time**: End date for data collection (optional)
* **Geography**: ISO country code like US, GB, DE (optional, defaults to worldwide)
* **Category**: Category ID for filtering results (optional, 0 = all categories)

## Resources

* [n8n community nodes documentation](https://docs.n8n.io/integrations/community-nodes/)
* [Google Trends API documentation](https://github.com/pat310/google-trends-api)

## License

MIT

## Development

To set up for development:

```bash
# Clone or download this repository
git clone <repository-url>
cd n8n-nodes-google-trends

# Install dependencies
npm install

# Build the node
npm run build

# For development with watch mode
npm run dev
```

## Version History

### 1.0.0
- Initial release
- Support for Interest Over Time, Related Queries, and Related Topics operations
- Multiple keywords support
- Configurable date ranges and geography filtering