Start

Quickstart

Get an API key, send one request, and understand the three ways the file can come back.

Reading this with an AI agent?

The entire documentation lives in one Markdown file, built to be fetched and read by an LLM. Copy the prompt below and paste it into ChatGPT, Claude, Cursor or any agent with web access — it asks the agent to read the file before helping you.

Open the Markdown

https://api.searchops.io/doc/docxapi.md

1. Create an API key

  1. Sign in at api.searchops.io/dashboard with Google.
  2. Open API keys and create one.
  3. Copy it immediately — the full key starts with sk_live_ and is shown only once.

Treat it like a password. Keys are stored hashed, so a lost key cannot be recovered — only rotated or deleted. Never put one in browser-side code.

2. Send your first request

Authentication is a single header: x-api-key.

curl
curl -X POST https://api.searchops.io/v1/generate \
  -H "Content-Type: application/json" \
  -H "x-api-key: sk_live_YOUR_KEY" \
  -d '{
    "input_type": "markdown",
    "content": "# Hello\n\nThis is **bold** text.",
    "response_format": "file",
    "filename": "hello"
  }' \
  --output hello.docx

That is a complete integration. There is no second call, no polling, and no job to wait on.

3. Choose how the file comes back

The response_format field changes the shape of the response, not the document.

ValueYou getUse it when
fileRaw .docx bytesThe next step stores or sends the file — Google Drive, S3, an email attachment. Best for n8n.
base64JSON with a base64 stringYour platform builds the binary itself, or you want to inspect the response first. This is the default.
urlJSON with a 24h download linkYou are handing a download to a human and do not want the bytes through your own system.
base64 response
{
  "status": "success",
  "format": "base64",
  "data": "UEsDBBQABgAIAAAAIQD…",
  "pages": null,
  "generation_time_ms": 480
}

pages is always null. Page count cannot be determined without rendering the document, so the API returns nothing rather than a wrong number. Do not build logic on it.

4. Name the file

Pass filename and the .docx extension is added for you. Unicode is fine; slashes and control characters are rejected.

request
{
  "input_type": "markdown",
  "content": "# Relatório\n\nConteúdo…",
  "response_format": "file",
  "filename": "Relatório mensal"
}

The response carries both an ASCII fallback and the UTF-8 name, so downloads keep accents in every browser.

Where to go next