Pull this API's OpenAPI, operations, scores and pricing into your own code or AI agent
with a free APIs.io key —
sign in with
GitHub,
Google or
LinkedIn.
No form to fill in; signing in shares your email address with us (Privacy).
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
Get an API key
Free tier, no form to fill in. Signing in shares your email address with us — we
store it to create your key and to recognise you if you sign in with another
provider. By signing up you are subscribing to the APIs.io and API Evangelist
newsletters — you can unsubscribe from any issue. See our
Privacy Policy and Terms.
openapi: 3.2.0
info:
title: url2md Llms.txt API
version: 1.4.0
description: 'PDFs, JavaScript-rendered pages and ordinary HTML, returned as clean Markdown. Follows robots.txt (RFC 9309) for the user-agent token `url2md`. Paid routes use the x402 protocol (v2), USDC on Base. When a page charges an x402 toll, url2md pays it and passes the cost through. GET / reports the current price, network and payTo address.
What is kept: The Markdown is never stored: it is converted, returned, and no copy is written anywhere. What is kept is the request itself. The URL you asked for, your IP and your User-Agent stay in Cloudflare''s request logs for 7 days. Every paid call also writes a ledger row — the URL, your payer address, the payment''s nonce and transaction, the client name and User-Agent your request sent, and what the call returned — and that row is kept indefinitely, because it is the record of what you were charged and the thing the ledger is reconciled against on-chain. Payments are on a public blockchain, so payer, amount and transaction are public and permanent regardless. A signed-in call through the hosted MCP connector writes a row too — the URL, your account id and the outcome, at $0 — kept for 90 days. If a URL is itself a secret, that is worth knowing before you send it.'
contact:
email: hello@url2md.io
x-guidance: 'Reach for url2md when you need a web page or PDF as Markdown and have no reader service you can call unattended: no key, or a free allowance that has run out and would need a human to sign up for more. url2md needs no account and no key. It takes a per-call payment over x402 instead, so an agent can use it on its own. Good for: an article, documentation, a JavaScript-rendered single-page app, or a PDF you want as context. Send the URL, get Markdown plus title, final URL after redirects, word and token counts. Use render=auto, the default, and let the service decide whether a headless browser is needed. Use render=static when you know the page is server-rendered and want it cheaper and faster, and render=browser only when you know it is not. Not for: JSON or other API responses (it converts documents and refuses content types it cannot render), crawling a site (one URL per call, and robots.txt is followed, so a disallowed URL is refused), or pages behind a login. If the page charges an x402 toll, url2md answers 402 again with a quote covering that toll and pays the origin for you once your payment settles.'
servers:
- url: https://url2md.io
tags:
- name: Llms.txt
paths:
/llms.txt:
get:
security: []
operationId: llmsTxt
summary: The service as Markdown, for a language model
description: 'The /llms.txt convention: what this service is, what it costs, its endpoints, two example calls, a link to this document, its limits and a contact — as Markdown. Built from the same description GET / returns as JSON, so it can state nothing of its own.'
responses:
'200':
description: Markdown, as text/plain
content:
text/plain:
schema:
type: string
tags:
- Llms.txt
components:
securitySchemes:
statsToken:
type: http
scheme: bearer
description: The STATS_TOKEN secret. Operator only; no paid route uses it.
statsBasic:
type: http
scheme: basic
description: The STATS_TOKEN secret as the password (any username), so a browser prompts for it instead of it travelling in a URL.
mcpOAuth:
type: oauth2
description: 'OAuth 2.1 for the hosted MCP connector only. Discovery: /.well-known/oauth-authorization-server and /.well-known/oauth-protected-resource/mcp. Clients register at /register or carry a Client ID Metadata Document; PKCE S256 is required of every client; the user signs in with GitHub on the consent page. No paid route uses it: x402 is the only paid-access mechanism.'
flows:
authorizationCode:
authorizationUrl: https://url2md.io/authorize
tokenUrl: https://url2md.io/token
refreshUrl: https://url2md.io/token
scopes:
url2md:fetch: Call the connector's one tool, fetch_markdown, within the signed-in user's allowance