Extract Text from a PDF
pdf_to_textExtract the text from a PDF file at a URL and return it as markdown, page by page. Use it to read a PDF, parse a form, report, paper, invoice, or document, or convert a PDF to text. Works on PDFs with a text layer (scanned image-only PDFs return little or no text; no OCR). Price: $0.005 per successful call; failed calls are free. Free to try: a few calls a day without a key.
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_to_text"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | The http(s) URL of the PDF file. | |
| api_key | No | Your Unstuck API key, if this connection has none. Leave empty to try free tools or to get a key and payment link. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | PDF URL after redirects. | |
| bytes | Yes | File size in bytes. | |
| pages | Yes | Number of pages. | |
| title | Yes | Title from the PDF metadata, if any. | |
| markdown | Yes | Text as markdown, one "## Page N" section per page. | |
| truncated | Yes | True if the text was cut at the size limit. | |
| balance_usd | Yes | Remaining prepaid balance, USD. | |
| charged_usd | Yes | Amount charged for this call, USD. | |
| likely_scanned | Yes | True if the PDF looks image-only (little extractable text). |