@reaudit/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.
Files changed (119) hide show
  1. package/LICENSE +33 -0
  2. package/README.md +399 -0
  3. package/dist/auth/oauth-client.d.ts +43 -0
  4. package/dist/auth/oauth-client.d.ts.map +1 -0
  5. package/dist/auth/oauth-client.js +340 -0
  6. package/dist/auth/oauth-client.js.map +1 -0
  7. package/dist/auth/token-store.d.ts +41 -0
  8. package/dist/auth/token-store.d.ts.map +1 -0
  9. package/dist/auth/token-store.js +176 -0
  10. package/dist/auth/token-store.js.map +1 -0
  11. package/dist/index.d.ts +11 -0
  12. package/dist/index.d.ts.map +1 -0
  13. package/dist/index.js +480 -0
  14. package/dist/index.js.map +1 -0
  15. package/dist/lib/api-client.d.ts +970 -0
  16. package/dist/lib/api-client.d.ts.map +1 -0
  17. package/dist/lib/api-client.js +441 -0
  18. package/dist/lib/api-client.js.map +1 -0
  19. package/dist/lib/confirmation.d.ts +92 -0
  20. package/dist/lib/confirmation.d.ts.map +1 -0
  21. package/dist/lib/confirmation.js +224 -0
  22. package/dist/lib/confirmation.js.map +1 -0
  23. package/dist/lib/error-handler.d.ts +57 -0
  24. package/dist/lib/error-handler.d.ts.map +1 -0
  25. package/dist/lib/error-handler.js +235 -0
  26. package/dist/lib/error-handler.js.map +1 -0
  27. package/dist/lib/offline-mode.d.ts +107 -0
  28. package/dist/lib/offline-mode.d.ts.map +1 -0
  29. package/dist/lib/offline-mode.js +356 -0
  30. package/dist/lib/offline-mode.js.map +1 -0
  31. package/dist/lib/progress-tracker.d.ts +87 -0
  32. package/dist/lib/progress-tracker.d.ts.map +1 -0
  33. package/dist/lib/progress-tracker.js +238 -0
  34. package/dist/lib/progress-tracker.js.map +1 -0
  35. package/dist/prompts/index.d.ts +24 -0
  36. package/dist/prompts/index.d.ts.map +1 -0
  37. package/dist/prompts/index.js +305 -0
  38. package/dist/prompts/index.js.map +1 -0
  39. package/dist/resources/index.d.ts +44 -0
  40. package/dist/resources/index.d.ts.map +1 -0
  41. package/dist/resources/index.js +125 -0
  42. package/dist/resources/index.js.map +1 -0
  43. package/dist/tools/account.d.ts +25 -0
  44. package/dist/tools/account.d.ts.map +1 -0
  45. package/dist/tools/account.js +69 -0
  46. package/dist/tools/account.js.map +1 -0
  47. package/dist/tools/action-grids.d.ts +414 -0
  48. package/dist/tools/action-grids.d.ts.map +1 -0
  49. package/dist/tools/action-grids.js +271 -0
  50. package/dist/tools/action-grids.js.map +1 -0
  51. package/dist/tools/analytics-query.d.ts +126 -0
  52. package/dist/tools/analytics-query.d.ts.map +1 -0
  53. package/dist/tools/analytics-query.js +106 -0
  54. package/dist/tools/analytics-query.js.map +1 -0
  55. package/dist/tools/analytics.d.ts +57 -0
  56. package/dist/tools/analytics.d.ts.map +1 -0
  57. package/dist/tools/analytics.js +122 -0
  58. package/dist/tools/analytics.js.map +1 -0
  59. package/dist/tools/audits.d.ts +123 -0
  60. package/dist/tools/audits.d.ts.map +1 -0
  61. package/dist/tools/audits.js +226 -0
  62. package/dist/tools/audits.js.map +1 -0
  63. package/dist/tools/calendar.d.ts +57 -0
  64. package/dist/tools/calendar.d.ts.map +1 -0
  65. package/dist/tools/calendar.js +109 -0
  66. package/dist/tools/calendar.js.map +1 -0
  67. package/dist/tools/content-generation.d.ts +211 -0
  68. package/dist/tools/content-generation.d.ts.map +1 -0
  69. package/dist/tools/content-generation.js +363 -0
  70. package/dist/tools/content-generation.js.map +1 -0
  71. package/dist/tools/content.d.ts +92 -0
  72. package/dist/tools/content.d.ts.map +1 -0
  73. package/dist/tools/content.js +130 -0
  74. package/dist/tools/content.js.map +1 -0
  75. package/dist/tools/indexing.d.ts +132 -0
  76. package/dist/tools/indexing.d.ts.map +1 -0
  77. package/dist/tools/indexing.js +190 -0
  78. package/dist/tools/indexing.js.map +1 -0
  79. package/dist/tools/optimization.d.ts +70 -0
  80. package/dist/tools/optimization.d.ts.map +1 -0
  81. package/dist/tools/optimization.js +106 -0
  82. package/dist/tools/optimization.js.map +1 -0
  83. package/dist/tools/projects.d.ts +67 -0
  84. package/dist/tools/projects.d.ts.map +1 -0
  85. package/dist/tools/projects.js +113 -0
  86. package/dist/tools/projects.js.map +1 -0
  87. package/dist/tools/prompts.d.ts +306 -0
  88. package/dist/tools/prompts.d.ts.map +1 -0
  89. package/dist/tools/prompts.js +378 -0
  90. package/dist/tools/prompts.js.map +1 -0
  91. package/dist/tools/publishing.d.ts +135 -0
  92. package/dist/tools/publishing.d.ts.map +1 -0
  93. package/dist/tools/publishing.js +209 -0
  94. package/dist/tools/publishing.js.map +1 -0
  95. package/dist/tools/reports.d.ts +252 -0
  96. package/dist/tools/reports.d.ts.map +1 -0
  97. package/dist/tools/reports.js +183 -0
  98. package/dist/tools/reports.js.map +1 -0
  99. package/dist/tools/social.d.ts +224 -0
  100. package/dist/tools/social.d.ts.map +1 -0
  101. package/dist/tools/social.js +291 -0
  102. package/dist/tools/social.js.map +1 -0
  103. package/dist/tools/sources.d.ts +221 -0
  104. package/dist/tools/sources.d.ts.map +1 -0
  105. package/dist/tools/sources.js +308 -0
  106. package/dist/tools/sources.js.map +1 -0
  107. package/dist/tools/strategy.d.ts +345 -0
  108. package/dist/tools/strategy.d.ts.map +1 -0
  109. package/dist/tools/strategy.js +392 -0
  110. package/dist/tools/strategy.js.map +1 -0
  111. package/dist/tools/usage.d.ts +101 -0
  112. package/dist/tools/usage.d.ts.map +1 -0
  113. package/dist/tools/usage.js +184 -0
  114. package/dist/tools/usage.js.map +1 -0
  115. package/dist/tools/visibility.d.ts +95 -0
  116. package/dist/tools/visibility.d.ts.map +1 -0
  117. package/dist/tools/visibility.js +163 -0
  118. package/dist/tools/visibility.js.map +1 -0
  119. package/package.json +54 -0
