PreteWorks API

com.preteworksPublished by preteworks.comOfficial publisherv1.0.2Updated Oct 24, 2026

One key for the document-to-web pipeline: scrape, AI-extract, build & edit PDFs, fill forms.

VerifiedStreamable HTTPWeb executableWeb Search & ScrapingFiles & StorageAI & ML

Overview

AI-generated overview

A hosted document and web pipeline API that lets an assistant scrape pages, extract or summarize content with AI, and build, edit and fill PDFs.

What you can do
Render HTML, Markdown, structured documents and images to PDF, and convert DOCX to PDF or text and Office files to Markdown or spreadsheets, with data turned into XLSX or CSV files. Edit PDFs by merging, splitting, selecting or rotating pages, adding page numbers, watermarks and metadata, and reading or filling form fields. Read PDF metadata and extract PDF text for search or summarization. Fetch public URLs as Markdown, HTML, links, metadata, screenshots or PDFs, and batch-scrape or crawl a site's linked pages. Use AI to extract named fields, summarize, or answer questions grounded only in a page, PDF, Office file or raw text.
When to use it
Useful when an assistant needs to turn web pages or documents into readable text or PDFs, assemble or clean up PDFs, fill PDF forms, or run AI extraction and question answering over a supplied source. It suits research, RAG preparation and document generation without running local conversion libraries.
Requirements
A remote streamable HTTP endpoint at api.preteworks.com. A bearer API key is required in the Authorization header; keys come from a signup page, and the free tier is listed as 500 units per month with no card. Network access is needed, and generated files are returned as file IDs plus download links valid for about one hour.
Before you install
The API key is a secret sent in the Authorization header, and usage is metered in units, so heavier use may require a paid plan. Documents, URLs and text you submit are processed by a third-party service, and the AI tools send content to that service for extraction, summarization and answering. Generated download links expire after about one hour. Scraping is limited to public hosts; private and internal addresses are blocked.

Installation

In SourceWeft

  1. Open PreteWorks API in the dashboard and add it to a workspace.
  2. Connect Authorization token credentials. They are stored privately and never shown on public pages.
  3. Enable the server for the chats that should use its tools.

Web executable via Streamable HTTP. Remote servers run from the web runtime once configured in a workspace.

Use with an agent

Paste this prompt into Claude Code, Codex, Cursor or another agent — or into SourceWeft chat. The agent reads this server's install guide, shows you its publisher, endpoint and sign-in, and adds it to your client once you agree. Keys never go into a command.

Read https://sourceweft.com/mcp/com.preteworks%2Fpreteworks-api/install.md and connect the MCP server it describes to my client. Before changing any config, show me its publisher, endpoint and sign-in method and wait for my OK. Never put an API key in a command or in a file I would commit; ask me where it should come from.

Read the install guide the agent follows

Other MCP clients

Add this to your client's mcpServers config.

{
  "mcpServers": {
    "preteworks-api": {
      "type": "http",
      "url": "https://api.preteworks.com/mcp",
      "headers": {
        "Authorization": "Bearer <YOUR_TOKEN>"
      }
    }
  }
}

Tools

29

render_html_to_pdf

Render HTML to PDF

Render 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.

Parametershtmlrequired

number_pdf

Number PDF pages

Stamp 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.

Parameterspdfrequiredstartformatposition

pdf_info

Read PDF info

Read a PDF's metadata (title, author, subject, keywords, creator, producer, dates) plus page count and page size, as JSON.

Parameterspdfrequired

set_pdf_metadata

Set PDF metadata

Set 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.

Parameterspdfrequiredtitleauthorcreatorsubjectkeywords

render_document

Generate a document

Render 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.

Parametersdatarequiredtemplaterequired

merge_pdfs

Merge PDFs

Combine 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.

Parameterspdfsrequired

select_pages

Select PDF pages

Keep 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.

Parameterspdfrequiredpagesrequired

rotate_pdf

Rotate PDF

Rotate every page of a PDF by 90, 180, or 270 degrees (clockwise). Returns a file_id (for chaining) and a ~1h download URL.

Parameterspdfrequireddegreesrequired

watermark_pdf

Watermark PDF

Stamp 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.

Parameterspdfrequiredtextrequired

extract_pdf_text

Extract text from a PDF

Extract 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.

Parameterspdfrequired

images_to_pdf

Images to PDF

Combine PNG/JPEG images (base64) into a PDF, one image per page. Returns a file_id and a ~1h URL.

Parametersimagesrequired

markdown_to_pdf

Render Markdown to PDF

Render Markdown to a clean, print-styled PDF. Returns a file_id and a ~1h URL.

Parameterstitlemarkdownrequired

split_pdf

Split a PDF

Split 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.

Parameterspdfrequiredranges

read_pdf_form

Read a PDF form

List a PDF's form fields (name, type, value, options) as JSON.

Parameterspdfrequired

fill_pdf_form

Fill a PDF form

Fill a PDF's form fields from a map of field -> value; optionally flatten. Returns a file_id and a ~1h URL.

Parameterspdfrequiredfieldsrequiredflatten

file_to_markdown

File to Markdown

Convert 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 'format' (docx|xlsx|csv) overrides auto-detection.

Parametersfilerequiredformat

data_to_spreadsheet

Create a spreadsheet from rows

Turn 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.

Parametersrowsrequiredformatsheet_name

batch_scrape

Batch: URLs to Markdown

Fetch 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.

Parametersurlsrequired

crawl_site

Crawl a site to Markdown

Fetch 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.

Parametersurlrequiredlimit

map_site

Map a site's URLs

Discover the same-origin URLs linked from a page — the site map, with no page content fetched. Private/internal hosts are blocked.

Parametersurlrequired

extract_data

Extract structured data (AI)

Extract 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 value, or null when absent.

Parameterspdfurlfilefieldsrequired

summarize_document

Summarize a document (AI)

Summarize 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.

Parameterspdfurlfiletextmax_words

answer_from_document

Answer a question from a document (AI)

Answer 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.

Parameterspdfurlfiletextquestionrequired

docx_to_text

DOCX to text

Extract the text of a .docx document (base64). Returns the text inline.

Parametersdocxrequired

docx_to_pdf

DOCX to PDF

Convert a .docx document (base64) to a PDF. Returns a file_id and a ~1h URL.

Parametersdocxrequired

read_url

Read a web page as Markdown

Fetch 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.

Parametersurlrequired

url_to_pdf

Snapshot a web page as PDF

Fetch 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.

Parametersurlrequired

url_to_screenshot

Screenshot a web page

Fetch 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.

Parametersurlrequiredfull_page

scrape_page

Scrape a web page (HTML + links + metadata)

Fetch 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 blocked.

Parametersurlrequiredformats

Version history

1
  1. v1.0.2LatestSep 16, 2026

Score

72% of the applicable checks met

How complete this listing is, computed from the registry entry, the endpoint and public sources. Not a rating of the server and not a statement that it is safe or working today: reachability is a dated check, and no installs or reviews go into the score.

  • Reached in the last 30 daysRequired25 pts
  • Auth declaredRequired10 pts
  • Tools listedRequired15 pts
  • DescriptionRequired15 pts
  • Logo10 pts

    Publish an icon in the registry entry.

  • Documentation15 pts

    Declare a GitHub repository with a README, or serve resource_documentation in the OAuth protected-resource metadata.

  • LicenseNot applicable

    A hosted service is used under its provider's terms, so no license is expected here. This check is left out of the percentage.