@url2md-io/mcp 0.1.3 → 0.1.4

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 (3) hide show
  1. package/README.md +22 -10
  2. package/dist/index.js +3 -3
  3. package/package.json +2 -2
package/README.md CHANGED
@@ -7,12 +7,16 @@
7
7
  > key. Give the key only to `@url2md-io/mcp`. If the name you are about to install has no scope in
8
8
  > front of it, it is the wrong one.
9
9
 
10
- An MCP server that gives your agent one tool: **turn any URL into clean Markdown**.
10
+ An MCP server that gives your agent one tool: **PDFs and pages that charge for access, as clean
11
+ Markdown**.
11
12
 
12
- It handles ordinary pages, JavaScript-rendered pages (a headless browser is used only when the page
13
- needs one) and PDFs. There is no account, no sign-up and no API key. Each call is paid for on-chain,
14
- from a wallet you control, at **$0.005** half a cent in USDC on Base. The settlement receipt
15
- comes back with the Markdown.
13
+ One conversion engine handles every kind, so the output is the same shape whichever it was: PDFs,
14
+ pages that only appear once JavaScript has run (a headless browser is used only when the page needs
15
+ one), and ordinary HTML. robots.txt is honoured per RFC 9309. There is no account, no sign-up and no API
16
+ key. Each call is paid for on-chain, from a wallet you control, at **$0.005** — half a cent — in USDC
17
+ on Base, and the settlement receipt comes back with the Markdown. When the page itself demands an
18
+ x402 payment before it will hand anything over, url2md pays that for you and the cost is included in
19
+ what you pay.
16
20
 
17
21
  ---
18
22
 
@@ -127,7 +131,7 @@ The server prints one line to stderr when it starts, naming the deployment, **th
127
131
  whether it is real money**, the wallet address it will pay from, and the per-call limit:
128
132
 
129
133
  ```
130
- @url2md-io/mcp 0.1.3 → https://url2md.io; eip155:8453 (real money); paying from 0x0972…7a36, at most $0.10 per call and $1.00 in total
134
+ @url2md-io/mcp 0.1.4 → https://url2md.io; eip155:8453 (real money); paying from 0x0972…7a36, at most $0.10 per call and $1.00 in total
131
135
  ```
132
136
 
133
137
  Your private key is never printed, logged, or sent anywhere except as the signature on a payment.
@@ -391,11 +395,19 @@ The testnet deployment is the same code as production, on the test network. Set
391
395
 
392
396
  ---
393
397
 
394
- ## Why this is a local server and not a hosted one
398
+ ## This local server, or the hosted connector
395
399
 
396
- Because a hosted server would have no wallet of yours to pay with. It would pay from its own and
397
- then have to bill you some other way an account, an API key, an invoice which is the exact thing
398
- x402 removes. Running it beside your client keeps the key on your machine and the payment yours.
400
+ This package is the local lane: it runs beside your client, holds your wallet key, and pays each call
401
+ itself, which is what lets it pay a page's own x402 toll too (quoted up front, settled after your
402
+ payment). Running it beside your client keeps the key on your machine and the payment yours.
403
+
404
+ The service also serves a hosted connector on its own origin — `POST /mcp`, Streamable HTTP behind
405
+ OAuth 2.1 with a GitHub sign-in — for clients that hold no wallet, such as claude.ai's custom
406
+ connectors. It is free to the signed-in account within a published allowance, and it never pays a
407
+ toll: a page that charges one comes back as an error pointing at this package and at the paid HTTP
408
+ endpoint. Where a deployment has it switched on, `GET /` lists it under `clients.mcp.remote` with the
409
+ URL and the allowance. Use this package when you want a toll paid, when you want no account in the
410
+ loop, or when you need more than the allowance.
399
411
 
400
412
  The key is read once at startup and used for one thing: signing
401
413
  [EIP-3009](https://eips.ethereum.org/EIPS/eip-3009) USDC transfer authorizations for the exact
package/dist/index.js CHANGED
@@ -18,7 +18,7 @@ import { Budget, ceilingLooksWrong, CEILING_WORTH_MENTIONING_USD, convert, disco
18
18
  * message or into a tool result.
19
19
  */
20
20
  export const SERVER_NAME = "url2md";
21
- export const SERVER_VERSION = "0.1.3";
21
+ export const SERVER_VERSION = "0.1.4";
22
22
  export const TOOL_NAME = "fetch_markdown";
23
23
  export const inputSchema = z.object({
24
24
  url: z.string().describe("The absolute http(s) URL to convert. Public hosts only: private, loopback and link-local addresses are refused, and the origin's robots.txt is obeyed."),
@@ -155,9 +155,9 @@ export function toolDescription(config, pricing) {
155
155
  : pricing?.model === "free"
156
156
  ? `This deployment (${config.baseUrl}) is not charging: calls are free.`
157
157
  : `Calls are paid per call over x402 from your own wallet; the live price is published at ${config.baseUrl}/.`;
158
- return ("Fetch any web page or PDF and return it as clean Markdown, ready to read. Handles JavaScript-rendered pages (a headless browser is used when the page needs one) and PDFs. " +
158
+ return ("Return a web page or PDF as clean Markdown: PDFs, pages that only render once JavaScript has run (a headless browser is used when the page needs one), and ordinary HTML, all through one conversion engine. robots.txt is obeyed per RFC 9309. " +
159
159
  `${cost} This server refuses to sign more than $${config.maxPriceUsd} for one call, or $${config.maxSpendUsd} in total for as long as it is running. ` +
160
- "If the page itself charges an x402 toll, url2md pays it and the cost is included in what you pay. " +
160
+ "If the page itself demands an x402 payment of its own, url2md pays that for you and the cost is included in what you pay. " +
161
161
  "Errors, including a payment that could not be made, come back as an error result whose text is a JSON object with a stable `code`.");
162
162
  }
163
163
  const isTestNetwork = (network) => network === "eip155:84532" || (network ?? "").includes("sepolia");
package/package.json CHANGED
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "name": "@url2md-io/mcp",
3
- "version": "0.1.3",
3
+ "version": "0.1.4",
4
4
  "mcpName": "io.url2md/mcp",
5
- "description": "MCP server for url2md any URL in, clean Markdown out. Pays per call over x402 from your own wallet.",
5
+ "description": "MCP server for url2md: PDFs and x402-tolled pages as clean Markdown, JavaScript rendering included, paid per call from your own wallet.",
6
6
  "keywords": [
7
7
  "mcp",
8
8
  "model-context-protocol",