@spicrawl/mcp 0.1.6 → 0.1.8

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.
@@ -1,5 +1,5 @@
1
1
  import { z } from "zod";
2
- import { run } from "./common.js";
2
+ import { loose, run } from "./common.js";
3
3
  // Usage analytics: /v1/usage, /v1/usage/summary, /v1/usage/reconciliation.
4
4
  // All three require the API key to carry the `read` scope (not in the default
5
5
  // key scopes {scrape, batch, sessions}); without it the API answers 403.
@@ -35,6 +35,107 @@ const METRICS = [
35
35
  "client_other",
36
36
  ];
37
37
  const DATE = z.string().regex(/^\d{4}-\d{2}-\d{2}$/, "YYYY-MM-DD");
38
+ // What the three endpoints answer (openapi.yaml: UsageBreakdown, UsageByKey,
39
+ // UsageSummary, UsageReconciliation). Metric names are open-ended ("new metrics
40
+ // may appear as map keys"), so a metric map is a record, not a fixed list.
41
+ const METRIC_MAP = z
42
+ .record(z.string(), z.number())
43
+ .nullish()
44
+ .describe("Metric name -> quantity. credits are micro-credits (1 credit = 1000000), engine_ms milliseconds, bytes_* bytes, the rest counts.");
45
+ const PERIOD = loose({
46
+ start: z.string().optional().describe("First UTC day, inclusive (YYYY-MM-DD)."),
47
+ end: z.string().optional().describe("End UTC day, EXCLUSIVE (YYYY-MM-DD)."),
48
+ days: z.number().optional(),
49
+ bounds: z.string().optional().describe("Always '[start, end)'."),
50
+ }).optional().describe("The window, as a half-open range of UTC days.");
51
+ const USAGE_AS_OF = z.string().nullish().describe("When the newest rollup row in the window was written; null when the window is empty.");
52
+ const STALE_SECONDS = z.number().nullish().describe("Age of usage_as_of in seconds; null when the window is empty. A large value means the rollup is behind.");
53
+ const WARNINGS = z.array(z.string()).optional().describe("Caveats the numbers would otherwise hide.");
54
+ const USAGE_OUTPUT = loose({
55
+ period: PERIOD,
56
+ group_by: z.string().optional().describe("The dimension used: day, project, engine, feature or key."),
57
+ groups: z
58
+ .array(loose({
59
+ key: z.string().describe("The bucket: a YYYY-MM-DD day, a project id, an engine tier (fetch, js or browser) or a feature (extract, ai_extract, proxy_datacenter, proxy_residential, batch)."),
60
+ label: z.string().optional().describe("Human label for an engine tier."),
61
+ metrics: METRIC_MAP,
62
+ }))
63
+ .nullish()
64
+ .describe("The buckets, sorted by key. Empty (or missing for group_by=key) does not mean no usage: read totals."),
65
+ totals: METRIC_MAP.optional().describe("Billed quantities for the whole window. Authoritative; use these, not the sum of groups."),
66
+ unattributed: METRIC_MAP.optional().describe("The part of each total the groups do not explain."),
67
+ keys: z
68
+ .array(loose({
69
+ key_id: z.string(),
70
+ name: z.string().optional(),
71
+ prefix: z.string().optional().describe("Display prefix of the API key, never the secret."),
72
+ project_id: z.string().optional(),
73
+ revoked: z.boolean().optional(),
74
+ days: z.array(loose({ day: z.string(), metrics: METRIC_MAP })).nullish(),
75
+ totals: METRIC_MAP.optional(),
76
+ }))
77
+ .nullish()
78
+ .describe("group_by=key only: one entry per API key, with its counters per UTC day."),
79
+ usage_as_of: USAGE_AS_OF,
80
+ stale_seconds: STALE_SECONDS,
81
+ warnings: WARNINGS,
82
+ });
83
+ const SUMMARY_OUTPUT = loose({
84
+ period: PERIOD,
85
+ period_elapsed_days: z.number().optional().describe("Whole days of the period elapsed; use it to pace consumption."),
86
+ plan: loose({
87
+ code: z.string().optional(),
88
+ name: z.string().optional(),
89
+ version: z.number().optional(),
90
+ subscription_status: z.string().optional().describe("'none' when no subscription covers now (the free plan)."),
91
+ period_source: z.string().optional().describe("'subscription' (billing period) or 'allowance_month'."),
92
+ }).optional(),
93
+ credits: loose({
94
+ included_micro: z.number().optional(),
95
+ used_micro: z.number().optional().describe("Credits spent so far, from the usage rollup; excludes credits held for in-flight work."),
96
+ remaining_micro: z.number().optional(),
97
+ overage_micro: z.number().optional(),
98
+ overage_micro_cents_per_credit: z.number().optional(),
99
+ used_basis_points: z.number().nullish().describe("Used / included in basis points (10000 = 100%); null when nothing is included."),
100
+ })
101
+ .nullish()
102
+ .describe("Metered usage against the plan's included credits. Micro-credits: 1 credit = 1000000."),
103
+ allowance: loose({
104
+ limit_micro: z.number().optional(),
105
+ limit_credits: z.number().optional(),
106
+ limit_source: z.string().optional().describe("'default' or 'override'."),
107
+ unlimited: z.boolean().optional(),
108
+ used_micro: z.number().optional().describe("Spent plus credits held for in-flight work."),
109
+ remaining_micro: z.number().optional().describe("Credits left under the monthly limit: the number to show."),
110
+ window_start: z.string().optional(),
111
+ resets_at: z.string().optional().describe("When the allowance is restored in full."),
112
+ })
113
+ .optional()
114
+ .describe("The monthly allowance the API enforces. Omitted when it cannot be read (warnings says so)."),
115
+ metrics: METRIC_MAP.optional().describe("Every billed metric for the period."),
116
+ unattributed: METRIC_MAP.optional(),
117
+ usage_as_of: USAGE_AS_OF,
118
+ stale_seconds: STALE_SECONDS,
119
+ warnings: WARNINGS,
120
+ });
121
+ const RECONCILIATION_OUTPUT = loose({
122
+ day: z.string().optional().describe("The UTC day reconciled."),
123
+ drift: z
124
+ .array(loose({
125
+ project_id: z.string().optional(),
126
+ metric: z.string().optional(),
127
+ stored_qty: z.number().optional().describe("The billed quantity."),
128
+ observed_qty: z.number().optional().describe("The quantity re-derived from the request log."),
129
+ delta: z.number().optional(),
130
+ action: z.string().optional().describe("The verdict: missing_in_usage_daily, absent_from_request_log, undercounted or overcounted."),
131
+ }))
132
+ .nullish()
133
+ .describe("Disagreements; empty means no drift."),
134
+ request_log_rows: z.number().optional().describe("Rows in the request log for the day; 0 means there was nothing to compare against."),
135
+ interpretation: z.string().optional().describe("What the drift can and cannot prove. Read it before acting on drift."),
136
+ repairable: z.boolean().optional().describe("Always false; nothing is repaired."),
137
+ warnings: WARNINGS,
138
+ });
38
139
  export const registerUsageTools = (server, client) => {
39
140
  server.registerTool("spicrawl_usage", {
40
141
  title: "Usage breakdown",
@@ -56,6 +157,7 @@ export const registerUsageTools = (server, client) => {
56
157
  .optional()
57
158
  .describe("Metrics to return. Omit for all of them."),
58
159
  },
160
+ outputSchema: USAGE_OUTPUT,
59
161
  annotations: { readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false },
60
162
  }, async (args) => run(() => {
61
163
  const qs = new URLSearchParams();
@@ -77,6 +179,7 @@ export const registerUsageTools = (server, client) => {
77
179
  description: "A compact current-period summary of your org's usage (totals as of now, from the daily rollup). No parameters. " +
78
180
  "Use for a quick 'how much have I used so far'; use spicrawl_usage for a windowed breakdown. Requires the `read` scope.",
79
181
  inputSchema: {},
182
+ outputSchema: SUMMARY_OUTPUT,
80
183
  annotations: { readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false },
81
184
  }, async () => run(() => client.request("GET", "/v1/usage/summary")));
82
185
  server.registerTool("spicrawl_usage_reconciliation", {
@@ -87,6 +190,7 @@ export const registerUsageTools = (server, client) => {
87
190
  inputSchema: {
88
191
  day: DATE.optional().describe("The UTC day to reconcile, YYYY-MM-DD. Default: yesterday."),
89
192
  },
193
+ outputSchema: RECONCILIATION_OUTPUT,
90
194
  annotations: { readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false },
91
195
  }, async ({ day }) => run(() => client.request("GET", `/v1/usage/reconciliation${day ? `?day=${encodeURIComponent(day)}` : ""}`)));
92
196
  };
@@ -1 +1 @@
1
- {"version":3,"file":"usage.js","sourceRoot":"","sources":["../../src/tools/usage.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,GAAG,EAAsB,MAAM,aAAa,CAAC;AAEtD,2EAA2E;AAC3E,8EAA8E;AAC9E,yEAAyE;AACzE,MAAM,OAAO,GAAG;IACd,UAAU;IACV,SAAS;IACT,WAAW;IACX,cAAc;IACd,eAAe;IACf,gBAAgB;IAChB,kBAAkB;IAClB,aAAa;IACb,gBAAgB;IAChB,aAAa;IACb,iBAAiB;IACjB,kBAAkB;IAClB,iBAAiB;IACjB,oBAAoB;IACpB,mBAAmB;IACnB,iBAAiB;IACjB,wBAAwB;IACxB,mBAAmB;IACnB,eA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.1.6",
3
+ "version": "0.1.8",
4
4
  "mcpName": "io.github.OfficialSpicrawl/mcp",
5
- "description": "The Spicrawl MCP server is a Model Context Protocol server that gives AI agents in Claude Code, Claude Desktop, Cursor, VS Code, Windsurf, Gemini CLI and Codex web scraping to Markdown, structured data extraction, screenshots, browser sessions and batch scraping as 25 native tools.",
5
+ "description": "MCP server for web scraping: scrape any URL to Markdown or JSON for Claude, Cursor and AI agents, with JavaScript rendering, batch scraping and data extraction",
6
6
  "license": "Apache-2.0",
7
7
  "author": "Spicrawl",
8
8
  "homepage": "https://docs.spicrawl.com/agents/mcp",
@@ -20,25 +20,20 @@
20
20
  "model-context-protocol",
21
21
  "web-scraping",
22
22
  "web-scraper",
23
- "web-crawler",
24
- "html-to-markdown",
23
+ "scraper",
24
+ "batch-scraping",
25
25
  "markdown",
26
+ "html-to-markdown",
26
27
  "data-extraction",
27
28
  "structured-data",
28
- "screenshot",
29
29
  "javascript-rendering",
30
- "batch-scraping",
30
+ "browser-automation",
31
31
  "llm",
32
- "ai-agents",
33
32
  "rag",
33
+ "ai-agents",
34
34
  "claude",
35
35
  "claude-code",
36
- "claude-desktop",
37
- "cursor",
38
- "vscode",
39
- "codex",
40
- "gemini-cli",
41
- "windsurf"
36
+ "cursor"
42
37
  ],
43
38
  "type": "module",
44
39
  "bin": {