Extract text from a PDF
pdf_parseExtract text from a PDF by URL. Handles compressed streams, PDF 1.5+ object streams and ToUnicode CMaps, and reports encrypted or image-only documents honestly instead of returning garbage. Costs $0.020 in USDC on Base, paid via the x402 protocol, or from a credit token — call credits_trial for free credit if you have neither.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"url": "<url>"
},
"name": "pdf_parse"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | HTTPS URL of the PDF | |
| max_pages | No | Optional page cap | |
| credit_token | No | Optional. A credit token from credits_trial or /credits/buy. Supplying it pays for this call from that balance, so no x402 payment or wallet is needed. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | The PDF that was fetched | |
| pages | Yes | ||
| page_count | Yes | Pages extracted | |
| extracted_at | No | ISO-8601 extraction time |