@maelitop/mention-mcp-server 1.0.0

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 ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2025 Maël LE PETIT
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,42 @@
1
+ # Mention MCP Server
2
+
3
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
4
+ [![NPM Version](https://img.shields.io/npm/v/@MaelitoP/mention-mcp-server.svg)](https://www.npmjs.com/package/@MaelitoP/mention-mcp-server)
5
+ [![NPM Downloads](https://img.shields.io/npm/dm/@MaelitoP/mention-mcp-server.svg)](https://www.npmjs.com/package/@MaelitoP/mention-mcp-server)
6
+
7
+ The [Model Context Protocol (MCP)](https://modelcontextprotocol.io/introduction) is an open protocol designed for effortless integration between LLM applications and external data sources or tools, offering a standardized framework to seamlessly provide LLMs with the context they require.
8
+
9
+ This server supplies tools designed to support social listening and monitoring capabilities through the Mention API.
10
+
11
+ ## Supported Tools
12
+
13
+ | Tool | Description |
14
+ |------|-------------|
15
+ | `get_account_info` | Retrieve account details and subscription plan |
16
+ | `get_app_data` | Get available languages, countries, sources |
17
+ | `list_alerts` | List all monitoring alerts with pagination |
18
+ | `get_alert` | Get detailed information about specific alerts |
19
+ | `create_basic_alert` | Create alerts with simple keyword matching |
20
+ | `create_advanced_alert` | Create alerts with boolean query syntax |
21
+ | `update_alert` | Modify existing alert criteria and settings |
22
+
23
+ ## Usage with Claude Desktop
24
+
25
+ Add the following to your Claude Desktop configuration file:
26
+ ```json
27
+ {
28
+ "mcpServers": {
29
+ "mention": {
30
+ "command": "npx",
31
+ "args": ["-y", "@maelitop/mention-mcp-server"],
32
+ "env": {
33
+ "MENTION_API_KEY": "your_mention_api_key_here"
34
+ }
35
+ }
36
+ }
37
+ }
38
+ ```
39
+
40
+ ## License
41
+
42
+ This project is licensed under the [MIT License](LICENSE).
@@ -0,0 +1,3 @@
1
+ #!/usr/bin/env node
2
+ export {};
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":""}
package/dist/index.js ADDED
@@ -0,0 +1,477 @@
1
+ #!/usr/bin/env node
2
+ import { Server } from "@modelcontextprotocol/sdk/server/index.js";
3
+ import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
4
+ import { CallToolRequestSchema, ErrorCode, ListPromptsRequestSchema, ListResourcesRequestSchema, ListToolsRequestSchema, McpError, } from "@modelcontextprotocol/sdk/types.js";
5
+ import { z } from "zod";
6
+ import { zodToJsonSchema } from "zod-to-json-schema";
7
+ const API_BASE_URL = "https://web.mention.com/api";
8
+ const ListAlertsArgsSchema = z.object({
9
+ limit: z
10
+ .number()
11
+ .min(1)
12
+ .max(100)
13
+ .optional()
14
+ .describe("Maximum number of alerts to return (1-100)"),
15
+ cursor: z.string().optional().describe("Pagination cursor for retrieving next page"),
16
+ });
17
+ const GetAlertArgsSchema = z.object({
18
+ alert_id: z.string().describe("The alert ID to retrieve"),
19
+ });
20
+ const CreateBasicAlertArgsSchema = z.object({
21
+ name: z.string().min(1).max(255).describe("Alert name (required, 1-255 characters)"),
22
+ description: z
23
+ .string()
24
+ .max(1000)
25
+ .optional()
26
+ .describe("Alert description (optional, max 1000 characters)"),
27
+ color: z
28
+ .string()
29
+ .regex(/^#[0-9a-fA-F]{6}$/)
30
+ .optional()
31
+ .describe("Alert color code (e.g., '#05e363')"),
32
+ included_keywords: z
33
+ .array(z.string())
34
+ .min(1)
35
+ .describe("Keywords to include - at least one keyword that should be present in mentions"),
36
+ required_keywords: z
37
+ .array(z.string())
38
+ .optional()
39
+ .describe("Keywords that must be present in all mentions (optional)"),
40
+ excluded_keywords: z
41
+ .array(z.string())
42
+ .optional()
43
+ .describe("Keywords to exclude from mentions (optional)"),
44
+ monitored_website: z
45
+ .object({
46
+ domain: z.string().describe("Domain to specifically monitor"),
47
+ block_self: z.boolean().optional().describe("Whether to block mentions from own site"),
48
+ })
49
+ .optional()
50
+ .describe("Specific website monitoring configuration (optional)"),
51
+ languages: z.array(z.string()).max(5).optional().describe("Language codes to monitor (max 5)"),
52
+ countries: z.array(z.string()).optional().describe("Country codes to monitor"),
53
+ sources: z
54
+ .array(z.enum(["twitter", "news", "web", "blogs", "videos", "forums", "images", "facebook"]))
55
+ .optional()
56
+ .describe("Sources to monitor"),
57
+ blocked_sites: z.array(z.string()).optional().describe("Domains to exclude from monitoring"),
58
+ noise_detection: z
59
+ .boolean()
60
+ .default(true)
61
+ .optional()
62
+ .describe("Enable noise detection (default: true)"),
63
+ });
64
+ const CreateAdvancedAlertArgsSchema = z.object({
65
+ name: z.string().min(1).max(255).describe("Alert name (required, 1-255 characters)"),
66
+ description: z
67
+ .string()
68
+ .max(1000)
69
+ .optional()
70
+ .describe("Alert description (optional, max 1000 characters)"),
71
+ color: z
72
+ .string()
73
+ .regex(/^#[0-9a-fA-F]{6}$/)
74
+ .optional()
75
+ .describe("Alert color code (e.g., '#05e363')"),
76
+ query_string: z
77
+ .string()
78
+ .describe("Advanced query string with boolean operators (e.g., '(NASA OR SpaceX) AND mars NOT nose')"),
79
+ languages: z.array(z.string()).max(5).optional().describe("Language codes to monitor (max 5)"),
80
+ countries: z.array(z.string()).optional().describe("Country codes to monitor"),
81
+ sources: z
82
+ .array(z.enum(["twitter", "news", "web", "blogs", "videos", "forums", "images", "facebook"]))
83
+ .optional()
84
+ .describe("Sources to monitor"),
85
+ blocked_sites: z.array(z.string()).optional().describe("Domains to exclude from monitoring"),
86
+ noise_detection: z
87
+ .boolean()
88
+ .default(true)
89
+ .optional()
90
+ .describe("Enable noise detection (default: true)"),
91
+ });
92
+ const UpdateAlertArgsSchema = z.object({
93
+ alert_id: z.string().describe("The alert ID to update"),
94
+ name: z.string().min(1).max(255).optional().describe("New alert name (1-255 characters)"),
95
+ description: z
96
+ .string()
97
+ .max(1000)
98
+ .optional()
99
+ .describe("New alert description (max 1000 characters)"),
100
+ color: z
101
+ .string()
102
+ .regex(/^#[0-9a-fA-F]{6}$/)
103
+ .optional()
104
+ .describe("New alert color code"),
105
+ query_type: z.enum(["basic", "advanced"]).optional().describe("Type of query to update"),
106
+ included_keywords: z
107
+ .array(z.string())
108
+ .optional()
109
+ .describe("Keywords to include (for basic queries)"),
110
+ required_keywords: z
111
+ .array(z.string())
112
+ .optional()
113
+ .describe("Required keywords (for basic queries)"),
114
+ excluded_keywords: z
115
+ .array(z.string())
116
+ .optional()
117
+ .describe("Excluded keywords (for basic queries)"),
118
+ query_string: z.string().optional().describe("Advanced query string (for advanced queries)"),
119
+ languages: z.array(z.string()).max(5).optional().describe("Language codes to monitor (max 5)"),
120
+ countries: z.array(z.string()).optional().describe("Country codes to monitor"),
121
+ sources: z
122
+ .array(z.enum(["twitter", "news", "web", "blogs", "videos", "forums", "images", "facebook"]))
123
+ .optional()
124
+ .describe("Sources to monitor"),
125
+ blocked_sites: z.array(z.string()).optional().describe("Domains to exclude from monitoring"),
126
+ noise_detection: z.boolean().optional().describe("Enable noise detection"),
127
+ });
128
+ const PauseAlertArgsSchema = z.object({
129
+ alert_id: z.string().describe("The alert ID to pause"),
130
+ });
131
+ const UnpauseAlertArgsSchema = z.object({
132
+ alert_id: z.string().describe("The alert ID to unpause"),
133
+ });
134
+ function logError(message, error) {
135
+ const errorData = {
136
+ error: {
137
+ code: -32603,
138
+ message: message,
139
+ data: error ? (error instanceof Error ? error.message : String(error)) : undefined,
140
+ },
141
+ };
142
+ console.error(JSON.stringify(errorData));
143
+ }
144
+ async function makeAPIRequest(endpoint, options = {}) {
145
+ const apiKey = process.env.MENTION_API_KEY;
146
+ if (!apiKey) {
147
+ const errorMsg = "MENTION_API_KEY environment variable is required";
148
+ logError(errorMsg);
149
+ throw new McpError(ErrorCode.InvalidRequest, errorMsg);
150
+ }
151
+ const url = `${API_BASE_URL}${endpoint}`;
152
+ try {
153
+ const response = await fetch(url, {
154
+ ...options,
155
+ headers: {
156
+ Authorization: `Bearer ${apiKey}`,
157
+ "Content-Type": "application/json",
158
+ ...options.headers,
159
+ },
160
+ });
161
+ if (!response.ok) {
162
+ let errorData;
163
+ try {
164
+ errorData = (await response.json());
165
+ }
166
+ catch {
167
+ const errorMsg = `HTTP ${response.status}: ${response.statusText}`;
168
+ logError(`Mention API request failed: ${errorMsg}`, { endpoint, status: response.status });
169
+ throw new McpError(ErrorCode.InternalError, errorMsg);
170
+ }
171
+ const errorMsg = `Mention API Error: ${errorData.error.message}${errorData.error.details ? ` - ${errorData.error.details}` : ""}`;
172
+ logError(`Mention API error: ${errorMsg}`, { endpoint, errorData });
173
+ throw new McpError(ErrorCode.InternalError, errorMsg);
174
+ }
175
+ return response.json();
176
+ }
177
+ catch (error) {
178
+ if (error instanceof McpError) {
179
+ throw error;
180
+ }
181
+ const errorMsg = `Network request failed: ${error instanceof Error ? error.message : String(error)}`;
182
+ logError(errorMsg, { endpoint, error });
183
+ throw new McpError(ErrorCode.InternalError, errorMsg);
184
+ }
185
+ }
186
+ const server = new Server({
187
+ name: "mention-mcp-server",
188
+ version: "1.0.0",
189
+ }, {
190
+ capabilities: {
191
+ tools: {},
192
+ resources: {},
193
+ prompts: {},
194
+ },
195
+ });
196
+ server.setRequestHandler(ListToolsRequestSchema, async () => {
197
+ return {
198
+ tools: [
199
+ {
200
+ name: "get_account_info",
201
+ description: "Get current account information including subscription plan, account ID, and capabilities. This tool should be called first to understand account limitations and determine which alert creation tools are available.",
202
+ inputSchema: {
203
+ type: "object",
204
+ properties: {},
205
+ required: [],
206
+ },
207
+ },
208
+ {
209
+ name: "get_app_data",
210
+ description: "Get application configuration data including available languages, countries, sources, colors, and other metadata needed for creating alerts.",
211
+ inputSchema: {
212
+ type: "object",
213
+ properties: {},
214
+ required: [],
215
+ },
216
+ },
217
+ {
218
+ name: "list_alerts",
219
+ description: "List all monitoring alerts for the current account with pagination support.",
220
+ inputSchema: zodToJsonSchema(ListAlertsArgsSchema),
221
+ },
222
+ {
223
+ name: "get_alert",
224
+ description: "Get detailed information about a specific alert by its ID.",
225
+ inputSchema: zodToJsonSchema(GetAlertArgsSchema),
226
+ },
227
+ {
228
+ name: "create_basic_alert",
229
+ description: "Create a new basic monitoring alert. Basic alerts use simple keyword matching with included_keywords, required_keywords, and excluded_keywords arrays.",
230
+ inputSchema: zodToJsonSchema(CreateBasicAlertArgsSchema),
231
+ },
232
+ {
233
+ name: "create_advanced_alert",
234
+ description: "Create a new advanced monitoring alert with boolean query syntax. Advanced alerts use complex query strings with boolean operators like AND, OR, NOT.",
235
+ inputSchema: zodToJsonSchema(CreateAdvancedAlertArgsSchema),
236
+ },
237
+ {
238
+ name: "update_alert",
239
+ description: "Update an existing alert with new criteria or settings.",
240
+ inputSchema: zodToJsonSchema(UpdateAlertArgsSchema),
241
+ },
242
+ {
243
+ name: "pause_alert",
244
+ description: "Temporarily pause monitoring for a specific alert.",
245
+ inputSchema: zodToJsonSchema(PauseAlertArgsSchema),
246
+ },
247
+ {
248
+ name: "unpause_alert",
249
+ description: "Resume monitoring for a previously paused alert.",
250
+ inputSchema: zodToJsonSchema(UnpauseAlertArgsSchema),
251
+ },
252
+ ],
253
+ };
254
+ });
255
+ server.setRequestHandler(ListResourcesRequestSchema, async () => {
256
+ return {
257
+ resources: [],
258
+ };
259
+ });
260
+ server.setRequestHandler(ListPromptsRequestSchema, async () => {
261
+ return {
262
+ prompts: [],
263
+ };
264
+ });
265
+ server.setRequestHandler(CallToolRequestSchema, async (request) => {
266
+ const { name, arguments: args } = request.params;
267
+ try {
268
+ switch (name) {
269
+ case "get_account_info": {
270
+ const data = await makeAPIRequest("/accounts/me");
271
+ return {
272
+ content: [
273
+ {
274
+ type: "text",
275
+ text: JSON.stringify(data, null, 2),
276
+ },
277
+ ],
278
+ };
279
+ }
280
+ case "get_app_data": {
281
+ const data = await makeAPIRequest("/app/data");
282
+ return {
283
+ content: [
284
+ {
285
+ type: "text",
286
+ text: JSON.stringify(data, null, 2),
287
+ },
288
+ ],
289
+ };
290
+ }
291
+ case "list_alerts": {
292
+ const { limit, cursor } = ListAlertsArgsSchema.parse(args);
293
+ const accountData = await makeAPIRequest("/accounts/me");
294
+ const accountId = accountData.account.id;
295
+ const queryParams = new URLSearchParams();
296
+ if (limit)
297
+ queryParams.append("limit", limit.toString());
298
+ if (cursor)
299
+ queryParams.append("cursor", cursor);
300
+ const endpoint = `/accounts/${accountId}/alerts${queryParams.toString() ? `?${queryParams.toString()}` : ""}`;
301
+ const data = await makeAPIRequest(endpoint);
302
+ return {
303
+ content: [
304
+ {
305
+ type: "text",
306
+ text: JSON.stringify(data, null, 2),
307
+ },
308
+ ],
309
+ };
310
+ }
311
+ case "get_alert": {
312
+ const { alert_id } = GetAlertArgsSchema.parse(args);
313
+ const accountData = await makeAPIRequest("/accounts/me");
314
+ const accountId = accountData.account.id;
315
+ const data = await makeAPIRequest(`/accounts/${accountId}/alerts/${alert_id}`);
316
+ return {
317
+ content: [
318
+ {
319
+ type: "text",
320
+ text: JSON.stringify(data, null, 2),
321
+ },
322
+ ],
323
+ };
324
+ }
325
+ case "create_basic_alert": {
326
+ const validated = CreateBasicAlertArgsSchema.parse(args);
327
+ const accountData = await makeAPIRequest("/accounts/me");
328
+ const accountId = accountData.account.id;
329
+ const { included_keywords, required_keywords, excluded_keywords, monitored_website, ...requestData } = validated;
330
+ const requestBody = {
331
+ ...requestData,
332
+ query: {
333
+ type: "basic",
334
+ included_keywords,
335
+ required_keywords,
336
+ excluded_keywords,
337
+ monitored_website,
338
+ },
339
+ };
340
+ const data = await makeAPIRequest(`/accounts/${accountId}/alerts`, {
341
+ method: "POST",
342
+ body: JSON.stringify(requestBody),
343
+ });
344
+ return {
345
+ content: [
346
+ {
347
+ type: "text",
348
+ text: JSON.stringify(data, null, 2),
349
+ },
350
+ ],
351
+ };
352
+ }
353
+ case "create_advanced_alert": {
354
+ const validated = CreateAdvancedAlertArgsSchema.parse(args);
355
+ const accountData = await makeAPIRequest("/accounts/me");
356
+ const accountId = accountData.account.id;
357
+ const { query_string, ...requestData } = validated;
358
+ const requestBody = {
359
+ ...requestData,
360
+ query: {
361
+ type: "advanced",
362
+ query_string,
363
+ },
364
+ };
365
+ const data = await makeAPIRequest(`/accounts/${accountId}/alerts`, {
366
+ method: "POST",
367
+ body: JSON.stringify(requestBody),
368
+ });
369
+ return {
370
+ content: [
371
+ {
372
+ type: "text",
373
+ text: JSON.stringify(data, null, 2),
374
+ },
375
+ ],
376
+ };
377
+ }
378
+ case "update_alert": {
379
+ const validated = UpdateAlertArgsSchema.parse(args);
380
+ const { alert_id, query_type, included_keywords, required_keywords, excluded_keywords, query_string, ...updateData } = validated;
381
+ const accountData = await makeAPIRequest("/accounts/me");
382
+ const accountId = accountData.account.id;
383
+ const requestBody = { ...updateData };
384
+ if (query_type) {
385
+ if (query_type === "basic") {
386
+ requestBody.query = {
387
+ type: "basic",
388
+ included_keywords,
389
+ required_keywords,
390
+ excluded_keywords,
391
+ };
392
+ }
393
+ else if (query_type === "advanced") {
394
+ requestBody.query = {
395
+ type: "advanced",
396
+ query_string,
397
+ };
398
+ }
399
+ }
400
+ const data = await makeAPIRequest(`/accounts/${accountId}/alerts/${alert_id}`, {
401
+ method: "PUT",
402
+ body: JSON.stringify(requestBody),
403
+ });
404
+ return {
405
+ content: [
406
+ {
407
+ type: "text",
408
+ text: JSON.stringify(data, null, 2),
409
+ },
410
+ ],
411
+ };
412
+ }
413
+ case "pause_alert": {
414
+ const { alert_id } = PauseAlertArgsSchema.parse(args);
415
+ const accountData = await makeAPIRequest("/accounts/me");
416
+ const accountId = accountData.account.id;
417
+ const data = await makeAPIRequest(`/accounts/${accountId}/alerts/${alert_id}/pause`, {
418
+ method: "POST",
419
+ });
420
+ return {
421
+ content: [
422
+ {
423
+ type: "text",
424
+ text: JSON.stringify(data, null, 2),
425
+ },
426
+ ],
427
+ };
428
+ }
429
+ case "unpause_alert": {
430
+ const { alert_id } = UnpauseAlertArgsSchema.parse(args);
431
+ const accountData = await makeAPIRequest("/accounts/me");
432
+ const accountId = accountData.account.id;
433
+ const data = await makeAPIRequest(`/accounts/${accountId}/alerts/${alert_id}/unpause`, {
434
+ method: "POST",
435
+ });
436
+ return {
437
+ content: [
438
+ {
439
+ type: "text",
440
+ text: JSON.stringify(data, null, 2),
441
+ },
442
+ ],
443
+ };
444
+ }
445
+ default:
446
+ throw new McpError(ErrorCode.MethodNotFound, `Unknown tool: ${name}`);
447
+ }
448
+ }
449
+ catch (error) {
450
+ if (error instanceof McpError) {
451
+ logError(`Tool execution error: ${error.message}`, {
452
+ tool: name,
453
+ args,
454
+ error: error.message,
455
+ });
456
+ throw error;
457
+ }
458
+ const errorMsg = `Tool execution failed: ${error instanceof Error ? error.message : String(error)}`;
459
+ logError(errorMsg, { tool: name, args, error });
460
+ throw new McpError(ErrorCode.InternalError, errorMsg);
461
+ }
462
+ });
463
+ async function main() {
464
+ try {
465
+ const transport = new StdioServerTransport();
466
+ await server.connect(transport);
467
+ }
468
+ catch (error) {
469
+ logError("Failed to start MCP server", error);
470
+ process.exit(1);
471
+ }
472
+ }
473
+ main().catch((error) => {
474
+ logError("Fatal error in main", error);
475
+ process.exit(1);
476
+ });
477
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAEA,OAAO,EAAE,MAAM,EAAE,MAAM,2CAA2C,CAAC;AACnE,OAAO,EAAE,oBAAoB,EAAE,MAAM,2CAA2C,CAAC;AACjF,OAAO,EACL,qBAAqB,EACrB,SAAS,EACT,wBAAwB,EACxB,0BAA0B,EAC1B,sBAAsB,EACtB,QAAQ,GACT,MAAM,oCAAoC,CAAC;AAC5C,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAErD,MAAM,YAAY,GAAG,6BAA6B,CAAC;AAEnD,MAAM,oBAAoB,GAAG,CAAC,CAAC,MAAM,CAAC;IACpC,KAAK,EAAE,CAAC;SACL,MAAM,EAAE;SACR,GAAG,CAAC,CAAC,CAAC;SACN,GAAG,CAAC,GAAG,CAAC;SACR,QAAQ,EAAE;SACV,QAAQ,CAAC,4CAA4C,CAAC;IACzD,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,4CAA4C,CAAC;CACrF,CAAC,CAAC;AAEH,MAAM,kBAAkB,GAAG,CAAC,CAAC,MAAM,CAAC;IAClC,QAAQ,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,0BAA0B,CAAC;CAC1D,CAAC,CAAC;AAEH,MAAM,0BAA0B,GAAG,CAAC,CAAC,MAAM,CAAC;IAC1C,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,G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AAC,CAAC;IACxD,CAAC;AACH,CAAC,CAAC,CAAC;AAEH,KAAK,UAAU,IAAI;IACjB,IAAI,CAAC;QACH,MAAM,SAAS,GAAG,IAAI,oBAAoB,EAAE,CAAC;QAC7C,MAAM,MAAM,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC;IAClC,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,QAAQ,CAAC,4BAA4B,EAAE,KAAK,CAAC,CAAC;QAC9C,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAClB,CAAC;AACH,CAAC;AAED,IAAI,EAAE,CAAC,KAAK,CAAC,CAAC,KAAK,EAAE,EAAE;IACrB,QAAQ,CAAC,qBAAqB,EAAE,KAAK,CAAC,CAAC;IACvC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAClB,CAAC,CAAC,CAAC"}
package/package.json ADDED
@@ -0,0 +1,49 @@
1
+ {
2
+ "name": "@maelitop/mention-mcp-server",
3
+ "version": "1.0.0",
4
+ "type": "module",
5
+ "main": "dist/index.js",
6
+ "bin": {
7
+ "mention-mcp-server": "dist/index.js"
8
+ },
9
+ "files": ["dist/**/*"],
10
+ "scripts": {
11
+ "build": "tsc",
12
+ "start": "node dist/index.js",
13
+ "dev": "tsx src/index.ts",
14
+ "prepublishOnly": "npm run build",
15
+ "test": "echo \"Error: no test specified\" && exit 1",
16
+ "lint": "biome lint .",
17
+ "lint:fix": "biome lint --write .",
18
+ "format": "biome format --write .",
19
+ "check": "biome check .",
20
+ "check:fix": "biome check --write .",
21
+ "ci": "npm run check && npm run build",
22
+ "version:patch": "npm version patch",
23
+ "version:minor": "npm version minor",
24
+ "version:major": "npm version major"
25
+ },
26
+ "keywords": ["mcp", "mention", "monitoring", "api", "agorapulse"],
27
+ "author": "MaelitoP",
28
+ "license": "MIT",
29
+ "description": "MCP server for the Mention API to monitor web and social media",
30
+ "repository": {
31
+ "type": "git",
32
+ "url": "git+https://github.com/MaelitoP/mention-mcp-server.git"
33
+ },
34
+ "bugs": {
35
+ "url": "https://github.com/MaelitoP/mention-mcp-server/issues"
36
+ },
37
+ "homepage": "https://github.com/MaelitoP/mention-mcp-server#readme",
38
+ "dependencies": {
39
+ "@modelcontextprotocol/sdk": "^1.12.1",
40
+ "zod": "^3.25.56",
41
+ "zod-to-json-schema": "^3.24.5"
42
+ },
43
+ "devDependencies": {
44
+ "@biomejs/biome": "^1.9.4",
45
+ "@types/node": "^22.15.30",
46
+ "tsx": "^4.19.4",
47
+ "typescript": "^5.8.3"
48
+ }
49
+ }