Skip to content
Fourohtwo

Convert documents between formats with pandoc

agentsvc.io/api/v1/proxy/doc-convert

Convert documents between formats with pandoc: Markdown, HTML, DOCX, ODT, EPUB, RST, LaTeX, RTF, plain text and PDF. Input as text (content), file (file_base64, max 10 MB: docx, odt, epub, rtf) or url. Input format is detected automatically or set with from. Text outputs come back as content, binary outputs (docx, odt, epub, pdf) as file_base64. Local file includes and remote images are not loaded

BaseUnchecked
POSThttps://agentsvc.io/api/v1/proxy/doc-convert

UptimeNot checked yet

30 days agoToday

Try it

Pays from your browser wallet in USDC on Base or USDG on Robinhood Chain, whichever the endpoint takes. The provider is paid directly; failed calls aren't refunded by Fourohtwo.

The response shows up here.

Call it from an agent

import { createPayer } from "fourohtwo";

// One agent key pays USDC on Base or USDG on Robinhood Chain,
// inside the spending rules you set on Fourohtwo.
const pay = createPayer({ privateKey: process.env.AGENT_KEY });
const res = await pay("https://agentsvc.io/api/v1/proxy/doc-convert", {
  method: "POST",
  headers: { "content-type": "application/json" },
  body: JSON.stringify({"to":"docx","content":"# Quarterly Report\n\n| Quarter | Revenue |\n|---|---|\n| Q1 | 12 |"}),
});
console.log(await res.json());

Example input

{
  "to": "docx",
  "content": "# Quarterly Report\n\n| Quarter | Revenue |\n|---|---|\n| Q1 | 12 |"
}