@aaa-sentinel/mcp-server 0.3.0 → 0.4.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 +5 -0
- package/dist/cli.js +54 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -137,12 +137,17 @@ status as plain JSON.
|
|
|
137
137
|
| `get_agent_playbook` | `playbookId` | `agent:read` | Business |
|
|
138
138
|
| `list_agent_playbook_templates` | — | `agent:read` | Business |
|
|
139
139
|
| `list_monitors` | `pinned?`, `clientId?` | `monitoring:read` | Pro |
|
|
140
|
+
| `count_monitors_by_client` | — | `monitoring:read` | Pro |
|
|
140
141
|
| `get_monitor` | `monitorId` | `monitoring:read` | Pro |
|
|
141
142
|
| `list_monitor_results` | `monitorId`, `limit?`, `before?` | `monitoring:read` | Pro |
|
|
142
143
|
| `get_monitor_uptime` | `monitorId`, `days?` | `monitoring:read` | Pro |
|
|
143
144
|
| `list_monitoring_services` | — | `monitoring:read` | Pro |
|
|
144
145
|
| `get_monitoring_service` | `serviceId` | `monitoring:read` | Pro |
|
|
145
146
|
| `get_service_history` | `serviceId`, `limit?` | `monitoring:read` | Pro |
|
|
147
|
+
| `list_monitoring_incidents` | `state?`, `monitorId?`, `limit?`, `before?` | `monitoring:read` | Pro |
|
|
148
|
+
| `get_monitoring_incident` | `incidentId` | `monitoring:read` | Pro |
|
|
149
|
+
| `list_status_pages` | — | `monitoring:read` | Pro |
|
|
150
|
+
| `get_status_page` | `pageId` | `monitoring:read` | Pro |
|
|
146
151
|
|
|
147
152
|
In `list_savings`, `type` is one of `compute`, `storage`, `network`, `database`, `serverless`,
|
|
148
153
|
`governance`. `source` is one of `own`, `corroborated`, `securityhub`, `guardduty`, `defender`,
|
package/dist/cli.js
CHANGED
|
@@ -4591,6 +4591,13 @@ var TOOLS = [
|
|
|
4591
4591
|
argsSchema: external_exports.object({ pinned: external_exports.boolean().optional(), clientId: external_exports.string().min(1).optional() }),
|
|
4592
4592
|
handler: async ({ pinned, clientId: clientId2 }, config) => apiGet("/v1/monitoring/monitors", { pinned: pinned ? "true" : void 0, clientId: clientId2 }, config)
|
|
4593
4593
|
}),
|
|
4594
|
+
defineTool({
|
|
4595
|
+
name: "count_monitors_by_client",
|
|
4596
|
+
description: "Count the monitors and flows of each managed client, to rebill monitoring per client. Every client the token can see is listed, with zeros if it has none; the organization\u2019s own monitors do not count. Requires the monitoring:read scope and the Pro plan or above.",
|
|
4597
|
+
inputSchema: { type: "object", properties: {} },
|
|
4598
|
+
argsSchema: external_exports.object({}),
|
|
4599
|
+
handler: async (_args, config) => apiGet("/v1/monitoring/clients/counts", void 0, config)
|
|
4600
|
+
}),
|
|
4594
4601
|
defineTool({
|
|
4595
4602
|
name: "get_monitor",
|
|
4596
4603
|
description: "Get one monitor with its definition, current state, since when, and last result (outcome, reason code, status code, latency). Requires the monitoring:read scope and the Pro plan or above.",
|
|
@@ -4645,15 +4652,61 @@ var TOOLS = [
|
|
|
4645
4652
|
),
|
|
4646
4653
|
argsSchema: external_exports.object({ serviceId: external_exports.string().min(1), limit: external_exports.number().int().min(1).max(200).optional() }),
|
|
4647
4654
|
handler: async ({ serviceId, limit }, config) => apiGet(`/v1/monitoring/services/${encodeURIComponent(serviceId)}/history`, { limit: asText(limit) }, config)
|
|
4655
|
+
}),
|
|
4656
|
+
defineTool({
|
|
4657
|
+
name: "list_monitoring_incidents",
|
|
4658
|
+
description: 'List monitoring incidents (each alerted outage, from when it started until it recovered), newest first, with duration, who acknowledged it and what it cost: the business impact per minute set on the monitor and, for cloud resources, an approximate cloud cost, in the organization currency. This answers "what is on fire and who is on it". Filter by state (open or resolved) or monitor. Paginated: pass the returned "nextCursor" as "before"; a page can come back short or empty with a cursor. Requires the monitoring:read scope and the Pro plan or above.',
|
|
4659
|
+
inputSchema: objectWith({
|
|
4660
|
+
state: { type: "string", enum: ["open", "resolved"], description: "Only open or only resolved incidents (optional)." },
|
|
4661
|
+
monitorId: { ...MONITOR_ID, description: "Only the incidents of this monitor (optional)." },
|
|
4662
|
+
limit: { type: "integer", minimum: 1, maximum: 200, description: "Page size (default 50)." },
|
|
4663
|
+
before: { type: "string", description: 'The "nextCursor" value of the previous page (optional).' }
|
|
4664
|
+
}),
|
|
4665
|
+
argsSchema: external_exports.object({
|
|
4666
|
+
state: external_exports.enum(["open", "resolved"]).optional(),
|
|
4667
|
+
monitorId: external_exports.string().min(1).optional(),
|
|
4668
|
+
limit: external_exports.number().int().min(1).max(200).optional(),
|
|
4669
|
+
before: external_exports.string().min(1).optional()
|
|
4670
|
+
}),
|
|
4671
|
+
handler: async ({ state, monitorId, limit, before }, config) => apiGet("/v1/monitoring/incidents", { state, monitorId, limit: asText(limit), before }, config)
|
|
4672
|
+
}),
|
|
4673
|
+
defineTool({
|
|
4674
|
+
name: "get_monitoring_incident",
|
|
4675
|
+
description: "Get one monitoring incident with its timeline (opened, re-alerted, acknowledged, notes, closed), its cause (reason code, status code, failed flow step) and what it cost in the organization currency. Requires the monitoring:read scope and the Pro plan or above.",
|
|
4676
|
+
inputSchema: objectWith({ incidentId: { type: "string", description: "Incident identifier, as returned by list_monitoring_incidents." } }, ["incidentId"]),
|
|
4677
|
+
argsSchema: external_exports.object({ incidentId: external_exports.string().min(1) }),
|
|
4678
|
+
handler: async ({ incidentId }, config) => apiGet(`/v1/monitoring/incidents/${encodeURIComponent(incidentId)}`, void 0, config)
|
|
4679
|
+
}),
|
|
4680
|
+
defineTool({
|
|
4681
|
+
name: "list_status_pages",
|
|
4682
|
+
description: "List the status pages (the public or link-only pages that show customers whether each service is up), with which client each belongs to, its services, language and custom domain, and how many more fit in the plan. A private page comes without its address: that link opens it for anyone. Requires the monitoring:read scope and the Pro plan or above.",
|
|
4683
|
+
inputSchema: objectWith({}),
|
|
4684
|
+
argsSchema: external_exports.object({}),
|
|
4685
|
+
handler: async (_args, config) => {
|
|
4686
|
+
const body = await apiGet("/v1/monitoring/status-pages", void 0, config);
|
|
4687
|
+
return { ...body, pages: (body.pages ?? []).map(withoutPrivateLink) };
|
|
4688
|
+
}
|
|
4689
|
+
}),
|
|
4690
|
+
defineTool({
|
|
4691
|
+
name: "get_status_page",
|
|
4692
|
+
description: "Get one status page: its settings and the step its custom domain is at, with the DNS records still to create. A private page comes without its address: that link opens it for anyone. Requires the monitoring:read scope and the Pro plan or above.",
|
|
4693
|
+
inputSchema: objectWith({ pageId: { type: "string", description: "Status page identifier, as returned by list_status_pages." } }, ["pageId"]),
|
|
4694
|
+
argsSchema: external_exports.object({ pageId: external_exports.string().min(1) }),
|
|
4695
|
+
handler: async ({ pageId }, config) => withoutPrivateLink(await apiGet(`/v1/monitoring/status-pages/${encodeURIComponent(pageId)}`, void 0, config))
|
|
4648
4696
|
})
|
|
4649
4697
|
];
|
|
4698
|
+
function withoutPrivateLink(page) {
|
|
4699
|
+
if (page["visibility"] !== "private") return page;
|
|
4700
|
+
const { url: _url, ...rest } = page;
|
|
4701
|
+
return rest;
|
|
4702
|
+
}
|
|
4650
4703
|
function findTool(name) {
|
|
4651
4704
|
return TOOLS.find((tool) => tool.name === name);
|
|
4652
4705
|
}
|
|
4653
4706
|
|
|
4654
4707
|
// src/protocol.ts
|
|
4655
4708
|
var SERVER_NAME = "aaa-sentinel-mcp";
|
|
4656
|
-
var SERVER_VERSION = "0.
|
|
4709
|
+
var SERVER_VERSION = "0.4.0";
|
|
4657
4710
|
var SUPPORTED_PROTOCOL_VERSIONS = ["2025-06-18", "2025-03-26", "2024-11-05"];
|
|
4658
4711
|
var PARSE_ERROR = -32700;
|
|
4659
4712
|
var INVALID_REQUEST = -32600;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aaa-sentinel/mcp-server",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.4.0",
|
|
4
4
|
"description": "Read-only MCP server for AAA Sentinel: query cloud costs, savings, security posture, AI spend, uptime monitoring, the remediation agent and managed clients from an AI assistant",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|