Extract clean Markdown from a URL
Fetch a single URL and return its main content as clean Markdown, with the navigation, ads, cookie banners and boilerplate stripped.
Fetch a single URL and return its main content as clean Markdown, with the navigation, ads, cookie banners and boilerplate stripped.
This is the synchronous endpoint: one URL in, extracted content out, in a single round trip. For many URLs use POST /bulk; to follow links from a starting page use POST /crawl.
format selects the output shape — markdown (default), json (typed blocks), chunks (pre-split for embedding), html, or links. json and chunks are Pro+ features, as is render_js, which runs the page through a headless browser first for client-side-rendered sites.
Costs one request against your monthly quota.
Authorization
BearerAuth Your API key, sent as Authorization: Bearer wm_.... Keys are wm_ followed by 40 hex characters. Create one with POST /register (free, no auth) or POST /keys.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://api.wellmarked.io/extract" \ -H "Authorization: Bearer wm_your_api_key_here" \ -H "Content-Type: application/json" \ -d '{ "url": "http://example.com" }'{ "blocks": [ { "level": 0, "text": "string", "type": "heading" } ], "chunks": [ { "end_token": 0, "start_token": 0, "text": "string" } ], "html": "string", "links": [ "string" ], "markdown": "string", "metadata": { "author": "string", "date": "string", "retrieved_at": "2019-08-24T14:15:22Z", "title": "string", "url": "string" }, "metrics": { "content_bytes": 0, "input_tokens": 0, "output_tokens": 0, "reduction_pct": 0, "tokens_saved": 0 }, "request_id": "266ea41d-adf5-480b-af50-15b940c2b846"}Examples
Copy-paste recipes for the four things most integrations do first — extract a page, render JS, run a bulk job to completion, and check your usage.
Check your usage for the current billing period
Return the calling key's request count for the current billing period, the plan's included allowance, and when the counter resets.