# Tanod Docs – PDF from Images

> Tanod Docs – PDF from Images is a paid API for AI agents from docs.tanod.dev, paid per call via x402, $0.005/call, status unknown (last checked 2026-10-13).

Converts one or more images (PNG, JPEG, or WebP) into a single PDF document, with configurable page size, orientation, and margins.

## Facts

- Endpoint: POST https://docs.tanod.dev/v1/pdf/from-images?utm_source=zero.xyz
- Price: $0.005/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-13
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/tanod-docs-pdf-from-images-23e1e99c
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_IyNgo1j30kzTYogVxCoUb

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability tanod-docs-pdf-from-images-23e1e99c -d '<json body>'
```

Example prompt: Take these three JPEG screenshots — here are their URLs — and combine them into a single A4 PDF with a 10-point margin around each image, then give me a download link valid for 24 hours.

## When to prefer this

Choose this endpoint when you need a straightforward, per-call image-to-PDF conversion without standing up your own document infrastructure. It is especially suited for AI agent workflows that dynamically assemble PDFs from remote image URLs or in-memory base64 images, need configurable page sizing (fit/A4/letter) and orientation, and want the result either inline or as a temporary hosted download link. Prefer it over heavier document pipelines when the sole input is raster images rather than Office files or HTML.

## Known failure modes

- Image URL unreachable or returns non-image content — request fails with an error
- Image exceeds 10 MB size limit — rejected before processing
- More than 30 images submitted — rejected due to maxItems constraint
- Invalid base64 string supplied — decoding error returned
- Unsupported image format (e.g. GIF or TIFF) — format rejection error
- Network timeout fetching remote image URLs — partial or full failure

## How this service works

Documents: DOCX template fill, Office to PDF, any file to Markdown, PDF to Word, OCR, PDF pipeline.

## Output

Returns a JSON object containing the resulting PDF as either inline base64 data or a 24-hour download URL (with expiry timestamp, byte size, content type, and SHA-256 hash), along with metadata such as page count, operation name, input and output byte sizes, and page size used.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "images": {
   "type": "array",
   "items": {
    "type": "object",
    "properties": {
     "url": {
      "anyOf": [
       {
        "type": "string",
        "maxLength": 2048,
        "minLength": 1
       },
       {
        "type": "null"
       }
      ],
      "default": null,
      "description": "http(s) URL of a PNG, JPEG or WebP (at most 10 MB)."
     },
     "image_base64": {
      "anyOf": [
       {
        "type": "string",
        "maxLength": 13398872,
        "minLength": 1
       },
       {
        "type": "null"
       }
      ],
      "default": null,
      "description": "The image as base64; or use url."
     }
    },
    "additionalProperties": false
   },
   "maxItems": 30,
   "minItems": 1,
   "description": "1-30 images (PNG, JPEG, WebP), each {url} or {image_base64}."
  },
  "margin": {
   "type": "number",
   "default": 0,
   "maximum": 144,
   "minimum": 0,
   "description": "Points (1/72 in) around each image."
  },
  "output": {
   "enum": [
    "base64",
    "url"
   ],
   "type": "string",
   "default": "base64",
   "description": "base64 (default): the file comes back inline as base64. url: the file is stored for 24 hours and the reply carries a download link (url, expires_at, bytes, content_type, sha256) instead of the base64, which keeps the file out of your context window."
  },
  "page_size": {
   "enum": [
    "fit",
    "a4",
    "letter"
   ],
   "type": "string",
   "default": "fit",
   "description": "fit (each page is its image's size), a4 or letter."
  },
  "orientation": {
   "enum": [
    "auto",
    "portrait",
    "landscape"
   ],
   "type": "string",
   "default": "auto",
   "description": "a4/letter only."
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "file": {
   "name": "images.pdf",
   "bytes": 3285,
   "pages": 1,
   "data_base64": "JVBERi0xLjMKJeLj... (trimmed: 4,380 base64 characters in the reply)",
   "content_type": "application/pdf"
  },
  "images": 1,
  "operation": "from-images",
  "page_size": "a4",
  "input_bytes": 2183,
  "input_pages": 1,
  "output_bytes": 3285,
  "untrusted_content": true
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/tanod-docs-pdf-from-images-23e1e99c/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from docs.tanod.dev](https://www.zero.xyz/host/docs.tanod.dev/llms.txt)
