@fruition/fcp-mcp-server 1.6.2 → 1.8.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/README.md +1 -1
- package/bin/unroo-heartbeat.sh +2 -2
- package/dist/index.js +576 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -234,4 +234,4 @@ The system learns from this and saves the mapping permanently, so you only need
|
|
|
234
234
|
|
|
235
235
|
### Viewing Time
|
|
236
236
|
|
|
237
|
-
Log in to [Unroo](https://
|
|
237
|
+
Log in to [Unroo](https://app.unroo.io) and check My Day or Timesheet to see your tracked sessions.
|
package/bin/unroo-heartbeat.sh
CHANGED
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
#
|
|
16
16
|
# Environment variables:
|
|
17
17
|
# UNROO_API_KEY - Required: Your UnRoo API key with time tracking enabled
|
|
18
|
-
# UNROO_API_ENDPOINT - Optional: API base URL (default: https://
|
|
18
|
+
# UNROO_API_ENDPOINT - Optional: API base URL (default: https://app.unroo.io)
|
|
19
19
|
# TOOL_NAME - Optional: Name of the tool that was used
|
|
20
20
|
# TOOL_DESCRIPTION - Optional: Description of what the tool did
|
|
21
21
|
#
|
|
@@ -31,7 +31,7 @@
|
|
|
31
31
|
|
|
32
32
|
# Configuration
|
|
33
33
|
EVENT_TYPE="${1:-tool_end}"
|
|
34
|
-
API_ENDPOINT="${UNROO_API_ENDPOINT:-https://
|
|
34
|
+
API_ENDPOINT="${UNROO_API_ENDPOINT:-https://app.unroo.io}"
|
|
35
35
|
API_URL="${API_ENDPOINT}/api/unroo/claude-tracker/heartbeat"
|
|
36
36
|
|
|
37
37
|
# Check for API key
|
package/dist/index.js
CHANGED
|
@@ -39,7 +39,7 @@ const FCP_API_URL = process.env.FCP_API_URL || 'https://fcp.fru.io';
|
|
|
39
39
|
const FCP_API_TOKEN = process.env.FCP_API_TOKEN || '';
|
|
40
40
|
// Unroo API can be called directly (legacy) or proxied through FCP (recommended)
|
|
41
41
|
// When UNROO_API_KEY is not set, Unroo calls go through FCP's proxy at /api/mcp/unroo/*
|
|
42
|
-
const UNROO_API_URL = process.env.UNROO_API_URL || 'https://
|
|
42
|
+
const UNROO_API_URL = process.env.UNROO_API_URL || 'https://app.unroo.io';
|
|
43
43
|
const UNROO_API_KEY = process.env.UNROO_API_KEY || '';
|
|
44
44
|
// If no Unroo key, use FCP as proxy (unified key setup)
|
|
45
45
|
const USE_FCP_UNROO_PROXY = !UNROO_API_KEY;
|
|
@@ -329,6 +329,110 @@ class FCPClient {
|
|
|
329
329
|
body: JSON.stringify(options || {}),
|
|
330
330
|
});
|
|
331
331
|
}
|
|
332
|
+
// Shield Domain Management
|
|
333
|
+
async shieldListDomains(filters) {
|
|
334
|
+
const params = new URLSearchParams();
|
|
335
|
+
if (filters?.status)
|
|
336
|
+
params.append('status', filters.status);
|
|
337
|
+
if (filters?.account_id)
|
|
338
|
+
params.append('account_id', String(filters.account_id));
|
|
339
|
+
const qs = params.toString();
|
|
340
|
+
return this.fetch(`/api/shield/domains${qs ? `?${qs}` : ''}`);
|
|
341
|
+
}
|
|
342
|
+
async shieldAddDomain(input) {
|
|
343
|
+
return this.fetch('/api/shield/domains', {
|
|
344
|
+
method: 'POST',
|
|
345
|
+
body: JSON.stringify(input),
|
|
346
|
+
});
|
|
347
|
+
}
|
|
348
|
+
async shieldGetDomain(domainId) {
|
|
349
|
+
return this.fetch(`/api/shield/domains/${domainId}`);
|
|
350
|
+
}
|
|
351
|
+
async shieldUpdateDomain(domainId, updates) {
|
|
352
|
+
return this.fetch(`/api/shield/domains/${domainId}`, {
|
|
353
|
+
method: 'PUT',
|
|
354
|
+
body: JSON.stringify(updates),
|
|
355
|
+
});
|
|
356
|
+
}
|
|
357
|
+
async shieldRemoveDomain(domainId) {
|
|
358
|
+
return this.fetch(`/api/shield/domains/${domainId}`, {
|
|
359
|
+
method: 'DELETE',
|
|
360
|
+
});
|
|
361
|
+
}
|
|
362
|
+
async shieldGetMetrics() {
|
|
363
|
+
return this.fetch('/api/shield/metrics?include_health=true');
|
|
364
|
+
}
|
|
365
|
+
async shieldVerifyDomain(domainId) {
|
|
366
|
+
return this.fetch(`/api/shield/domains/${domainId}/verify`, {
|
|
367
|
+
method: 'POST',
|
|
368
|
+
});
|
|
369
|
+
}
|
|
370
|
+
// ============================================================================
|
|
371
|
+
// Backup Management Methods
|
|
372
|
+
// ============================================================================
|
|
373
|
+
async backupListSites() {
|
|
374
|
+
return this.fetch('/api/backup/sites');
|
|
375
|
+
}
|
|
376
|
+
async backupGetConfig() {
|
|
377
|
+
return this.fetch('/api/backup/config');
|
|
378
|
+
}
|
|
379
|
+
async backupListEligible() {
|
|
380
|
+
return this.fetch('/api/backup/eligible');
|
|
381
|
+
}
|
|
382
|
+
async backupEnable(siteId) {
|
|
383
|
+
return this.fetch('/api/backup/enable', {
|
|
384
|
+
method: 'POST',
|
|
385
|
+
body: JSON.stringify({ siteId }),
|
|
386
|
+
});
|
|
387
|
+
}
|
|
388
|
+
async backupTrigger(websiteId, triggerType) {
|
|
389
|
+
return this.fetch('/api/backup/trigger', {
|
|
390
|
+
method: 'POST',
|
|
391
|
+
body: JSON.stringify({ websiteId, triggerType }),
|
|
392
|
+
});
|
|
393
|
+
}
|
|
394
|
+
async backupCheckTrigger(websiteId) {
|
|
395
|
+
return this.fetch(`/api/backup/trigger?websiteId=${websiteId}`);
|
|
396
|
+
}
|
|
397
|
+
async backupListBackups(siteId) {
|
|
398
|
+
return this.fetch(`/api/backup/list?siteId=${encodeURIComponent(siteId)}`);
|
|
399
|
+
}
|
|
400
|
+
async backupGetStatus(options) {
|
|
401
|
+
const params = new URLSearchParams();
|
|
402
|
+
if (options.backupId)
|
|
403
|
+
params.set('backupId', options.backupId);
|
|
404
|
+
if (options.websiteId)
|
|
405
|
+
params.set('websiteId', options.websiteId.toString());
|
|
406
|
+
const query = params.toString();
|
|
407
|
+
return this.fetch(`/api/backup/status${query ? `?${query}` : ''}`);
|
|
408
|
+
}
|
|
409
|
+
async backupDownload(backupId) {
|
|
410
|
+
return this.fetch(`/api/backup/download?backupId=${encodeURIComponent(backupId)}`);
|
|
411
|
+
}
|
|
412
|
+
async backupDownloadPrepared(input) {
|
|
413
|
+
return this.fetch('/api/backup/download', {
|
|
414
|
+
method: 'POST',
|
|
415
|
+
body: JSON.stringify(input),
|
|
416
|
+
});
|
|
417
|
+
}
|
|
418
|
+
async backupListPairings(siteId) {
|
|
419
|
+
const params = new URLSearchParams();
|
|
420
|
+
if (siteId)
|
|
421
|
+
params.set('siteId', siteId.toString());
|
|
422
|
+
const query = params.toString();
|
|
423
|
+
return this.fetch(`/api/backup/pairing${query ? `?${query}` : ''}`);
|
|
424
|
+
}
|
|
425
|
+
async backupUpdatePairing(siteId, pairingConfig) {
|
|
426
|
+
return this.fetch('/api/backup/pairing', {
|
|
427
|
+
method: 'POST',
|
|
428
|
+
body: JSON.stringify({ siteId, pairingConfig }),
|
|
429
|
+
});
|
|
430
|
+
}
|
|
431
|
+
async backupDeletePairing(siteId) {
|
|
432
|
+
return this.fetch(`/api/backup/pairing?siteId=${siteId}`, {
|
|
433
|
+
method: 'DELETE',
|
|
434
|
+
});
|
|
435
|
+
}
|
|
332
436
|
}
|
|
333
437
|
// Unroo API Client
|
|
334
438
|
// Supports two modes:
|
|
@@ -1061,6 +1165,14 @@ const TOOLS = [
|
|
|
1061
1165
|
type: 'number',
|
|
1062
1166
|
description: 'The ID of the launch to update (required)',
|
|
1063
1167
|
},
|
|
1168
|
+
website_id: {
|
|
1169
|
+
type: 'number',
|
|
1170
|
+
description: 'Associated website ID (null to unlink)',
|
|
1171
|
+
},
|
|
1172
|
+
account_id: {
|
|
1173
|
+
type: 'number',
|
|
1174
|
+
description: 'Associated account/client ID (null to unlink)',
|
|
1175
|
+
},
|
|
1064
1176
|
name: {
|
|
1065
1177
|
type: 'string',
|
|
1066
1178
|
description: 'Updated launch name',
|
|
@@ -1909,6 +2021,10 @@ const TOOLS = [
|
|
|
1909
2021
|
type: 'string',
|
|
1910
2022
|
description: 'Updated backup cron schedule',
|
|
1911
2023
|
},
|
|
2024
|
+
multisite_root_id: {
|
|
2025
|
+
type: 'number',
|
|
2026
|
+
description: 'Root site ID for WordPress multisite networks. Set to link as a subsite, null to unlink.',
|
|
2027
|
+
},
|
|
1912
2028
|
},
|
|
1913
2029
|
required: ['website_id'],
|
|
1914
2030
|
},
|
|
@@ -1935,6 +2051,330 @@ const TOOLS = [
|
|
|
1935
2051
|
required: ['website_id'],
|
|
1936
2052
|
},
|
|
1937
2053
|
},
|
|
2054
|
+
// Fruition Shield - Shared WAF Gateway
|
|
2055
|
+
{
|
|
2056
|
+
name: 'fcp_shield_list_domains',
|
|
2057
|
+
description: 'List all domains protected by Fruition Shield WAF. Filter by status (pending_dns, pending_cert, active, suspended) or account_id.',
|
|
2058
|
+
inputSchema: {
|
|
2059
|
+
type: 'object',
|
|
2060
|
+
properties: {
|
|
2061
|
+
status: {
|
|
2062
|
+
type: 'string',
|
|
2063
|
+
description: 'Filter by status: pending_dns, pending_cert, cert_validating, active, suspended, removed',
|
|
2064
|
+
},
|
|
2065
|
+
account_id: {
|
|
2066
|
+
type: 'number',
|
|
2067
|
+
description: 'Filter by account/client ID',
|
|
2068
|
+
},
|
|
2069
|
+
},
|
|
2070
|
+
},
|
|
2071
|
+
},
|
|
2072
|
+
{
|
|
2073
|
+
name: 'fcp_shield_add_domain',
|
|
2074
|
+
description: 'Add a domain to Fruition Shield WAF protection. Returns DNS records (traffic CNAME + cert validation CNAME) that must be added at the registrar.',
|
|
2075
|
+
inputSchema: {
|
|
2076
|
+
type: 'object',
|
|
2077
|
+
properties: {
|
|
2078
|
+
domain: {
|
|
2079
|
+
type: 'string',
|
|
2080
|
+
description: 'Domain to protect (e.g., www.butterflies.org)',
|
|
2081
|
+
},
|
|
2082
|
+
origin_host: {
|
|
2083
|
+
type: 'string',
|
|
2084
|
+
description: 'Origin server IP or hostname (e.g., 146.190.2.169 for K8s prod)',
|
|
2085
|
+
},
|
|
2086
|
+
origin_port: {
|
|
2087
|
+
type: 'number',
|
|
2088
|
+
description: 'Origin port (default: 443)',
|
|
2089
|
+
},
|
|
2090
|
+
origin_protocol: {
|
|
2091
|
+
type: 'string',
|
|
2092
|
+
description: 'Origin protocol: http or https (default: https)',
|
|
2093
|
+
},
|
|
2094
|
+
website_id: {
|
|
2095
|
+
type: 'number',
|
|
2096
|
+
description: 'Link to existing FCP website ID',
|
|
2097
|
+
},
|
|
2098
|
+
account_id: {
|
|
2099
|
+
type: 'number',
|
|
2100
|
+
description: 'Associated account/client ID',
|
|
2101
|
+
},
|
|
2102
|
+
cache_profile: {
|
|
2103
|
+
type: 'string',
|
|
2104
|
+
description: 'Cache profile: standard, aggressive, minimal, none (default: standard)',
|
|
2105
|
+
},
|
|
2106
|
+
notes: {
|
|
2107
|
+
type: 'string',
|
|
2108
|
+
description: 'Notes about this domain',
|
|
2109
|
+
},
|
|
2110
|
+
},
|
|
2111
|
+
required: ['domain', 'origin_host'],
|
|
2112
|
+
},
|
|
2113
|
+
},
|
|
2114
|
+
{
|
|
2115
|
+
name: 'fcp_shield_get_domain',
|
|
2116
|
+
description: 'Get Shield domain details including onboarding status, DNS records needed, and WAF configuration.',
|
|
2117
|
+
inputSchema: {
|
|
2118
|
+
type: 'object',
|
|
2119
|
+
properties: {
|
|
2120
|
+
domain_id: {
|
|
2121
|
+
type: 'number',
|
|
2122
|
+
description: 'The Shield domain ID',
|
|
2123
|
+
},
|
|
2124
|
+
},
|
|
2125
|
+
required: ['domain_id'],
|
|
2126
|
+
},
|
|
2127
|
+
},
|
|
2128
|
+
{
|
|
2129
|
+
name: 'fcp_shield_update_domain',
|
|
2130
|
+
description: 'Update Shield domain configuration (origin, cache profile, WAF rules, geo-blocking, rate limiting).',
|
|
2131
|
+
inputSchema: {
|
|
2132
|
+
type: 'object',
|
|
2133
|
+
properties: {
|
|
2134
|
+
domain_id: {
|
|
2135
|
+
type: 'number',
|
|
2136
|
+
description: 'The Shield domain ID',
|
|
2137
|
+
},
|
|
2138
|
+
origin_host: { type: 'string', description: 'Updated origin host' },
|
|
2139
|
+
origin_port: { type: 'number', description: 'Updated origin port' },
|
|
2140
|
+
cache_profile: { type: 'string', description: 'Cache profile: standard, aggressive, minimal, none' },
|
|
2141
|
+
waf_profile: { type: 'string', description: 'WAF profile: standard, premium, custom' },
|
|
2142
|
+
geo_block_countries: {
|
|
2143
|
+
type: 'array',
|
|
2144
|
+
items: { type: 'string' },
|
|
2145
|
+
description: 'Country codes to block (e.g., ["CN","RU","KP","IR","BY"])',
|
|
2146
|
+
},
|
|
2147
|
+
rate_limit_tier: { type: 'string', description: 'Rate limit: standard, strict, relaxed' },
|
|
2148
|
+
bot_control_enabled: { type: 'boolean', description: 'Enable AWS Bot Control (+$10/mo)' },
|
|
2149
|
+
enabled: { type: 'boolean', description: 'Enable/disable domain' },
|
|
2150
|
+
notes: { type: 'string', description: 'Updated notes' },
|
|
2151
|
+
},
|
|
2152
|
+
required: ['domain_id'],
|
|
2153
|
+
},
|
|
2154
|
+
},
|
|
2155
|
+
{
|
|
2156
|
+
name: 'fcp_shield_remove_domain',
|
|
2157
|
+
description: 'Remove a domain from Fruition Shield protection. Removes from CloudFront, DynamoDB, and deletes ACM certificate.',
|
|
2158
|
+
inputSchema: {
|
|
2159
|
+
type: 'object',
|
|
2160
|
+
properties: {
|
|
2161
|
+
domain_id: {
|
|
2162
|
+
type: 'number',
|
|
2163
|
+
description: 'The Shield domain ID to remove',
|
|
2164
|
+
},
|
|
2165
|
+
},
|
|
2166
|
+
required: ['domain_id'],
|
|
2167
|
+
},
|
|
2168
|
+
},
|
|
2169
|
+
{
|
|
2170
|
+
name: 'fcp_shield_get_metrics',
|
|
2171
|
+
description: 'Get aggregate Fruition Shield WAF metrics: total domains, requests, blocks, block rate, and infrastructure health.',
|
|
2172
|
+
inputSchema: {
|
|
2173
|
+
type: 'object',
|
|
2174
|
+
properties: {},
|
|
2175
|
+
},
|
|
2176
|
+
},
|
|
2177
|
+
// ============================================================================
|
|
2178
|
+
// Backup Management Tools
|
|
2179
|
+
// ============================================================================
|
|
2180
|
+
{
|
|
2181
|
+
name: 'fcp_backup_list_sites',
|
|
2182
|
+
description: 'List websites with backups enabled. Returns site details including domain, cluster, namespace, and backup schedule.',
|
|
2183
|
+
inputSchema: {
|
|
2184
|
+
type: 'object',
|
|
2185
|
+
properties: {},
|
|
2186
|
+
},
|
|
2187
|
+
},
|
|
2188
|
+
{
|
|
2189
|
+
name: 'fcp_backup_get_config',
|
|
2190
|
+
description: 'Get S3 backup configuration. Admin only. Returns bucket, region, endpoint info (credentials are excluded).',
|
|
2191
|
+
inputSchema: {
|
|
2192
|
+
type: 'object',
|
|
2193
|
+
properties: {},
|
|
2194
|
+
},
|
|
2195
|
+
},
|
|
2196
|
+
{
|
|
2197
|
+
name: 'fcp_backup_list_eligible',
|
|
2198
|
+
description: 'List sites eligible for backup but not yet enabled. Returns sites grouped by environment (production, staging, development).',
|
|
2199
|
+
inputSchema: {
|
|
2200
|
+
type: 'object',
|
|
2201
|
+
properties: {},
|
|
2202
|
+
},
|
|
2203
|
+
},
|
|
2204
|
+
{
|
|
2205
|
+
name: 'fcp_backup_enable',
|
|
2206
|
+
description: 'Enable backup for a site and trigger the first backup automatically.',
|
|
2207
|
+
inputSchema: {
|
|
2208
|
+
type: 'object',
|
|
2209
|
+
properties: {
|
|
2210
|
+
siteId: {
|
|
2211
|
+
type: 'number',
|
|
2212
|
+
description: 'The website ID to enable backups for',
|
|
2213
|
+
},
|
|
2214
|
+
},
|
|
2215
|
+
required: ['siteId'],
|
|
2216
|
+
},
|
|
2217
|
+
},
|
|
2218
|
+
{
|
|
2219
|
+
name: 'fcp_backup_trigger',
|
|
2220
|
+
description: 'Manually trigger a backup for a website. Admin only. Creates a queued backup job.',
|
|
2221
|
+
inputSchema: {
|
|
2222
|
+
type: 'object',
|
|
2223
|
+
properties: {
|
|
2224
|
+
websiteId: {
|
|
2225
|
+
type: 'number',
|
|
2226
|
+
description: 'The website ID to backup',
|
|
2227
|
+
},
|
|
2228
|
+
triggerType: {
|
|
2229
|
+
type: 'string',
|
|
2230
|
+
description: 'Trigger type (default: manual)',
|
|
2231
|
+
},
|
|
2232
|
+
},
|
|
2233
|
+
required: ['websiteId'],
|
|
2234
|
+
},
|
|
2235
|
+
},
|
|
2236
|
+
{
|
|
2237
|
+
name: 'fcp_backup_check_trigger',
|
|
2238
|
+
description: 'Check if a backup can be triggered for a website. Returns hosting status, K8s config, enabled status, and queue length.',
|
|
2239
|
+
inputSchema: {
|
|
2240
|
+
type: 'object',
|
|
2241
|
+
properties: {
|
|
2242
|
+
websiteId: {
|
|
2243
|
+
type: 'number',
|
|
2244
|
+
description: 'The website ID to check',
|
|
2245
|
+
},
|
|
2246
|
+
},
|
|
2247
|
+
required: ['websiteId'],
|
|
2248
|
+
},
|
|
2249
|
+
},
|
|
2250
|
+
{
|
|
2251
|
+
name: 'fcp_backup_list_backups',
|
|
2252
|
+
description: 'List backup history for a site. Returns backup jobs with status, size, duration, and location.',
|
|
2253
|
+
inputSchema: {
|
|
2254
|
+
type: 'object',
|
|
2255
|
+
properties: {
|
|
2256
|
+
siteId: {
|
|
2257
|
+
type: 'number',
|
|
2258
|
+
description: 'The website ID (will be formatted as site-{id} for the API)',
|
|
2259
|
+
},
|
|
2260
|
+
},
|
|
2261
|
+
required: ['siteId'],
|
|
2262
|
+
},
|
|
2263
|
+
},
|
|
2264
|
+
{
|
|
2265
|
+
name: 'fcp_backup_get_status',
|
|
2266
|
+
description: 'Get backup job status. Provide backupId for a specific job, or websiteId for backup history of a site.',
|
|
2267
|
+
inputSchema: {
|
|
2268
|
+
type: 'object',
|
|
2269
|
+
properties: {
|
|
2270
|
+
backupId: {
|
|
2271
|
+
type: 'string',
|
|
2272
|
+
description: 'Specific backup job ID to get status for',
|
|
2273
|
+
},
|
|
2274
|
+
websiteId: {
|
|
2275
|
+
type: 'number',
|
|
2276
|
+
description: 'Website ID to get backup history for',
|
|
2277
|
+
},
|
|
2278
|
+
},
|
|
2279
|
+
},
|
|
2280
|
+
},
|
|
2281
|
+
{
|
|
2282
|
+
name: 'fcp_backup_download',
|
|
2283
|
+
description: 'Generate a presigned S3 download URL for a completed backup. URL expires in 1 hour.',
|
|
2284
|
+
inputSchema: {
|
|
2285
|
+
type: 'object',
|
|
2286
|
+
properties: {
|
|
2287
|
+
backupId: {
|
|
2288
|
+
type: 'string',
|
|
2289
|
+
description: 'The backup ID to download',
|
|
2290
|
+
},
|
|
2291
|
+
},
|
|
2292
|
+
required: ['backupId'],
|
|
2293
|
+
},
|
|
2294
|
+
},
|
|
2295
|
+
{
|
|
2296
|
+
name: 'fcp_backup_download_prepared',
|
|
2297
|
+
description: 'Prepare a backup download with optional sanitization. Returns a presigned download URL with metadata.',
|
|
2298
|
+
inputSchema: {
|
|
2299
|
+
type: 'object',
|
|
2300
|
+
properties: {
|
|
2301
|
+
siteId: {
|
|
2302
|
+
type: 'string',
|
|
2303
|
+
description: 'The site ID (e.g., site-123)',
|
|
2304
|
+
},
|
|
2305
|
+
backupId: {
|
|
2306
|
+
type: 'string',
|
|
2307
|
+
description: 'The backup ID to download',
|
|
2308
|
+
},
|
|
2309
|
+
downloadType: {
|
|
2310
|
+
type: 'string',
|
|
2311
|
+
description: 'Type of download (e.g., database, files)',
|
|
2312
|
+
},
|
|
2313
|
+
format: {
|
|
2314
|
+
type: 'string',
|
|
2315
|
+
description: 'Download format (optional)',
|
|
2316
|
+
},
|
|
2317
|
+
sanitize: {
|
|
2318
|
+
type: 'boolean',
|
|
2319
|
+
description: 'Whether to sanitize production data (optional)',
|
|
2320
|
+
},
|
|
2321
|
+
},
|
|
2322
|
+
required: ['siteId', 'backupId', 'downloadType'],
|
|
2323
|
+
},
|
|
2324
|
+
},
|
|
2325
|
+
{
|
|
2326
|
+
name: 'fcp_backup_list_pairings',
|
|
2327
|
+
description: 'List site pairings for backup management. Optionally filter by site ID. Shows production/staging/dev relationships grouped by account.',
|
|
2328
|
+
inputSchema: {
|
|
2329
|
+
type: 'object',
|
|
2330
|
+
properties: {
|
|
2331
|
+
siteId: {
|
|
2332
|
+
type: 'number',
|
|
2333
|
+
description: 'Optional: specific site ID to get pairing for',
|
|
2334
|
+
},
|
|
2335
|
+
},
|
|
2336
|
+
},
|
|
2337
|
+
},
|
|
2338
|
+
{
|
|
2339
|
+
name: 'fcp_backup_update_pairing',
|
|
2340
|
+
description: 'Create or update a site pairing configuration. Defines staging/development relationships for a site.',
|
|
2341
|
+
inputSchema: {
|
|
2342
|
+
type: 'object',
|
|
2343
|
+
properties: {
|
|
2344
|
+
siteId: {
|
|
2345
|
+
type: 'number',
|
|
2346
|
+
description: 'The site ID to update pairing for',
|
|
2347
|
+
},
|
|
2348
|
+
pairingConfig: {
|
|
2349
|
+
type: 'object',
|
|
2350
|
+
description: 'Pairing configuration with staging (string|null) and development (array) site references',
|
|
2351
|
+
properties: {
|
|
2352
|
+
staging: { type: 'string', description: 'Staging site domain or null' },
|
|
2353
|
+
development: {
|
|
2354
|
+
type: 'array',
|
|
2355
|
+
items: { type: 'string' },
|
|
2356
|
+
description: 'Development site domains',
|
|
2357
|
+
},
|
|
2358
|
+
},
|
|
2359
|
+
},
|
|
2360
|
+
},
|
|
2361
|
+
required: ['siteId', 'pairingConfig'],
|
|
2362
|
+
},
|
|
2363
|
+
},
|
|
2364
|
+
{
|
|
2365
|
+
name: 'fcp_backup_delete_pairing',
|
|
2366
|
+
description: 'Remove a site pairing configuration. Clears the pairing config for a site.',
|
|
2367
|
+
inputSchema: {
|
|
2368
|
+
type: 'object',
|
|
2369
|
+
properties: {
|
|
2370
|
+
siteId: {
|
|
2371
|
+
type: 'number',
|
|
2372
|
+
description: 'The site ID to remove pairing for',
|
|
2373
|
+
},
|
|
2374
|
+
},
|
|
2375
|
+
required: ['siteId'],
|
|
2376
|
+
},
|
|
2377
|
+
},
|
|
1938
2378
|
];
|
|
1939
2379
|
// Register tool handlers
|
|
1940
2380
|
server.setRequestHandler(ListToolsRequestSchema, async () => {
|
|
@@ -2776,6 +3216,141 @@ server.setRequestHandler(CallToolRequestSchema, async (request) => {
|
|
|
2776
3216
|
],
|
|
2777
3217
|
};
|
|
2778
3218
|
}
|
|
3219
|
+
// Fruition Shield Handlers
|
|
3220
|
+
case 'fcp_shield_list_domains': {
|
|
3221
|
+
const { status, account_id } = args;
|
|
3222
|
+
const result = await client.shieldListDomains({ status, account_id });
|
|
3223
|
+
return {
|
|
3224
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
3225
|
+
};
|
|
3226
|
+
}
|
|
3227
|
+
case 'fcp_shield_add_domain': {
|
|
3228
|
+
const { domain, origin_host, origin_port, origin_protocol, website_id, account_id, cache_profile, notes } = args;
|
|
3229
|
+
const result = await client.shieldAddDomain({
|
|
3230
|
+
domain, origin_host, origin_port, origin_protocol, website_id, account_id, cache_profile, notes,
|
|
3231
|
+
});
|
|
3232
|
+
return {
|
|
3233
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
3234
|
+
};
|
|
3235
|
+
}
|
|
3236
|
+
case 'fcp_shield_get_domain': {
|
|
3237
|
+
const { domain_id } = args;
|
|
3238
|
+
const result = await client.shieldGetDomain(domain_id);
|
|
3239
|
+
return {
|
|
3240
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
3241
|
+
};
|
|
3242
|
+
}
|
|
3243
|
+
case 'fcp_shield_update_domain': {
|
|
3244
|
+
const { domain_id, ...updates } = args;
|
|
3245
|
+
const result = await client.shieldUpdateDomain(domain_id, updates);
|
|
3246
|
+
return {
|
|
3247
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
3248
|
+
};
|
|
3249
|
+
}
|
|
3250
|
+
case 'fcp_shield_remove_domain': {
|
|
3251
|
+
const { domain_id } = args;
|
|
3252
|
+
const result = await client.shieldRemoveDomain(domain_id);
|
|
3253
|
+
return {
|
|
3254
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
3255
|
+
};
|
|
3256
|
+
}
|
|
3257
|
+
case 'fcp_shield_get_metrics': {
|
|
3258
|
+
const result = await client.shieldGetMetrics();
|
|
3259
|
+
return {
|
|
3260
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
3261
|
+
};
|
|
3262
|
+
}
|
|
3263
|
+
// ============================================================================
|
|
3264
|
+
// Backup Management Handlers
|
|
3265
|
+
// ============================================================================
|
|
3266
|
+
case 'fcp_backup_list_sites': {
|
|
3267
|
+
const result = await client.backupListSites();
|
|
3268
|
+
return {
|
|
3269
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
3270
|
+
};
|
|
3271
|
+
}
|
|
3272
|
+
case 'fcp_backup_get_config': {
|
|
3273
|
+
const result = await client.backupGetConfig();
|
|
3274
|
+
return {
|
|
3275
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
3276
|
+
};
|
|
3277
|
+
}
|
|
3278
|
+
case 'fcp_backup_list_eligible': {
|
|
3279
|
+
const result = await client.backupListEligible();
|
|
3280
|
+
return {
|
|
3281
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
3282
|
+
};
|
|
3283
|
+
}
|
|
3284
|
+
case 'fcp_backup_enable': {
|
|
3285
|
+
const { siteId } = args;
|
|
3286
|
+
const result = await client.backupEnable(siteId);
|
|
3287
|
+
return {
|
|
3288
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
3289
|
+
};
|
|
3290
|
+
}
|
|
3291
|
+
case 'fcp_backup_trigger': {
|
|
3292
|
+
const { websiteId, triggerType } = args;
|
|
3293
|
+
const result = await client.backupTrigger(websiteId, triggerType);
|
|
3294
|
+
return {
|
|
3295
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
3296
|
+
};
|
|
3297
|
+
}
|
|
3298
|
+
case 'fcp_backup_check_trigger': {
|
|
3299
|
+
const { websiteId } = args;
|
|
3300
|
+
const result = await client.backupCheckTrigger(websiteId);
|
|
3301
|
+
return {
|
|
3302
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
3303
|
+
};
|
|
3304
|
+
}
|
|
3305
|
+
case 'fcp_backup_list_backups': {
|
|
3306
|
+
const { siteId } = args;
|
|
3307
|
+
const result = await client.backupListBackups(`site-${siteId}`);
|
|
3308
|
+
return {
|
|
3309
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
3310
|
+
};
|
|
3311
|
+
}
|
|
3312
|
+
case 'fcp_backup_get_status': {
|
|
3313
|
+
const { backupId, websiteId } = args;
|
|
3314
|
+
const result = await client.backupGetStatus({ backupId, websiteId });
|
|
3315
|
+
return {
|
|
3316
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
3317
|
+
};
|
|
3318
|
+
}
|
|
3319
|
+
case 'fcp_backup_download': {
|
|
3320
|
+
const { backupId } = args;
|
|
3321
|
+
const result = await client.backupDownload(backupId);
|
|
3322
|
+
return {
|
|
3323
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
3324
|
+
};
|
|
3325
|
+
}
|
|
3326
|
+
case 'fcp_backup_download_prepared': {
|
|
3327
|
+
const { siteId, backupId, downloadType, format, sanitize } = args;
|
|
3328
|
+
const result = await client.backupDownloadPrepared({ siteId, backupId, downloadType, format, sanitize });
|
|
3329
|
+
return {
|
|
3330
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
3331
|
+
};
|
|
3332
|
+
}
|
|
3333
|
+
case 'fcp_backup_list_pairings': {
|
|
3334
|
+
const { siteId } = args;
|
|
3335
|
+
const result = await client.backupListPairings(siteId);
|
|
3336
|
+
return {
|
|
3337
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
3338
|
+
};
|
|
3339
|
+
}
|
|
3340
|
+
case 'fcp_backup_update_pairing': {
|
|
3341
|
+
const { siteId, pairingConfig } = args;
|
|
3342
|
+
const result = await client.backupUpdatePairing(siteId, pairingConfig);
|
|
3343
|
+
return {
|
|
3344
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
3345
|
+
};
|
|
3346
|
+
}
|
|
3347
|
+
case 'fcp_backup_delete_pairing': {
|
|
3348
|
+
const { siteId } = args;
|
|
3349
|
+
const result = await client.backupDeletePairing(siteId);
|
|
3350
|
+
return {
|
|
3351
|
+
content: [{ type: 'text', text: JSON.stringify(result, null, 2) }],
|
|
3352
|
+
};
|
|
3353
|
+
}
|
|
2779
3354
|
default:
|
|
2780
3355
|
throw new Error(`Unknown tool: ${name}`);
|
|
2781
3356
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fruition/fcp-mcp-server",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.8.0",
|
|
4
4
|
"description": "MCP Server for FCP Launch Coordination System - enables Claude Code to interact with FCP launches and track development time",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"type": "module",
|