@isnow890/naver-search-mcp 1.0.46 → 1.0.48
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +0 -0
- package/README.md +90 -215
- package/dist/data/categories.json +0 -0
- package/dist/src/clients/naver-api-core.client.d.ts +0 -0
- package/dist/src/clients/naver-api-core.client.js +0 -0
- package/dist/src/clients/naver-search.client.d.ts +0 -0
- package/dist/src/clients/naver-search.client.js +0 -0
- package/dist/src/handlers/category.handlers.d.ts +0 -0
- package/dist/src/handlers/category.handlers.js +17 -13
- package/dist/src/handlers/datalab.handlers.d.ts +0 -0
- package/dist/src/handlers/datalab.handlers.js +26 -17
- package/dist/src/handlers/search.handlers.d.ts +0 -0
- package/dist/src/handlers/search.handlers.js +0 -0
- package/dist/src/index.d.ts +2 -2
- package/dist/src/index.js +38 -24
- package/dist/src/schemas/category.schemas.d.ts +0 -0
- package/dist/src/schemas/category.schemas.js +0 -0
- package/dist/src/schemas/datalab.schemas.d.ts +0 -0
- package/dist/src/schemas/datalab.schemas.js +2 -2
- package/dist/src/schemas/search.schemas.d.ts +0 -0
- package/dist/src/schemas/search.schemas.js +0 -0
- package/dist/src/types/datalab.types.d.ts +0 -0
- package/dist/src/types/datalab.types.js +0 -0
- package/dist/src/types/search.types.d.ts +0 -0
- package/dist/src/types/search.types.js +0 -0
- package/dist/src/types/time.types.d.ts +0 -0
- package/dist/src/types/time.types.js +0 -0
- package/dist/src/utils/date.utils.d.ts +29 -0
- package/dist/src/utils/date.utils.js +51 -0
- package/package.json +1 -2
- package/dist/data/README.md +0 -26
- package/dist/ref/naver-search-mcp-fixed-main/package.json +0 -39
- package/dist/ref/naver-search-mcp-fixed-main/src/clients/naver-api-core.client.d.ts +0 -11
- package/dist/ref/naver-search-mcp-fixed-main/src/clients/naver-api-core.client.js +0 -30
- package/dist/ref/naver-search-mcp-fixed-main/src/clients/naver-search.client.d.ts +0 -70
- package/dist/ref/naver-search-mcp-fixed-main/src/clients/naver-search.client.js +0 -100
- package/dist/ref/naver-search-mcp-fixed-main/src/handlers/datalab.handlers.d.ts +0 -61
- package/dist/ref/naver-search-mcp-fixed-main/src/handlers/datalab.handlers.js +0 -137
- package/dist/ref/naver-search-mcp-fixed-main/src/handlers/search.handlers.d.ts +0 -44
- package/dist/ref/naver-search-mcp-fixed-main/src/handlers/search.handlers.js +0 -81
- package/dist/ref/naver-search-mcp-fixed-main/src/index.d.ts +0 -2
- package/dist/ref/naver-search-mcp-fixed-main/src/index.js +0 -122
- package/dist/ref/naver-search-mcp-fixed-main/src/schemas/datalab.schemas.d.ts +0 -336
- package/dist/ref/naver-search-mcp-fixed-main/src/schemas/datalab.schemas.js +0 -103
- package/dist/ref/naver-search-mcp-fixed-main/src/schemas/search.schemas.d.ts +0 -80
- package/dist/ref/naver-search-mcp-fixed-main/src/schemas/search.schemas.js +0 -62
- package/dist/ref/naver-search-mcp-fixed-main/src/tools/datalab.tools.d.ts +0 -13
- package/dist/ref/naver-search-mcp-fixed-main/src/tools/datalab.tools.js +0 -70
- package/dist/ref/naver-search-mcp-fixed-main/src/tools/search.tools.d.ts +0 -13
- package/dist/ref/naver-search-mcp-fixed-main/src/tools/search.tools.js +0 -62
- package/dist/ref/naver-search-mcp-fixed-main/src/types/datalab.types.d.ts +0 -78
- package/dist/ref/naver-search-mcp-fixed-main/src/types/datalab.types.js +0 -1
- package/dist/ref/naver-search-mcp-fixed-main/src/types/search.types.d.ts +0 -44
- package/dist/ref/naver-search-mcp-fixed-main/src/types/search.types.js +0 -1
- package/dist/src/handlers/time.handlers.d.ts +0 -11
- package/dist/src/handlers/time.handlers.js +0 -32
- package/dist/src/schemas/time.schemas.d.ts +0 -6
- package/dist/src/schemas/time.schemas.js +0 -7
- package/dist/src/utils/memory-manager.d.ts +0 -87
- package/dist/src/utils/memory-manager.js +0 -211
package/LICENSE
CHANGED
|
File without changes
|
package/README.md
CHANGED
|
@@ -3,79 +3,31 @@
|
|
|
3
3
|
[](README-ko.md)
|
|
4
4
|
|
|
5
5
|
[](https://archestra.ai/mcp-catalog/isnow890__naver-search-mcp)
|
|
6
|
-
[](https://smithery.ai/server/@isnow890/naver-search-mcp)
|
|
7
6
|
[](https://mcp.so/server/naver-search-mcp/isnow890)
|
|
8
7
|
|
|
9
|
-
|
|
8
|
+
MCP server for Naver Search API and DataLab API integration, enabling comprehensive search across various Naver services and data trend analysis.
|
|
10
9
|
|
|
11
|
-
|
|
10
|
+
## Available on ClawHub for OpenClaw
|
|
12
11
|
|
|
13
|
-
|
|
14
|
-
- Excel compatibility issues fixed in category search - Replaced with JSON functionality
|
|
15
|
-
- Web Korean search (`search_webkr`) functionality restored
|
|
16
|
-
- Full compatibility with Smithery platform installations
|
|
12
|
+
You can install this MCP server as an OpenClaw skill from ClawHub:
|
|
17
13
|
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
- Enhanced all existing tool descriptions to reference time tool for temporal queries
|
|
22
|
-
- Improved temporal context handling for "today", "now", "current" searches
|
|
23
|
-
- Comprehensive Korean time formatting with multiple output formats
|
|
24
|
-
|
|
25
|
-
###### 1.0.4 (2025-08-21)
|
|
26
|
-
|
|
27
|
-
- `find_category` tool added - with fuzzy matching and ranking system support
|
|
28
|
-
- Enhanced parameter validation with Zod schema
|
|
29
|
-
- Improved category search workflow
|
|
30
|
-
|
|
31
|
-
###### 1.0.30 (2025-08-04)
|
|
32
|
-
|
|
33
|
-
- MCP SDK upgraded to 1.17.1
|
|
34
|
-
- Fixed compatibility issues with Smithery specification changes
|
|
35
|
-
- Added comprehensive DataLab shopping category code documentation
|
|
36
|
-
|
|
37
|
-
###### 1.0.2 (2025-04-26)
|
|
38
|
-
|
|
39
|
-
- README updated: cafe article search tool and version history section improved
|
|
40
|
-
|
|
41
|
-
###### 1.0.1 (2025-04-26)
|
|
42
|
-
|
|
43
|
-
- Cafe article search feature added
|
|
44
|
-
- Shopping category info added to zod
|
|
45
|
-
- Source code refactored
|
|
46
|
-
|
|
47
|
-
###### 1.0.0 (2025-04-08)
|
|
48
|
-
|
|
49
|
-
- Initial release
|
|
50
|
-
|
|
51
|
-
#### Prerequisites
|
|
14
|
+
```bash
|
|
15
|
+
openclaw skills install naver-search-mcp
|
|
16
|
+
```
|
|
52
17
|
|
|
53
|
-
|
|
54
|
-
- Node.js 18 or higher
|
|
55
|
-
- NPM 8 or higher
|
|
56
|
-
- Docker (optional, for container deployment)
|
|
18
|
+
The ClawHub skill uses the published npm package internally and requires `NAVER_CLIENT_ID` and `NAVER_CLIENT_SECRET` in your OpenClaw environment.
|
|
57
19
|
|
|
58
|
-
|
|
20
|
+
## Quick Start: Use Without API Key
|
|
59
21
|
|
|
60
|
-
|
|
61
|
-
2. Click "Register Application"
|
|
62
|
-
3. Enter application name and select ALL of the following APIs:
|
|
63
|
-
- Search (for blog, news, book search, etc.)
|
|
64
|
-
- DataLab (Search Trends)
|
|
65
|
-
- DataLab (Shopping Insight)
|
|
66
|
-
4. Set the obtained Client ID and Client Secret as environment variables
|
|
22
|
+
You can use this server immediately without API keys through [Kakao PlayMCP](https://playmcp.kakao.com/mcp/154). Simply visit the link and start using it right away!
|
|
67
23
|
|
|
68
24
|
## Tool Details
|
|
69
25
|
|
|
70
26
|
### Available tools:
|
|
71
27
|
|
|
72
|
-
#### 🕐 Time & Context Tools
|
|
73
|
-
|
|
74
|
-
- **get_current_korean_time**: Get current Korean time (KST) with comprehensive date/time information. Essential for understanding "today", "now", or "current" context in Korean timezone. Always use this tool when temporal context is needed for searches or analysis.
|
|
75
|
-
|
|
76
28
|
#### 🆕 Category Search
|
|
77
29
|
|
|
78
|
-
- **find_category**: Category search tool
|
|
30
|
+
- **find_category**: Category search tool so you no longer need to manually check category numbers in URLs for trend and shopping insight searches. Just describe the category in natural language.
|
|
79
31
|
|
|
80
32
|
#### Search Tools
|
|
81
33
|
|
|
@@ -103,106 +55,26 @@
|
|
|
103
55
|
- **datalab_shopping_keyword_by_gender**: Analyze shopping keyword trends by gender
|
|
104
56
|
- **datalab_shopping_keyword_by_age**: Analyze shopping keyword trends by age group
|
|
105
57
|
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
```
|
|
121
|
-
|
|
122
|
-
#### 📱 Digital Marketing Strategy
|
|
123
|
-
|
|
124
|
-
```javascript
|
|
125
|
-
// Beauty industry analysis
|
|
126
|
-
find_category("cosmetics") → Find beauty categories
|
|
127
|
-
datalab_shopping_gender → 95% female vs 5% male shoppers
|
|
128
|
-
datalab_shopping_device → Mobile dominance in beauty shopping
|
|
129
|
-
datalab_shopping_keywords → "tint" vs "lipstick" keyword performance
|
|
130
|
-
```
|
|
131
|
-
|
|
132
|
-
#### 🏢 Business Intelligence & Competitive Analysis
|
|
133
|
-
|
|
134
|
-
```javascript
|
|
135
|
-
// Tech product insights
|
|
136
|
-
find_category("smartphone") → Check electronics categories
|
|
137
|
-
datalab_shopping_category → Track iPhone vs Galaxy trends
|
|
138
|
-
datalab_shopping_age → 20-30s as main smartphone buyers
|
|
139
|
-
datalab_shopping_device → PC vs mobile shopping behavior
|
|
140
|
-
```
|
|
141
|
-
|
|
142
|
-
#### 📊 Seasonal Business Planning
|
|
143
|
-
|
|
144
|
-
```javascript
|
|
145
|
-
// Holiday shopping analysis
|
|
146
|
-
find_category("gift") → Gift categories
|
|
147
|
-
datalab_shopping_category → Black Friday, Christmas trends
|
|
148
|
-
datalab_shopping_keywords → "Mother's Day gift" vs "birthday gift"
|
|
149
|
-
datalab_shopping_age → Age-based gift purchasing patterns
|
|
150
|
-
```
|
|
151
|
-
|
|
152
|
-
#### 🎯 Customer Persona Development
|
|
153
|
-
|
|
154
|
-
```javascript
|
|
155
|
-
// Fitness market analysis
|
|
156
|
-
find_category("exercise") → Sports/fitness categories
|
|
157
|
-
datalab_shopping_gender → Male vs female fitness spending
|
|
158
|
-
datalab_shopping_age → Primary fitness demographics (20-40s)
|
|
159
|
-
datalab_shopping_keywords → "home workout" vs "gym" trend analysis
|
|
160
|
-
```
|
|
161
|
-
|
|
162
|
-
### 📈 Advanced Analysis Scenarios
|
|
163
|
-
|
|
164
|
-
#### Market Entry Strategy
|
|
165
|
-
|
|
166
|
-
1. **Category Discovery**: Use `find_category` to explore market segments
|
|
167
|
-
2. **Trend Analysis**: Identify growing vs declining categories
|
|
168
|
-
3. **Demographic Targeting**: Age/gender analysis for customer targeting
|
|
169
|
-
4. **Competitive Intelligence**: Keyword performance comparison
|
|
170
|
-
5. **Device Strategy**: Mobile vs PC shopping optimization
|
|
171
|
-
|
|
172
|
-
#### Product Launch Planning
|
|
173
|
-
|
|
174
|
-
1. **Market Validation**: Category growth trends and seasonality
|
|
175
|
-
2. **Target Customers**: Demographic analysis for product positioning
|
|
176
|
-
3. **Marketing Channels**: Device preferences for advertising strategy
|
|
177
|
-
4. **Competitive Landscape**: Keyword competition and opportunities
|
|
178
|
-
5. **Pricing Strategy**: Category performance and price correlation
|
|
179
|
-
|
|
180
|
-
#### Performance Monitoring
|
|
181
|
-
|
|
182
|
-
1. **Category Health**: Monitor product category trends
|
|
183
|
-
2. **Keyword Tracking**: Track brand and product keyword performance
|
|
184
|
-
3. **Demographic Shifts**: Monitor changing customer demographics
|
|
185
|
-
4. **Seasonal Patterns**: Plan inventory and marketing campaigns
|
|
186
|
-
5. **Competitive Benchmarking**: Compare performance against category averages
|
|
187
|
-
|
|
188
|
-
### Quick Reference: Popular Category Codes
|
|
189
|
-
|
|
190
|
-
| Category | Code | Korean |
|
|
191
|
-
| ------------------- | -------- | ------------- |
|
|
192
|
-
| Fashion/Clothing | 50000000 | 패션의류 |
|
|
193
|
-
| Cosmetics/Beauty | 50000002 | 화장품/미용 |
|
|
194
|
-
| Digital/Electronics | 50000003 | 디지털/가전 |
|
|
195
|
-
| Sports/Leisure | 50000004 | 스포츠/레저 |
|
|
196
|
-
| Food/Beverages | 50000008 | 식품/음료 |
|
|
197
|
-
| Health/Medical | 50000009 | 건강/의료용품 |
|
|
198
|
-
|
|
199
|
-
💡 **Tip**: Use `find_category` with fuzzy searches like "beauty", "fashion", "electronics" to easily find categories.
|
|
58
|
+
## Getting API Keys
|
|
59
|
+
|
|
60
|
+
1. Visit [Naver Developers](https://developers.naver.com/apps/#/register) and log in with your Naver account
|
|
61
|
+
2. Click the "Application Registration" (애플리케이션 등록) button
|
|
62
|
+
3. Fill in the application information:
|
|
63
|
+
- **Application Name**: Enter any name (e.g., "Naver Search MCP")
|
|
64
|
+
- **Usage**: Select "Search" (검색)
|
|
65
|
+
4. In the API Settings section, check ALL of the following APIs:
|
|
66
|
+
- **Search** (검색) - Required for blog, news, book, cafe article, web, image, kin, encyclopedia, academic, and local search
|
|
67
|
+
- **DataLab - Search Trends** (데이터랩 - 검색어 트렌드) - Required for search term trend analysis
|
|
68
|
+
- **DataLab - Shopping Insight** (데이터랩 - 쇼핑인사이트) - Required for shopping trend analysis
|
|
69
|
+
5. Click "Register" to complete registration
|
|
70
|
+
6. After registration, you'll see your **Client ID** and **Client Secret** on the application detail page
|
|
71
|
+
7. Use these credentials in the configuration below
|
|
200
72
|
|
|
201
73
|
## Installation
|
|
202
74
|
|
|
203
75
|
### Method 1: NPX Installation (Recommended)
|
|
204
76
|
|
|
205
|
-
The most reliable way to use this MCP server is through
|
|
77
|
+
The most reliable way to use this MCP server is through NPX. For detailed package information, see the [NPM package page](https://www.npmjs.com/package/@isnow890/naver-search-mcp).
|
|
206
78
|
|
|
207
79
|
#### Claude Desktop Configuration
|
|
208
80
|
|
|
@@ -223,9 +95,9 @@ Add to Claude Desktop config file (`%APPDATA%\Claude\claude_desktop_config.json`
|
|
|
223
95
|
}
|
|
224
96
|
```
|
|
225
97
|
|
|
226
|
-
####
|
|
98
|
+
#### Claude Code Configuration
|
|
227
99
|
|
|
228
|
-
Add to
|
|
100
|
+
Add to your Claude Code settings:
|
|
229
101
|
|
|
230
102
|
```json
|
|
231
103
|
{
|
|
@@ -242,38 +114,21 @@ Add to `mcp.json`:
|
|
|
242
114
|
}
|
|
243
115
|
```
|
|
244
116
|
|
|
245
|
-
### Method 2:
|
|
246
|
-
|
|
247
|
-
⚠️ **Important Notice**: Smithery installation may experience connection timeouts and hanging issues due to WebSocket relay infrastructure problems. This is a known Smithery platform issue, not a problem with this MCP server code. **NPX installation (Method 1) is strongly recommended for reliable operation.**
|
|
248
|
-
|
|
249
|
-
#### Known Issues with Smithery:
|
|
250
|
-
- Server initialization hangs or times out
|
|
251
|
-
- `Error -32001: Request timed out`
|
|
252
|
-
- WebSocket connection drops after handshake
|
|
253
|
-
- Server shuts down unexpectedly before processing requests
|
|
254
|
-
|
|
255
|
-
#### If you still want to try Smithery:
|
|
117
|
+
### Method 2: ClawHub Installation for OpenClaw
|
|
256
118
|
|
|
257
|
-
|
|
119
|
+
This MCP server can also be used from OpenClaw through the ClawHub skill wrapper. Install it with:
|
|
258
120
|
|
|
259
121
|
```bash
|
|
260
|
-
|
|
122
|
+
openclaw skills install naver-search-mcp
|
|
261
123
|
```
|
|
262
124
|
|
|
263
|
-
|
|
125
|
+
The ClawHub skill uses the same published npm package internally:
|
|
264
126
|
|
|
265
127
|
```bash
|
|
266
|
-
|
|
267
|
-
npx -y @smithery/cli@latest install @isnow890/naver-search-mcp --client cursor
|
|
268
|
-
|
|
269
|
-
# Windsurf
|
|
270
|
-
npx -y @smithery/cli@latest install @isnow890/naver-search-mcp --client windsurf
|
|
271
|
-
|
|
272
|
-
# Cline
|
|
273
|
-
npx -y @smithery/cli@latest install @isnow890/naver-search-mcp --client cline
|
|
128
|
+
npx -y @isnow890/naver-search-mcp
|
|
274
129
|
```
|
|
275
130
|
|
|
276
|
-
|
|
131
|
+
Make sure `NAVER_CLIENT_ID` and `NAVER_CLIENT_SECRET` are configured in your OpenClaw environment before using the skill.
|
|
277
132
|
|
|
278
133
|
### Method 3: Local Installation
|
|
279
134
|
|
|
@@ -292,7 +147,7 @@ npm run build
|
|
|
292
147
|
|
|
293
148
|
##### Or Download ZIP File
|
|
294
149
|
|
|
295
|
-
1. Download the latest version from [GitHub Releases](https://github.com/isnow890/naver-search-mcp
|
|
150
|
+
1. Download the latest version from [GitHub Releases](https://github.com/isnow890/naver-search-mcp)
|
|
296
151
|
2. Extract the ZIP file to your desired location
|
|
297
152
|
3. Navigate to the extracted folder in terminal:
|
|
298
153
|
|
|
@@ -382,51 +237,71 @@ pwd
|
|
|
382
237
|
|
|
383
238
|
After completing the configuration, completely close and restart Claude Desktop to activate the Naver Search MCP server.
|
|
384
239
|
|
|
240
|
+
## Prerequisites
|
|
241
|
+
|
|
242
|
+
- Naver Developers API Key (Client ID and Secret)
|
|
243
|
+
- Node.js 18 or higher
|
|
244
|
+
- NPM 8 or higher
|
|
245
|
+
|
|
246
|
+
## License
|
|
247
|
+
|
|
248
|
+
MIT License
|
|
249
|
+
|
|
385
250
|
---
|
|
386
251
|
|
|
387
|
-
##
|
|
252
|
+
## Version History
|
|
388
253
|
|
|
389
|
-
###
|
|
254
|
+
### 1.0.48 (2026-05-12)
|
|
390
255
|
|
|
391
|
-
|
|
256
|
+
- Fixed `find_category` data loading when the MCP server is launched by `npx` from a different working directory
|
|
257
|
+
- Category data is now resolved relative to the installed package before falling back to local development paths
|
|
392
258
|
|
|
393
|
-
|
|
394
|
-
docker run -i --rm \
|
|
395
|
-
-e NAVER_CLIENT_ID=your_client_id \
|
|
396
|
-
-e NAVER_CLIENT_SECRET=your_client_secret \
|
|
397
|
-
mcp/naver-search
|
|
398
|
-
```
|
|
259
|
+
### 1.0.47 (2025-01-03)
|
|
399
260
|
|
|
400
|
-
|
|
261
|
+
- **Added "today" keyword support** for all DataLab date parameters - no need to call separate time tool
|
|
262
|
+
- **Fixed server termination issue** - MCP server now properly exits when client disconnects
|
|
263
|
+
- **Added graceful shutdown handlers** for SIGINT, SIGTERM, and transport close events
|
|
264
|
+
- **Removed get_current_korean_time tool** - redundant with new "today" keyword feature
|
|
265
|
+
- **Removed memory monitoring module** - resolved setInterval blocking process exit
|
|
266
|
+
- **Special thanks to @gloomyrobot** for reporting the server termination issue
|
|
401
267
|
|
|
402
|
-
|
|
403
|
-
{
|
|
404
|
-
"mcpServers": {
|
|
405
|
-
"naver-search": {
|
|
406
|
-
"command": "docker",
|
|
407
|
-
"args": [
|
|
408
|
-
"run",
|
|
409
|
-
"-i",
|
|
410
|
-
"--rm",
|
|
411
|
-
"-e",
|
|
412
|
-
"NAVER_CLIENT_ID=your_client_id",
|
|
413
|
-
"-e",
|
|
414
|
-
"NAVER_CLIENT_SECRET=your_client_secret",
|
|
415
|
-
"mcp/naver-search"
|
|
416
|
-
]
|
|
417
|
-
}
|
|
418
|
-
}
|
|
419
|
-
}
|
|
420
|
-
```
|
|
268
|
+
### 1.0.45 (2025-09-28)
|
|
421
269
|
|
|
422
|
-
|
|
270
|
+
- Resolved platform compatibility issues for hosted MCP installations
|
|
271
|
+
- Replaced the Excel export in category search with JSON for better compatibility
|
|
272
|
+
- Restored the `search_webkr` tool for Korean web search
|
|
273
|
+
- Improved hosted platform installation compatibility
|
|
423
274
|
|
|
424
|
-
|
|
275
|
+
### 1.0.44 (2025-08-31)
|
|
425
276
|
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
277
|
+
- Added the `get_current_korean_time` tool for essential Korea Standard Time context
|
|
278
|
+
- Referenced the time tool across existing tool descriptions for temporal queries
|
|
279
|
+
- Improved handling of "today", "now", and "current" searches with temporal context
|
|
280
|
+
- Expanded Korean date and time formatting outputs with multiple formats
|
|
429
281
|
|
|
430
|
-
|
|
282
|
+
### 1.0.40 (2025-08-21)
|
|
431
283
|
|
|
432
|
-
|
|
284
|
+
- Added the `find_category` tool with fuzzy matching so you no longer need to check category numbers manually in URLs
|
|
285
|
+
- Enhanced parameter validation with Zod schema
|
|
286
|
+
- Improved the category search workflow
|
|
287
|
+
- Implemented a level-based category ranking system that prioritizes top-level categories
|
|
288
|
+
|
|
289
|
+
### 1.0.30 (2025-08-04)
|
|
290
|
+
|
|
291
|
+
- MCP SDK upgraded to 1.17.1
|
|
292
|
+
- Fixed compatibility issues with hosted MCP platform specification changes
|
|
293
|
+
- Added comprehensive DataLab shopping category code documentation
|
|
294
|
+
|
|
295
|
+
### 1.0.2 (2025-04-26)
|
|
296
|
+
|
|
297
|
+
- README updated: cafe article search tool and version history section improved
|
|
298
|
+
|
|
299
|
+
### 1.0.1 (2025-04-26)
|
|
300
|
+
|
|
301
|
+
- Cafe article search feature added
|
|
302
|
+
- Shopping category info added to zod
|
|
303
|
+
- Source code refactored
|
|
304
|
+
|
|
305
|
+
### 1.0.0 (2025-04-08)
|
|
306
|
+
|
|
307
|
+
- Initial release
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
// Import JSON data - bundle-safe approach
|
|
2
2
|
import { existsSync, readFileSync } from 'fs';
|
|
3
|
-
import { join } from 'path';
|
|
3
|
+
import { dirname, join } from 'path';
|
|
4
|
+
import { fileURLToPath } from 'url';
|
|
4
5
|
// 메모리 누수 방지를 위한 지연 로딩 캐시
|
|
5
6
|
let categoriesCache = null;
|
|
7
|
+
const moduleDir = dirname(fileURLToPath(import.meta.url));
|
|
6
8
|
// Load categories data with fallback paths for different environments
|
|
7
9
|
function getCategoriesData() {
|
|
8
10
|
// 캐시된 데이터가 있으면 반환 (메모리 효율성)
|
|
@@ -10,19 +12,21 @@ function getCategoriesData() {
|
|
|
10
12
|
return categoriesCache;
|
|
11
13
|
}
|
|
12
14
|
try {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
const
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
15
|
+
const candidatePaths = [
|
|
16
|
+
// Package-relative path. Works when launched by npx from any cwd.
|
|
17
|
+
join(moduleDir, '..', '..', 'data', 'categories.json'),
|
|
18
|
+
// Local development fallbacks.
|
|
19
|
+
join(process.cwd(), 'dist', 'data', 'categories.json'),
|
|
20
|
+
join(process.cwd(), 'data', 'categories.json'),
|
|
21
|
+
];
|
|
22
|
+
for (const categoryPath of candidatePaths) {
|
|
23
|
+
if (existsSync(categoryPath)) {
|
|
24
|
+
const categoryJson = readFileSync(categoryPath, 'utf8').toString();
|
|
25
|
+
categoriesCache = JSON.parse(categoryJson);
|
|
26
|
+
return categoriesCache;
|
|
27
|
+
}
|
|
24
28
|
}
|
|
25
|
-
throw new Error(
|
|
29
|
+
throw new Error(`카테고리 데이터 파일을 찾을 수 없습니다. Tried: ${candidatePaths.join(', ')}`);
|
|
26
30
|
}
|
|
27
31
|
catch (error) {
|
|
28
32
|
console.error('카테고리 데이터 로딩 실패:', error);
|
|
File without changes
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { NaverSearchClient } from "../clients/naver-search.client.js";
|
|
2
|
+
import { resolveDateRange } from "../utils/date.utils.js";
|
|
2
3
|
// 클라이언트 인스턴스 (싱글톤)
|
|
3
4
|
const client = NaverSearchClient.getInstance();
|
|
4
5
|
/**
|
|
@@ -50,7 +51,8 @@ export const datalabToolHandlers = {
|
|
|
50
51
|
* @param params DatalabSearch
|
|
51
52
|
*/
|
|
52
53
|
export async function handleSearchTrend(params) {
|
|
53
|
-
|
|
54
|
+
const { startDate, endDate } = resolveDateRange(params.startDate, params.endDate);
|
|
55
|
+
return client.searchTrend({ ...params, startDate, endDate });
|
|
54
56
|
}
|
|
55
57
|
/**
|
|
56
58
|
* 쇼핑 카테고리 트렌드 핸들러
|
|
@@ -58,7 +60,8 @@ export async function handleSearchTrend(params) {
|
|
|
58
60
|
* @param params DatalabShopping
|
|
59
61
|
*/
|
|
60
62
|
export async function handleShoppingCategoryTrend(params) {
|
|
61
|
-
|
|
63
|
+
const { startDate, endDate } = resolveDateRange(params.startDate, params.endDate);
|
|
64
|
+
return client.datalabShoppingCategory({ ...params, startDate, endDate });
|
|
62
65
|
}
|
|
63
66
|
/**
|
|
64
67
|
* 쇼핑 기기별 트렌드 핸들러
|
|
@@ -66,9 +69,10 @@ export async function handleShoppingCategoryTrend(params) {
|
|
|
66
69
|
* @param params DatalabShoppingDevice
|
|
67
70
|
*/
|
|
68
71
|
export async function handleShoppingByDeviceTrend(params) {
|
|
72
|
+
const { startDate, endDate } = resolveDateRange(params.startDate, params.endDate);
|
|
69
73
|
return client.datalabShoppingByDevice({
|
|
70
|
-
startDate
|
|
71
|
-
endDate
|
|
74
|
+
startDate,
|
|
75
|
+
endDate,
|
|
72
76
|
timeUnit: params.timeUnit,
|
|
73
77
|
category: params.category,
|
|
74
78
|
device: params.device,
|
|
@@ -80,9 +84,10 @@ export async function handleShoppingByDeviceTrend(params) {
|
|
|
80
84
|
* @param params DatalabShoppingGender
|
|
81
85
|
*/
|
|
82
86
|
export async function handleShoppingByGenderTrend(params) {
|
|
87
|
+
const { startDate, endDate } = resolveDateRange(params.startDate, params.endDate);
|
|
83
88
|
return client.datalabShoppingByGender({
|
|
84
|
-
startDate
|
|
85
|
-
endDate
|
|
89
|
+
startDate,
|
|
90
|
+
endDate,
|
|
86
91
|
timeUnit: params.timeUnit,
|
|
87
92
|
category: params.category,
|
|
88
93
|
gender: params.gender,
|
|
@@ -94,9 +99,10 @@ export async function handleShoppingByGenderTrend(params) {
|
|
|
94
99
|
* @param params DatalabShoppingAge
|
|
95
100
|
*/
|
|
96
101
|
export async function handleShoppingByAgeTrend(params) {
|
|
102
|
+
const { startDate, endDate } = resolveDateRange(params.startDate, params.endDate);
|
|
97
103
|
return client.datalabShoppingByAge({
|
|
98
|
-
startDate
|
|
99
|
-
endDate
|
|
104
|
+
startDate,
|
|
105
|
+
endDate,
|
|
100
106
|
timeUnit: params.timeUnit,
|
|
101
107
|
category: params.category,
|
|
102
108
|
ages: params.ages,
|
|
@@ -108,10 +114,10 @@ export async function handleShoppingByAgeTrend(params) {
|
|
|
108
114
|
* @param params DatalabShoppingKeywords
|
|
109
115
|
*/
|
|
110
116
|
export async function handleShoppingKeywordsTrend(params) {
|
|
111
|
-
|
|
117
|
+
const { startDate, endDate } = resolveDateRange(params.startDate, params.endDate);
|
|
112
118
|
return client.datalabShoppingKeywords({
|
|
113
|
-
startDate
|
|
114
|
-
endDate
|
|
119
|
+
startDate,
|
|
120
|
+
endDate,
|
|
115
121
|
timeUnit: params.timeUnit,
|
|
116
122
|
category: params.category,
|
|
117
123
|
keyword: params.keyword,
|
|
@@ -123,9 +129,10 @@ export async function handleShoppingKeywordsTrend(params) {
|
|
|
123
129
|
* @param params DatalabShoppingKeywordDevice
|
|
124
130
|
*/
|
|
125
131
|
export async function handleShoppingKeywordByDeviceTrend(params) {
|
|
132
|
+
const { startDate, endDate } = resolveDateRange(params.startDate, params.endDate);
|
|
126
133
|
return client.datalabShoppingKeywordByDevice({
|
|
127
|
-
startDate
|
|
128
|
-
endDate
|
|
134
|
+
startDate,
|
|
135
|
+
endDate,
|
|
129
136
|
timeUnit: params.timeUnit,
|
|
130
137
|
category: params.category,
|
|
131
138
|
keyword: params.keyword,
|
|
@@ -138,9 +145,10 @@ export async function handleShoppingKeywordByDeviceTrend(params) {
|
|
|
138
145
|
* @param params DatalabShoppingKeywordGender
|
|
139
146
|
*/
|
|
140
147
|
export async function handleShoppingKeywordByGenderTrend(params) {
|
|
148
|
+
const { startDate, endDate } = resolveDateRange(params.startDate, params.endDate);
|
|
141
149
|
return client.datalabShoppingKeywordByGender({
|
|
142
|
-
startDate
|
|
143
|
-
endDate
|
|
150
|
+
startDate,
|
|
151
|
+
endDate,
|
|
144
152
|
timeUnit: params.timeUnit,
|
|
145
153
|
category: params.category,
|
|
146
154
|
keyword: params.keyword,
|
|
@@ -153,9 +161,10 @@ export async function handleShoppingKeywordByGenderTrend(params) {
|
|
|
153
161
|
* @param params DatalabShoppingKeywordAge
|
|
154
162
|
*/
|
|
155
163
|
export async function handleShoppingKeywordByAgeTrend(params) {
|
|
164
|
+
const { startDate, endDate } = resolveDateRange(params.startDate, params.endDate);
|
|
156
165
|
return client.datalabShoppingKeywordByAge({
|
|
157
|
-
startDate
|
|
158
|
-
endDate
|
|
166
|
+
startDate,
|
|
167
|
+
endDate,
|
|
159
168
|
timeUnit: params.timeUnit,
|
|
160
169
|
category: params.category,
|
|
161
170
|
keyword: params.keyword,
|
|
File without changes
|
|
File without changes
|
package/dist/src/index.d.ts
CHANGED
|
@@ -17,7 +17,7 @@ export declare const configSchema: z.ZodObject<{
|
|
|
17
17
|
export declare function resetServerInstance(): void;
|
|
18
18
|
export declare function createNaverSearchServer({ config, }: {
|
|
19
19
|
config: z.infer<typeof configSchema>;
|
|
20
|
-
}): import("@modelcontextprotocol/sdk/server/index.js").Server<{
|
|
20
|
+
}): McpServer | import("@modelcontextprotocol/sdk/server/index.js").Server<{
|
|
21
21
|
method: string;
|
|
22
22
|
params?: {
|
|
23
23
|
[x: string]: unknown;
|
|
@@ -39,5 +39,5 @@ export declare function createNaverSearchServer({ config, }: {
|
|
|
39
39
|
_meta?: {
|
|
40
40
|
[x: string]: unknown;
|
|
41
41
|
} | undefined;
|
|
42
|
-
}
|
|
42
|
+
}>;
|
|
43
43
|
export default createNaverSearchServer;
|