API Documentation

Everything you need to integrate the Web-to-Markdown API.

Authentication

All API requests require an x-api-key header. Get your key from the dashboard.

POST/api/v1/convert

Convert a webpage URL to clean, structured Markdown.

Request Body

{
  "url": "https://example.com",       // required
  "include_links": true,               // optional, default: true
  "include_images": true               // optional, default: true
}

Headers

HeaderRequiredDescription
x-api-keyRequiredYour API key
Content-TypeRequiredapplication/json

Success Response (200)

{
  "success": true,
  "data": {
    "url": "https://example.com",
    "markdown": "# Example Domain\n\nThis domain is for...",
    "length": 1234,
    "usage": {
      "used": 24,
      "limit": 50,
      "plan": "free"
    }
  },
  "meta": {
    "response_time_ms": 342
  }
}

Error Responses

401Missing or invalid API key
422Invalid request body or non-HTML URL
429Rate limit or monthly quota exceeded
502Target URL unreachable or blocking requests
504Request timed out (15s limit)

Rate Limits

PlanRequests/minMonthly callsPrice
Free1050$0
Pro6010,000$9/mo
Enterprise200100,000$49/mo

cURL Example

terminal
$ curl -X POST https://wtmapi.com/api/v1/convert \
  -H "Content-Type: application/json" \
  -H "x-api-key: wtm_your_api_key_here" \
  -d '{"url": "https://example.com"}'