# Tanod Docs – PDF Remove Pages

> Tanod Docs – PDF Remove Pages 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).

Removes specified pages from a PDF document and returns the modified PDF as base64 or a download URL

## Facts

- Endpoint: POST https://docs.tanod.dev/v1/pdf/remove-pages?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-remove-pages-a8bb5f8e
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_HJpzlUC_05BpGL-bMFzu3

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-remove-pages-a8bb5f8e -d '<json body>'
```

Example prompt: Can you remove pages 1, 3, and 5-7 from this PDF at https://example.com/report.pdf and give me the result as a download link?

## When to prefer this

Use this endpoint when you need to programmatically remove specific pages from a PDF — by number, range, or keywords like 'last' — without converting the document to another format. It is well-suited for automation pipelines where PDFs need to be sanitized, trimmed, or prepared before sharing. Prefer this over general PDF editing tools when you need a lightweight, API-driven solution that returns the result inline or as a temporary download link, especially when operating within an AI agent workflow.

## Known failure modes

- PDF URL is private, internal, or uses an IP-literal host — request refused
- PDF exceeds 20 MB (URL) or 10 MB decoded (base64) — size limit error
- Invalid page range syntax in 'pages' field — validation error
- URL is unreachable or returns a non-PDF — fetch error
- PDF is password-protected or encrypted — processing failure
- Page numbers out of range for the actual document — error or no-op

## 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 modified PDF either as inline base64 (file.data_base64) or a 24-hour download URL, along with metadata including the output file name, byte size, page count, and content type. Also includes input_bytes, input_pages, output_bytes, and a flag indicating whether active/untrusted content was removed.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "url": {
   "anyOf": [
    {
     "type": "string",
     "maxLength": 2048,
     "minLength": 1
    },
    {
     "type": "null"
    }
   ],
   "default": null,
   "description": "Public http(s) URL of the PDF (at most 20 MB; private, internal and IP-literal hosts are refused); or use pdf_base64."
  },
  "pages": {
   "type": "string",
   "pattern": "^[0-9a-zA-Z ,\\-]+$",
   "maxLength": 200,
   "minLength": 1,
   "description": "1-based pages to remove: N, N-M, N- (to the end), -M, last; comma separated."
  },
  "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."
  },
  "pdf_base64": {
   "anyOf": [
    {
     "type": "string",
     "maxLength": 13398872,
     "minLength": 1
    },
    {
     "type": "null"
    }
   ],
   "default": null,
   "description": "The PDF as base64 (at most 10 MB decoded per request); or use url."
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "file": {
   "name": "removed.pdf",
   "bytes": 51782,
   "pages": 1,
   "data_base64": "JVBERi0xLjcKJb/3... (trimmed: 69,044 base64 characters in the reply)",
   "content_type": "application/pdf"
  },
  "operation": "remove-pages",
  "input_bytes": 140815,
  "input_pages": 6,
  "output_bytes": 51782,
  "untrusted_content": true,
  "active_content_removed": {}
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/tanod-docs-pdf-remove-pages-a8bb5f8e/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)
