PreteWorks API
One key for the document-to-web pipeline: scrape, AI-extract, build & edit PDFs, fill forms.
Is this yours? Claim it freeA few minutes with a DNS record or a file. Then edit it, get uptime emails, a README badge and paid calls.
Add to your AI
Remote MCP server (streamable HTTP). Most clients sign you in with the provider on first use.
Claude Code
claude mcp add --transport http preteworks-api https://api.preteworks.com/mcp
Claude Desktop, Cursor, Windsurf (mcp config)
{
"mcpServers": {
"preteworks-api": {
"url": "https://api.preteworks.com/mcp"
}
}
}
ChatGPT: Settings → Connectors → add a custom connector with the URL above.
How to call PreteWorks API from code (MCP)
Remote MCP over streamable HTTP with the official SDKs: initialize, list its tools, then call_tool / callTool.
Python
# pip install mcp
import asyncio
from mcp import ClientSession
from mcp.client.streamable_http import streamablehttp_client
async def main():
async with streamablehttp_client("https://api.preteworks.com/mcp") as (read, write, _):
async with ClientSession(read, write) as session:
await session.initialize()
tools = await session.list_tools()
print([t.name for t in tools.tools])
asyncio.run(main())TypeScript
// npm i @modelcontextprotocol/sdk
import { Client } from "@modelcontextprotocol/sdk/client/index.js";
import { StreamableHTTPClientTransport } from "@modelcontextprotocol/sdk/client/streamableHttp.js";
const client = new Client({ name: "my-agent", version: "1.0.0" });
await client.connect(new StreamableHTTPClientTransport(new URL("https://api.preteworks.com/mcp")));
console.log((await client.listTools()).tools.map((t) => t.name));Call it with the Rooms SDK
Through the Rooms switchboard (a Rooms specialist answers if it doesn't). SDK docs
// npm i https://rooms.aurmada.com/sdk/rooms-a2a-0.1.0.tgz
import { Rooms } from "rooms-a2a";
const r = await new Rooms().ask("…", { agent: "preteworks-api" });
# pip install https://rooms.aurmada.com/sdk/rooms_a2a-0.1.0-py3-none-any.whl
from rooms_a2a import Rooms
r = Rooms().ask("…", agent="preteworks-api")Track record
- Uptime
- 100% uptime over the last 26 checked days (one unpaid request a day)
- Calls via Rooms (30 days)
- 0
No calls through Rooms in the last 30 days yet. Rooms only counts what it brokers, hosts or checks; nothing is estimated.
Tools (29)
- Render HTML to PDF
render_html_to_pdfRender a full HTML document to a PDF. External subresources are blocked for safety — inline images/fonts as data: URIs. Returns a file_id (for chaining) and a ~1h download URL. - Number PDF pages
number_pdfStamp a page number on every page. position: bottom-center (default) | bottom-left | bottom-right | top-center | top-left | top-right. format supports {n} and {total}. Returns a file_id + ~1h URL. - Read PDF info
pdf_infoRead a PDF's metadata (title, author, subject, keywords, creator, producer, dates) plus page count and page size, as JSON. - Set PDF metadata
set_pdf_metadataSet a PDF's title, author, subject, keywords (array or comma string) and/or creator. Only the fields you provide change. Returns a file_id + ~1h URL. - Generate a document
render_documentRender a structured document to a PDF from a named template (invoice, receipt, report). Money/totals are computed for you. Returns a file_id (for chaining) and a ~1h download URL. - Merge PDFs
merge_pdfsCombine 2+ PDFs into a single PDF, in the order given. Inputs are file_ids (from prior tools) or base64 PDFs. Returns a file_id (for chaining) and a ~1h download URL. - Select PDF pages
select_pagesKeep only the specified pages of a PDF (e.g. [1,3,5]) and drop the rest, preserving order. Returns a file_id (for chaining) and a ~1h download URL. - Rotate PDF
rotate_pdfRotate every page of a PDF by 90, 180, or 270 degrees (clockwise). Returns a file_id (for chaining) and a ~1h download URL. - Watermark PDF
watermark_pdfStamp a diagonal grey text watermark (e.g. "DRAFT", "CONFIDENTIAL") across every page of a PDF. Returns a file_id (for chaining) and a ~1h download URL. - Extract text from a PDF
extract_pdf_textExtract the text content of a PDF — for RAG, summarization, or search. Accepts a file_id (from a prior tool) or a base64-encoded PDF, and returns the text inline. Not OCR: a scanned/image-only PDF returns little or no text. - Images to PDF
images_to_pdfCombine PNG/JPEG images (base64) into a PDF, one image per page. Returns a file_id and a ~1h URL. - Render Markdown to PDF
markdown_to_pdfRender Markdown to a clean, print-styled PDF. Returns a file_id and a ~1h URL. - Split a PDF
split_pdfSplit a PDF into multiple PDFs — one per page by default, or by page ranges like '1-3;4-6'. Returns a file_id + URL per part. - Read a PDF form
read_pdf_formList a PDF's form fields (name, type, value, options) as JSON. - Fill a PDF form
fill_pdf_formFill a PDF's form fields from a map of field -> value; optionally flatten. Returns a file_id and a ~1h URL. - File to Markdown
file_to_markdownConvert a Word (.docx), Excel (.xlsx) or CSV file (base64) into clean Markdown — for RAG, agents and pipelines. DOCX keeps headings/lists/tables; spreadsheets become Markdown tables (one per sheet). Returns Markdown inline. Optional 'forma… - Create a spreadsheet from rows
data_to_spreadsheetTurn rows of data into a downloadable XLSX (default) or CSV. 'rows' is an array of objects (keys → header row) or an array of arrays (first row is the header). Returns a file_id (for chaining) and a ~1h download URL. - Batch: URLs to Markdown
batch_scrapeFetch up to 10 public URLs and return each as clean Markdown, in one call — for research/RAG over several pages at once. Private/internal hosts are blocked. - Crawl a site to Markdown
crawl_siteFetch a URL plus up to 7 more same-origin pages it links to (≤8 total), each as clean Markdown. Bounded and synchronous. Private/internal hosts are blocked. - Map a site's URLs
map_siteDiscover the same-origin URLs linked from a page — the site map, with no page content fetched. Private/internal hosts are blocked. - Extract structured data (AI)
extract_dataExtract specified fields from a web page, PDF, or Office file as JSON, using AI. Provide 'fields' plus ONE source: a 'url', a 'pdf' (file_id or base64), or a 'file' (base64 .docx/.xlsx/.csv). Returns a JSON object mapping each field to its… - Summarize a document (AI)
summarize_documentSummarize a web page, PDF, Office file (.docx/.xlsx/.csv), or raw text using AI. Provide ONE source: 'url', 'pdf' (file_id or base64), 'file' (base64), or 'text'. Optional 'max_words'. Returns the summary. - Answer a question from a document (AI)
answer_from_documentAnswer a question grounded ONLY in a source document — a web page, PDF, Office file, or raw text. Provide 'question' plus ONE source: 'url', 'pdf', 'file' (base64), or 'text'. Says so when the answer isn't in the document. - DOCX to text
docx_to_textExtract the text of a .docx document (base64). Returns the text inline. - DOCX to PDF
docx_to_pdfConvert a .docx document (base64) to a PDF. Returns a file_id and a ~1h URL. - Read a web page as Markdown
read_urlFetch a public http/https URL and return its main content as clean Markdown — ideal for giving an agent readable web content for research or RAG. Private/internal hosts are blocked. - Snapshot a web page as PDF
url_to_pdfFetch a public http/https URL and render the live page to a PDF. Returns a file_id (chainable into the PDF tools) and a ~1h download URL. Private/internal hosts are blocked. - Screenshot a web page
url_to_screenshotFetch a public http/https URL and capture a PNG screenshot. Set full_page for the entire scroll height. Returns a file_id and a ~1h download URL. - Scrape a web page (HTML + links + metadata)
scrape_pageFetch a public http/https URL and return its rendered HTML, the links on the page, and page metadata (title/description/OpenGraph/canonical/favicon) — in one render. For clean Markdown use read_url instead. Private/internal hosts are block…
Automated check: 80/100
Last run 2026-11-22 23:41 UTC. What we measured, not a guarantee.
- 10/10Every URL is https.
- 40/40MCP initialize answered (preteworks 1.1.0).
- 15/1529 tools listed by tools/list.
- 0/10No MCP server card at /.well-known/mcp/server-card.json.
- 10/10Has a homepage or documentation link.
- 5/5Answered in 1238 ms.
- 0/10Not claimed with a domain proof yet.