@@ -0,0 +1,226 @@
1
+ "use strict";
2
+ /**
3
+ * Audit Tools
4
+ *
5
+ * MCP tools for SEO audits and recommendations.
6
+ */
7
+ Object.defineProperty(exports, "__esModule", { value: true });
8
+ exports.auditTools = exports.getAuditRecommendationsSchema = exports.getAuditDetailsSchema = exports.listAuditsSchema = void 0;
9
+ exports.listAudits = listAudits;
10
+ exports.getAuditDetails = getAuditDetails;
11
+ exports.getAuditRecommendations = getAuditRecommendations;
12
+ const zod_1 = require("zod");
13
+ // Tool schemas
14
+ exports.listAuditsSchema = zod_1.z.object({
15
+ projectId: zod_1.z.string().optional().describe('Filter by project ID'),
16
+ limit: zod_1.z.number().optional().describe('Maximum number of audits to return (default: 10, max: 50)'),
17
+ status: zod_1.z.string().optional().describe('Filter by status (pending, processing, completed, failed)'),
18
+ });
19
+ exports.getAuditDetailsSchema = zod_1.z.object({
20
+ auditId: zod_1.z.string().describe('The ID of the audit to get details for'),
21
+ });
22
+ exports.getAuditRecommendationsSchema = zod_1.z.object({
23
+ auditId: zod_1.z.string().describe('The ID of the audit'),
24
+ category: zod_1.z.string().optional().describe('Filter by category (technical, content, performance, mobile, local)'),
25
+ impact: zod_1.z.string().optional().describe('Filter by impact level (critical, high, medium, low)'),
26
+ });
27
+ /**
28
+ * List audits tool handler
29
+ */
30
+ async function listAudits(client, args) {
31
+ const result = await client.listAudits({
32
+ projectId: args.projectId,
33
+ limit: args.limit,
34
+ status: args.status,
35
+ });
36
+ if (result.audits.length === 0) {
37
+ return 'No SEO audits found. Run an audit in the Reaudit dashboard to get started.';
38
+ }
39
+ let response = `## SEO Audits (${result.count} total)\n\n`;
40
+ for (const audit of result.audits) {
41
+ const statusEmoji = audit.status === 'completed' ? '✅' :
42
+ audit.status === 'processing' ? '⏳' :
43
+ audit.status === 'failed' ? '❌' : '⏸️';
44
+ response += `### ${statusEmoji} ${audit.domain}\n`;
45
+ response += `- **URL:** ${audit.url}\n`;
46
+ response += `- **Status:** ${audit.status}\n`;
47
+ if (audit.currentScore !== null) {
48
+ response += `- **Score:** ${audit.currentScore}/100`;
49
+ if (audit.potentialScore !== null && audit.potentialScore > audit.currentScore) {
50
+ response += ` (potential: ${audit.potentialScore})`;
51
+ }
52
+ response += '\n';
53
+ }
54
+ if (audit.pageTitle) {
55
+ response += `- **Title:** ${audit.pageTitle}\n`;
56
+ }
57
+ response += `- **ID:** ${audit.id}\n`;
58
+ response += `- **Date:** ${new Date(audit.createdAt).toLocaleDateString()}\n\n`;
59
+ }
60
+ return response;
61
+ }
62
+ /**
63
+ * Get audit details tool handler
64
+ */
65
+ async function getAuditDetails(client, args) {
66
+ const audit = await client.getAuditDetails(args.auditId);
67
+ if (audit.status !== 'completed') {
68
+ return `Audit is ${audit.status}. ${audit.status === 'processing' ? 'Please wait for it to complete.' : ''}`;
69
+ }
70
+ let response = `## SEO Audit: ${audit.domain}\n\n`;
71
+ response += `**URL:** ${audit.url}\n`;
72
+ response += `**Title:** ${audit.pageTitle}\n`;
73
+ response += `**Description:** ${audit.pageDescription}\n\n`;
74
+ response += `### Scores\n`;
75
+ response += `- **Current SEO Score:** ${audit.scores.current}/100\n`;
76
+ response += `- **Potential Score:** ${audit.scores.potential}/100\n`;
77
+ if (audit.scores.pageSpeed !== null) {
78
+ response += `- **Page Speed:** ${audit.scores.pageSpeed}/100\n`;
79
+ }
80
+ if (audit.scores.accessibility !== null) {
81
+ response += `- **Accessibility:** ${audit.scores.accessibility}/100\n`;
82
+ }
83
+ response += '\n';
84
+ response += `### Focus Keyphrase\n`;
85
+ response += `${audit.focusKeyphrase}\n\n`;
86
+ if (audit.recommendations.length > 0) {
87
+ response += `### Top Recommendations (${audit.recommendations.length} total)\n`;
88
+ const topRecs = audit.recommendations.slice(0, 5);
89
+ for (const rec of topRecs) {
90
+ const impactEmoji = rec.impact === 'critical' ? '🔴' :
91
+ rec.impact === 'high' ? '🟠' :
92
+ rec.impact === 'medium' ? '🟡' : '🟢';
93
+ response += `${impactEmoji} **${rec.title}** (${rec.category})\n`;
94
+ response += ` ${rec.description}\n\n`;
95
+ }
96
+ }
97
+ if (audit.technicalIssues.length > 0) {
98
+ response += `### Technical Issues (${audit.technicalIssues.length})\n`;
99
+ for (const issue of audit.technicalIssues.slice(0, 3)) {
100
+ response += `- **${issue.issue}**\n`;
101
+ response += ` Impact: ${issue.impact}\n`;
102
+ response += ` Solution: ${issue.solution}\n\n`;
103
+ }
104
+ }
105
+ if (audit.pageSpeed) {
106
+ response += `### Page Speed Metrics\n`;
107
+ response += `- FCP: ${audit.pageSpeed.fcp}\n`;
108
+ response += `- LCP: ${audit.pageSpeed.lcp}\n`;
109
+ response += `- TBT: ${audit.pageSpeed.tbt}\n`;
110
+ response += `- CLS: ${audit.pageSpeed.cls}\n\n`;
111
+ }
112
+ if (audit.contentQuality) {
113
+ response += `### Content Quality\n`;
114
+ response += `- Overall: ${audit.contentQuality.overall}/100\n`;
115
+ response += `- Clarity: ${audit.contentQuality.clarity}/100\n`;
116
+ response += `- Factuality: ${audit.contentQuality.factuality}/100\n`;
117
+ response += `- Answerability: ${audit.contentQuality.answerability}/100\n`;
118
+ }
119
+ return response;
120
+ }
121
+ /**
122
+ * Get audit recommendations tool handler
123
+ */
124
+ async function getAuditRecommendations(client, args) {
125
+ const result = await client.getAuditRecommendations(args.auditId, {
126
+ category: args.category,
127
+ impact: args.impact,
128
+ });
129
+ if (result.totalRecommendations === 0) {
130
+ return 'No recommendations found for this audit.';
131
+ }
132
+ let response = `## SEO Recommendations for ${result.url}\n`;
133
+ response += `**Current Score:** ${result.currentScore}/100\n`;
134
+ response += `**Total Recommendations:** ${result.totalRecommendations}\n\n`;
135
+ response += `### Summary\n`;
136
+ response += `- 🔴 Critical: ${result.summary.critical}\n`;
137
+ response += `- 🟠 High: ${result.summary.high}\n`;
138
+ response += `- 🟡 Medium: ${result.summary.medium}\n`;
139
+ response += `- 🟢 Low: ${result.summary.low}\n\n`;
140
+ const sections = [
141
+ { name: 'Critical', emoji: '🔴', items: result.byImpact.critical },
142
+ { name: 'High', emoji: '🟠', items: result.byImpact.high },
143
+ { name: 'Medium', emoji: '🟡', items: result.byImpact.medium },
144
+ { name: 'Low', emoji: '🟢', items: result.byImpact.low },
145
+ ];
146
+ for (const section of sections) {
147
+ if (section.items.length > 0) {
148
+ response += `### ${section.emoji} ${section.name} Priority\n\n`;
149
+ for (const rec of section.items) {
150
+ response += `**${rec.title}** (${rec.category})\n`;
151
+ response += `${rec.description}\n`;
152
+ response += `- Effort: ${rec.effort}\n`;
153
+ response += `- Time to Impact: ${rec.timeToImpact}\n`;
154
+ if (rec.implementation) {
155
+ response += `- Implementation: ${rec.implementation}\n`;
156
+ }
157
+ response += '\n';
158
+ }
159
+ }
160
+ }
161
+ return response;
162
+ }
163
+ /**
164
+ * Tool definitions for MCP
165
+ */
166
+ exports.auditTools = [
167
+ {
168
+ name: 'list_audits',
169
+ description: 'List SEO audits. Shows audit status, scores, and basic info for each audited page.',
170
+ inputSchema: {
171
+ type: 'object',
172
+ properties: {
173
+ projectId: {
174
+ type: 'string',
175
+ description: 'Filter by project ID',
176
+ },
177
+ limit: {
178
+ type: 'number',
179
+ description: 'Maximum number of audits to return (default: 10, max: 50)',
180
+ },
181
+ status: {
182
+ type: 'string',
183
+ description: 'Filter by status (pending, processing, completed, failed)',
184
+ },
185
+ },
186
+ required: [],
187
+ },
188
+ },
189
+ {
190
+ name: 'get_audit_details',
191
+ description: 'Get detailed results of a specific SEO audit including scores, recommendations, technical issues, and page speed metrics.',
192
+ inputSchema: {
193
+ type: 'object',
194
+ properties: {
195
+ auditId: {
196
+ type: 'string',
197
+ description: 'The ID of the audit to get details for',
198
+ },
199
+ },
200
+ required: ['auditId'],
201
+ },
202
+ },
203
+ {
204
+ name: 'get_audit_recommendations',
205
+ description: 'Get prioritized SEO recommendations from an audit, grouped by impact level (critical, high, medium, low).',
206
+ inputSchema: {
207
+ type: 'object',
208
+ properties: {
209
+ auditId: {
210
+ type: 'string',
211
+ description: 'The ID of the audit',
212
+ },
213
+ category: {
214
+ type: 'string',
215
+ description: 'Filter by category (technical, content, performance, mobile, local)',
216
+ },
217
+ impact: {
218
+ type: 'string',
219
+ description: 'Filter by impact level (critical, high, medium, low)',
220
+ },
221
+ },
222
+ required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IAAI,EAAE,QAAQ;oBACd,WAAW,EAAE,qEAAqE;iBACnF;gBACD,MAAM,EAAE;oBACN,IAAI,EAAE,QAAQ;oBACd,WAAW,EAAE,sDAAsD;iBACpE;aACF;YACD,QAAQ,EAAE,CAAC,SAAS,CAAC;SACtB;KACF;CACF,CAAC"}
@@ -0,0 +1,57 @@
1
+ /**
2
+ * Calendar Tools
3
+ *
4
+ * MCP tools for content calendar management.
5
+ */
6
+ import { z } from 'zod';
7
+ import { ReauditAPIClient } from '../lib/api-client.js';
8
+ export declare const getContentCalendarSchema: z.ZodObject<{
9
+ projectId: z.ZodOptional<z.ZodString>;
10
+ startDate: z.ZodOptional<z.ZodString>;
11
+ endDate: z.ZodOptional<z.ZodString>;
12
+ limit: z.ZodOptional<z.ZodNumber>;
13
+ }, "strip", z.ZodTypeAny, {
14
+ projectId?: string | undefined;
15
+ limit?: number | undefined;
16
+ startDate?: string | undefined;
17
+ endDate?: string | undefined;
18
+ }, {
19
+ projectId?: string | undefined;
20
+ limit?: number | undefined;
21
+ startDate?: string | undefined;
22
+ endDate?: string | undefined;
23
+ }>;
24
+ /**
25
+ * Get content calendar tool handler
26
+ */
27
+ export declare function getContentCalendar(client: ReauditAPIClient, args: z.infer<typeof getContentCalendarSchema>): Promise<string>;
28
+ /**
29
+ * Tool definitions for MCP
30
+ */
31
+ export declare const calendarTools: {
32
+ name: string;
33
+ description: string;
34
+ inputSchema: {
35
+ type: "object";
36
+ properties: {
37
+ projectId: {
38
+ type: string;
39
+ description: string;
40
+ };
41
+ startDate: {
42
+ type: string;
43
+ description: string;
44
+ };
45
+ endDate: {
46
+ type: string;
47
+ description: string;
48
+ };
49
+ limit: {
50
+ type: string;
51
+ description: string;
52
+ };
53
+ };
54
+ required: string[];
55
+ };
56
+ }[];
57
+ //# sourceMappingURL=calendar.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"calendar.d.ts","sourceRoot":"","sources":["../../src/tools/calendar.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AAGxD,eAAO,MAAM,wBAAwB;;;;;;;;;;;;;;;EAKnC,CAAC;AAEH;;GAEG;AACH,wBAAsB,kBAAkB,CACtC,MAAM,EAAE,gBAAgB,EACxB,IAAI,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,GAC7C,OAAO,CAAC,MAAM,CAAC,CA8DjB;AAED;;GAEG;AACH,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;kBAwBJ,MAAM,EAAE;;GAG7B,CAAC"}
@@ -0,0 +1,109 @@
1
+ "use strict";
2
+ /**
3
+ * Calendar Tools
4
+ *
5
+ * MCP tools for content calendar management.
6
+ */
7
+ Object.defineProperty(exports, "__esModule", { value: true });
8
+ exports.calendarTools = exports.getContentCalendarSchema = void 0;
9
+ exports.getContentCalendar = getContentCalendar;
10
+ const zod_1 = require("zod");
11
+ // Tool schemas
12
+ exports.getContentCalendarSchema = zod_1.z.object({
13
+ projectId: zod_1.z.string().optional().describe('Filter by project ID'),
14
+ startDate: zod_1.z.string().optional().describe('Start date for filtering (ISO format)'),
15
+ endDate: zod_1.z.string().optional().describe('End date for filtering (ISO format)'),
16
+ limit: zod_1.z.number().optional().describe('Maximum number of events to return (default: 50)'),
17
+ });
18
+ /**
19
+ * Get content calendar tool handler
20
+ */
21
+ async function getContentCalendar(client, args) {
22
+ const result = await client.getContentCalendar({
23
+ projectId: args.projectId,
24
+ startDate: args.startDate,
25
+ endDate: args.endDate,
26
+ limit: args.limit,
27
+ });
28
+ if (result.events.length === 0) {
29
+ return 'No content calendar events found. Schedule content or create a GTM strategy to populate your calendar.';
30
+ }
31
+ let response = `## Content Calendar\n\n`;
32
+ response += `### Summary\n`;
33
+ response += `- **Total Events:** ${result.stats.total}\n`;
34
+ response += `- **Social Media:** ${result.stats.socialMedia}\n`;
35
+ response += `- **WordPress:** ${result.stats.wordpress}\n`;
36
+ response += `- **Blog:** ${result.stats.blog}\n`;
37
+ response += `- **Strategy Planned:** ${result.stats.strategyPlanned}\n\n`;
38
+ response += `### Status Breakdown\n`;
39
+ response += `- Planned: ${result.stats.planned}\n`;
40
+ response += `- Scheduled: ${result.stats.scheduled}\n`;
41
+ response += `- Published: ${result.stats.published}\n\n`;
42
+ response += `### Events (${result.events.length})\n\n`;
43
+ // Group events by date
44
+ const eventsByDate = new Map();
45
+ for (const event of result.events) {
46
+ const dateKey = new Date(event.date).toLocaleDateString('en-US', {
47
+ weekday: 'short',
48
+ month: 'short',
49
+ day: 'numeric',
50
+ });
51
+ if (!eventsByDate.has(dateKey)) {
52
+ eventsByDate.set(dateKey, []);
53
+ }
54
+ eventsByDate.get(dateKey).push(event);
55
+ }
56
+ for (const [date, events] of eventsByDate) {
57
+ response += `#### ${date}\n`;
58
+ for (const event of events) {
59
+ const statusEmoji = event.status === 'published' ? '✅' :
60
+ event.status === 'scheduled' ? '📅' :
61
+ event.status === 'draft' ? '📝' : '📋';
62
+ response += `- ${statusEmoji} **${event.title}**\n`;
63
+ response += ` - Type: ${event.type} | Platform: ${event.platform} | Status: ${event.status}\n`;
64
+ if (event.strategyName) {
65
+ response += ` - Strategy: ${event.strategyName}`;
66
+ if (event.weekNumber)
67
+ response += ` (Week ${event.weekNumber})`;
68
+ response += '\n';
69
+ }
70
+ if (event.url) {
71
+ response += ` - URL: ${event.url}\n`;
72
+ }
73
+ }
74
+ response += '\n';
75
+ }
76
+ return response;
77
+ }
78
+ /**
79
+ * Tool definitions for MCP
80
+ */
81
+ exports.calendarTools = [
82
+ {
83
+ name: 'get_content_calendar',
84
+ description: 'Get your content calendar showing all scheduled, planned, and published content across social media, WordPress, blog, and GTM strategy items. Filter by project, date range, or limit results.',
85
+ inputSchema: {
86
+ type: 'object',
87
+ properties: {
88
+ projectId: {
89
+ type: 'string',
90
+ description: 'Filter by project ID (optional)',
91
+ },
92
+ startDate: {
93
+ type: 'string',
94
+ description: 'Start date for filtering in ISO format (e.g., 2024-01-01)',
95
+ },
96
+ endDate: {
97
+ type: 'string',
98
+ description: 'End date for filtering in ISO format (e.g., 2024-12-31)',
99
+ },
100
+ limit: {
101
+ type: 'number',
102
+ description: 'Maximum number of events to return (default: 50)',
103
+ },
104
+ },
105
+ required: [],
106
+ },
107
+ },
108
+ ];
109
+ //# sourceMappingURL=calendar.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"calendar.js","sourceRoot":"","sources":["../../src/tools/calendar.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;;AAgBH,gDAiEC;AA/ED,6BAAwB;AAGxB,eAAe;AACF,QAAA,wBAAwB,GAAG,OAAC,CAAC,MAAM,CAAC;IAC/C,SAAS,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,sBAAsB,CAAC;IACjE,SAAS,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,uCAAuC,CAAC;IAClF,OAAO,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,qCAAqC,CAAC;IAC9E,KAAK,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,kDAAkD,CAAC;CAC1F,CAAC,CAAC;AAEH;;GAEG;AACI,KAAK,UAAU,kBAAkB,CACtC,MAAwB,EACxB,IAA8C;IAE9C,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,kBAAkB,CAAC;QAC7C,SAAS,EAAE,IAAI,CAAC,SAAS;QACzB,SAAS,EAAE,IAAI,CAAC,SAAS;QACzB,OAAO,EAAE,IAAI,CAAC,OAAO;QACrB,KAAK,EAAE,IAAI,CAAC,KAAK;KAClB,CAAC,CAAC;IAEH,IAAI,MAAM,CAAC,MAAM,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;Q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EAAE,QAAiB;YACvB,UAAU,EAAE;gBACV,SAAS,EAAE;oBACT,IAAI,EAAE,QAAQ;oBACd,WAAW,EAAE,iCAAiC;iBAC/C;gBACD,SAAS,EAAE;oBACT,IAAI,EAAE,QAAQ;oBACd,WAAW,EAAE,2DAA2D;iBACzE;gBACD,OAAO,EAAE;oBACP,IAAI,EAAE,QAAQ;oBACd,WAAW,EAAE,yDAAyD;iBACvE;gBACD,KAAK,EAAE;oBACL,IAAI,EAAE,QAAQ;oBACd,WAAW,EAAE,kDAAkD;iBAChE;aACF;YACD,QAAQ,EAAE,EAAc;SACzB;KACF;CACF,CAAC"}
@@ -0,0 +1,211 @@
1
+ /**
2
+ * Content Generation Tools
3
+ *
4
+ * MCP tools for AI content generation.
5
+ */
6
+ import { z } from 'zod';
7
+ import { ReauditAPIClient } from '../lib/api-client.js';
8
+ export declare const generateContentSchema: z.ZodObject<{
9
+ keyword: z.ZodString;
10
+ topic: z.ZodString;
11
+ contentType: z.ZodOptional<z.ZodString>;
12
+ contentLength: z.ZodOptional<z.ZodEnum<["short", "medium", "long", "comprehensive"]>>;
13
+ tone: z.ZodOptional<z.ZodString>;
14
+ customTone: z.ZodOptional<z.ZodString>;
15
+ useProjectTone: z.ZodOptional<z.ZodBoolean>;
16
+ additionalContext: z.ZodOptional<z.ZodString>;
17
+ projectId: z.ZodOptional<z.ZodString>;
18
+ language: z.ZodOptional<z.ZodString>;
19
+ useSemanticVariants: z.ZodOptional<z.ZodBoolean>;
20
+ useWebSearch: z.ZodOptional<z.ZodBoolean>;
21
+ }, "strip", z.ZodTypeAny, {
22
+ topic: string;
23
+ keyword: string;
24
+ projectId?: string | undefined;
25
+ contentType?: string | undefined;
26
+ contentLength?: "short" | "medium" | "long" | "comprehensive" | undefined;
27
+ tone?: string | undefined;
28
+ customTone?: string | undefined;
29
+ useProjectTone?: boolean | undefined;
30
+ additionalContext?: string | undefined;
31
+ language?: string | undefined;
32
+ useSemanticVariants?: boolean | undefined;
33
+ useWebSearch?: boolean | undefined;
34
+ }, {
35
+ topic: string;
36
+ keyword: string;
37
+ projectId?: string | undefined;
38
+ contentType?: string | undefined;
39
+ contentLength?: "short" | "medium" | "long" | "comprehensive" | undefined;
40
+ tone?: string | undefined;
41
+ customTone?: string | undefined;
42
+ useProjectTone?: boolean | undefined;
43
+ additionalContext?: string | undefined;
44
+ language?: string | undefined;
45
+ useSemanticVariants?: boolean | undefined;
46
+ useWebSearch?: boolean | undefined;
47
+ }>;
48
+ export declare const getContentHistorySchema: z.ZodObject<{
49
+ projectId: z.ZodOptional<z.ZodString>;
50
+ contentType: z.ZodOptional<z.ZodString>;
51
+ limit: z.ZodOptional<z.ZodNumber>;
52
+ }, "strip", z.ZodTypeAny, {
53
+ projectId?: string | undefined;
54
+ limit?: number | undefined;
55
+ contentType?: string | undefined;
56
+ }, {
57
+ projectId?: string | undefined;
58
+ limit?: number | undefined;
59
+ contentType?: string | undefined;
60
+ }>;
61
+ export declare const getContentDetailsSchema: z.ZodObject<{
62
+ contentId: z.ZodString;
63
+ includeSchema: z.ZodOptional<z.ZodBoolean>;
64
+ }, "strip", z.ZodTypeAny, {
65
+ contentId: string;
66
+ includeSchema?: boolean | undefined;
67
+ }, {
68
+ contentId: string;
69
+ includeSchema?: boolean | undefined;
70
+ }>;
71
+ /**
72
+ * Generate content tool handler
73
+ */
74
+ export declare function generateContent(client: ReauditAPIClient, args: z.infer<typeof generateContentSchema>): Promise<string>;
75
+ /**
76
+ * Get content history tool handler
77
+ */
78
+ export declare function getContentHistory(client: ReauditAPIClient, args: z.infer<typeof getContentHistorySchema>): Promise<string>;
79
+ /**
80
+ * Get content details tool handler
81
+ */
82
+ export declare function getContentDetails(client: ReauditAPIClient, args: z.infer<typeof getContentDetailsSchema>): Promise<string>;
83
+ /**
84
+ * Tool definitions for MCP
85
+ */
86
+ export declare const contentGenerationTools: ({
87
+ name: string;
88
+ description: string;
89
+ inputSchema: {
90
+ type: "object";
91
+ properties: {
92
+ keyword: {
93
+ type: string;
94
+ description: string;
95
+ };
96
+ topic: {
97
+ type: string;
98
+ description: string;
99
+ };
100
+ contentType: {
101
+ type: string;
102
+ description: string;
103
+ };
104
+ contentLength: {
105
+ type: string;
106
+ enum: string[];
107
+ description: string;
108
+ };
109
+ tone: {
110
+ type: string;
111
+ description: string;
112
+ };
113
+ customTone: {
114
+ type: string;
115
+ description: string;
116
+ };
117
+ useProjectTone: {
118
+ type: string;
119
+ description: string;
120
+ };
121
+ additionalContext: {
122
+ type: string;
123
+ description: string;
124
+ };
125
+ projectId: {
126
+ type: string;
127
+ description: string;
128
+ };
129
+ language: {
130
+ type: string;
131
+ description: string;
132
+ };
133
+ useSemanticVariants: {
134
+ type: string;
135
+ description: string;
136
+ };
137
+ useWebSearch: {
138
+ type: string;
139
+ description: string;
140
+ };
141
+ limit?: undefined;
142
+ contentId?: undefined;
143
+ includeSchema?: undefined;
144
+ };
145
+ required: string[];
146
+ };
147
+ } | {
148
+ name: string;
149
+ description: string;
150
+ inputSchema: {
151
+ type: "object";
152
+ properties: {
153
+ projectId: {
154
+ type: string;
155
+ description: string;
156
+ };
157
+ contentType: {
158
+ type: string;
159
+ description: string;
160
+ };
161
+ limit: {
162
+ type: string;
163
+ description: string;
164
+ };
165
+ keyword?: undefined;
166
+ topic?: undefined;
167
+ contentLength?: undefined;
168
+ tone?: undefined;
169
+ customTone?: undefined;
170
+ useProjectTone?: undefined;
171
+ additionalContext?: undefined;
172
+ language?: undefined;
173
+ useSemanticVariants?: undefined;
174
+ useWebSearch?: undefined;
175
+ contentId?: undefined;
176
+ includeSchema?: undefined;
177
+ };
178
+ required: string[];
179
+ };
180
+ } | {
181
+ name: string;
182
+ description: string;
183
+ inputSchema: {
184
+ type: "object";
185
+ properties: {
186
+ contentId: {
187
+ type: string;
188
+ description: string;
189
+ };
190
+ includeSchema: {
191
+ type: string;
192
+ description: string;
193
+ };
194
+ keyword?: undefined;
195
+ topic?: undefined;
196
+ contentType?: undefined;
197
+ contentLength?: undefined;
198
+ tone?: undefined;
199
+ customTone?: undefined;
200
+ useProjectTone?: undefined;
201
+ additionalContext?: undefined;
202
+ projectId?: undefined;
203
+ language?: undefined;
204
+ useSemanticVariants?: undefined;
205
+ useWebSearch?: undefined;
206
+ limit?: undefined;
207
+ };
208
+ required: string[];
209
+ };
210
+ })[];
211
+ //# sourceMappingURL=content-generation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"content-generation.d.ts","sourceRoot":"","sources":["../../src/tools/content-generation.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AAGxD,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAahC,CAAC;AAEH,eAAO,MAAM,uBAAuB;;;;;;;;;;;;EAIlC,CAAC;AAEH,eAAO,MAAM,uBAAuB;;;;;;;;;EAGlC,CAAC;AAEH;;GAEG;AACH,wBAAsB,eAAe,CACnC,MAAM,EAAE,gBAAgB,EACxB,IAAI,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,GAC1C,OAAO,CAAC,MAAM,CAAC,CA8FjB;AAED;;GAEG;AACH,wBAAsB,iBAAiB,CACrC,MAAM,EAAE,gBAAgB,EACxB,IAAI,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,GAC5C,OAAO,CAAC,MAAM,CAAC,CA4BjB;AAED;;GAEG;AACH,wBAAsB,iBAAiB,CACrC,MAAM,EAAE,gBAAgB,EACxB,IAAI,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,GAC5C,OAAO,CAAC,MAAM,CAAC,CAwGjB;AAED;;GAEG;AACH,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;kBA+Eb,MAAM,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAqB7B,CAAC"}