# AgentTools PDF to Text Extractor

> AgentTools PDF to Text Extractor is a paid API for AI agents from agentstoolshub.com, paid per call via x402, $0.01/call, status unknown (last checked 2026-10-12).

Fetches a PDF by URL (SSRF-guarded) or accepts base64-encoded PDF content and extracts all readable text with page count using deterministic parsing.

## Facts

- Endpoint: GET https://agentstoolshub.com/api/v1/dev/pdf-to-text?utm_source=zero.xyz
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-12
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/agenttools-pdf-to-text-extractor-78156b23
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_futbyIhSsAbLO5dMSepyR

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 agenttools-pdf-to-text-extractor-78156b23
```

Example prompt: Can you extract all the text from this PDF for me? Here's the URL: https://example.com/report.pdf — just give me the full readable content and how many pages it has.

## When to prefer this

Use this endpoint whenever an AI agent needs to read the content of a PDF document — either from a public URL or as base64 content — and the PDF contains embedded text (not scanned images). It is deterministic and does not hallucinate content, making it reliable for legal, financial, or research documents. Prefer this over OCR-based or LLM-based solutions when you need exact text reproduction with no inference.

## Known failure modes

- URL points to a non-PDF resource — parsing fails or returns empty text
- PDF is scanned/image-based with no embedded text — returns empty or minimal text (OCR not included)
- URL is blocked by SSRF guard (private/internal IP ranges) — request rejected
- base64 input is malformed or not a valid PDF — parsing error returned
- PDF is encrypted or password-protected — text extraction fails
- maxChars too low — truncates output significantly

## How this service works

Fetch a PDF (by URL, SSRF-guarded) or accept it as base64 and extract all readable text with page count. Deterministic parsing — no language model, so nothing is invented. Text-based PDFs only; scanned images need OCR (not included). Use this when an agent needs to extract readable text from any PDF — agents can't read PDFs.

## Output

Returns all readable text extracted from the PDF along with the total page count. Output is deterministically parsed — no language model inference, so the text is exactly what appears in the PDF. Works only on text-based PDFs; scanned image PDFs are not supported.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [],
     "properties": {
      "url": {
       "type": "string",
       "description": "Or provide base64 instead"
      },
      "base64": {
       "type": "string",
       "description": "Base64 content"
      },
      "maxChars": {
       "type": "number",
       "description": "Max text length"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/agenttools-pdf-to-text-extractor-78156b23/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from agentstoolshub.com](https://www.zero.xyz/host/agentstoolshub.com/llms.txt)
