Content
# Naver API MCP Server
Naver Shopping Insights API and Search API integrated MCP (Model Context Protocol) server.
## Features
### Shopping Insights API (DataLab)
#### Category Trends
- `get-category-trends`: Get trends for multiple categories (up to 3 categories)
- `get-category-by-device`: Get trends for a specific category by device
- `get-category-by-gender`: Get trends for a specific category by gender
- `get-category-by-age`: Get trends for a specific category by age
#### Keyword Trends
- `get-keyword-trends`: Get trends for multiple keywords (up to 5 keywords)
- `get-keyword-by-device`: Get trends for a specific keyword by device
- `get-keyword-by-gender`: Get trends for a specific keyword by gender
- `get-keyword-by-age`: Get trends for a specific keyword by age
### Search API
- `search-blog`: Blog search
- `search-kin`: Knowledge search
- `search-shopping`: Shopping search
- `search-encyclopedia`: Encyclopedia search
## Installation
### Install from Source Code
```bash
# Clone repository
git clone https://github.com/dataartai/naver-api-mcp.git
cd naver-api-mcp
# Install dependencies
npm install
# Build
npm run build
```
## Configuration
1. Register an application on the Naver Developer Center (https://developers.naver.com) and obtain a client ID and secret.
- **Shopping Insights API**: Apply for DataLab > Shopping Insights API
- **Search API**: Apply for Search API
2. Set environment variables:
**Method 1: Using `.env` file (local development)**
```env
NAVER_CLIENT_ID=your-client-id
NAVER_CLIENT_SECRET=your-client-secret
```
**Method 2: Directly in MCP configuration file**
```json
{
"mcpServers": {
"naver-api": {
"command": "node",
"args": [
"path/to/naver-api-mcp/dist/index.js"
],
"env": {
"NAVER_CLIENT_ID": "YOUR-CLIENT-ID",
"NAVER_CLIENT_SECRET": "YOUR-CLIENT-SECRET"
}
}
}
}
```
## Usage
### Direct Execution
```bash
npm start
```
### Claude Desktop Configuration
To use with Claude Desktop, add the following configuration file:
**Windows**: `%APPDATA%\Claude\claude_desktop_config.json`
```json
{
"mcpServers": {
"naver-api": {
"command": "node",
"args": [
"D:\\OneDrive\\Cursorhome\\naver-api-mcp\\dist\\index.js"
],
"cwd": "D:\\OneDrive\\Cursorhome\\naver-api-mcp",
"env": {
"NAVER_CLIENT_ID": "YOUR-CLIENT-ID",
"NAVER_CLIENT_SECRET": "YOUR-CLIENT-SECRET"
}
}
}
}
```
> **Note**: Update the path to the actual project path.
## MCP Tool Usage Guide
### Shopping Insights API Tools
#### Category Trends
**`get-category-trends`**: Get trends for multiple categories
- `startDate`: Start date (YYYY-MM-DD)
- `endDate`: End date (YYYY-MM-DD)
- `timeUnit`: Time unit (`date`, `week`, `month`)
- `categories`: Category array (up to 3 categories)
- `device`: Device filter (`pc`, `mobile`, `all`) - optional
- `gender`: Gender filter (`m`, `f`, `a`) - optional
- `ages`: Age group array (`10`, `20`, `30`, `40`, `50`, `60`) - optional
**`get-category-by-device`**: Get trends for a specific category by device
- `category`: Category ID (e.g., `50000000`)
**`get-category-by-gender`**: Get trends for a specific category by gender
- `category`: Category ID
**`get-category-by-age`**: Get trends for a specific category by age
- `category`: Category ID
#### Keyword Trends
**`get-keyword-trends`**: Get trends for multiple keywords
- `category`: Category ID
- `keywords`: Keyword array (up to 5 keywords)
**`get-keyword-by-device`**: Get trends for a specific keyword by device
- `category`: Category ID
- `keyword`: Search keyword
**`get-keyword-by-gender`**: Get trends for a specific keyword by gender
- `category`: Category ID
- `keyword`: Search keyword
**`get-keyword-by-age`**: Get trends for a specific keyword by age
- `category`: Category ID
- `keyword`: Search keyword
### Search API Tools
#### Blog Search (`search-blog`)
- `query`: Search term (required)
- `display`: Number of results to display at once (1-100, default: 10)
- `start`: Search start position (1-1000, default: 1)
- `sort`: Sorting method (`sim`: accuracy, `date`: date)
#### Knowledge Search (`search-kin`)
- `query`: Search term (required)
- `display`: Number of results to display at once (1-100, default: 10)
- `start`: Search start position (1-1000, default: 1)
- `sort`: Sorting method (`sim`: accuracy, `date`: date, `point`: points)
#### Shopping Search (`search-shopping`)
- `query`: Search term (required)
- `display`: Number of results to display at once (1-100, default: 10)
- `start`: Search start position (1-1000, default: 1)
- `sort`: Sorting method (`sim`: accuracy, `date`: date, `asc`: price ascending, `dsc`: price descending)
- `filter`: Filter (`naverpay`: Naver Pay linked products only) - optional
- `exclude`: Product type to exclude (`used`: used, `rental`: rental, `cbshop`: cross-border shopping) - optional
#### Encyclopedia Search (`search-encyclopedia`)
- `query`: Search term (required)
- `display`: Number of results to display at once (1-100, default: 10)
- `start`: Search start position (1-1000, default: 1)
## Major Category IDs
- Fashion clothing: `50000000`
- Cosmetics/Beauty: `50000002`
- Digital/Electronics: `50000003`
- Food: `50000008`
## API Limitations
### Shopping Insights API (DataLab)
- **Category array**: Up to 3 categories only (`get-category-trends`)
- **Keyword array**: Up to 5 keywords only (`get-keyword-trends`)
- **Daily call limit**: 1,000 calls per day
### Search API
- **Daily call limit**: 25,000 calls per day
- **display**: Up to 100
- **start**: Up to 1,000
## Project Structure
```
naver-api-mcp/
├── src/
│ ├── index.ts # Server entry point
│ ├── server.ts # MCP server definition
│ └── clients/
│ ├── shoppingInsightClient.ts # Shopping Insights API client
│ └── searchClient.ts # Search API client
├── dist/ # Build output
├── package.json
└── README.md
```
## License
ISC
## References
- [Naver DataLab API documentation > Shopping Insights](https://developers.naver.com/docs/serviceapi/datalab/shopping/shopping.md)
- [Naver Search API documentation > Blog](https://developers.naver.com/docs/serviceapi/search/blog/blog.md)
- [Naver Search API documentation > Knowledge](https://developers.naver.com/docs/serviceapi/search/kin/kin.md)
- [Naver Search API documentation > Shopping](https://developers.naver.com/docs/serviceapi/search/shopping/shopping.md)
- [Naver Search API documentation > Encyclopedia](https://developers.naver.com/docs/serviceapi/search/encyclopedia/encyclopedia.md)
- [Model Context Protocol](https://modelcontextprotocol.io)