# PDF Extractor All-in-One: Text, Tables & OCR (`t800solutions/pdf-extractor`) Actor

The all-in-one PDF extractor: text in reading order (even multi-column), LLM-ready Markdown, tables, OCR for scanned pages in 20 languages, RAG chunks, images and page images. Passwords, page ranges, links, uploads or base64. Failed PDFs are not charged. Export via API, CSV or Excel.

- **URL**: https://apify.com/t800solutions/pdf-extractor.md
- **Developed by:** [T800 Solutions](https://apify.com/t800solutions) (community)
- **Categories:** AI, Developer tools, Automation
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: 5.00 out of 5 stars

## Pricing

from $0.70 / 1,000 page extracteds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

**PDF Extractor All-in-One** is a PDF extractor API that turns any PDF into clean, structured data in a single run: **text in reading order** (even 2, 3 or 4-column layouts), **LLM-ready Markdown** with headings, **tables** as rows and columns, **OCR for scanned PDFs** in 20 languages, **RAG chunks** with page numbers, the **images inside the PDF** and **each page as an image**. Paste PDF links, upload a file or send base64, then export the results as JSON, CSV or Excel, or use them through the API. **Failed PDFs are not charged.**

### ✨ What can this PDF extractor do?

| Feature | What it does |
|---|---|
| 📝 **PDF to text and Markdown** | Full text in reading order, plus Markdown with `#` `##` `###` headings, lists and tables, ready for ChatGPT, Claude, Gemini or any LLM |
| 📰 **Multi-column layouts** | Papers, magazines and government publications in 2, 3 or 4 columns come out in the order a person reads them |
| 📊 **PDF tables** | Every table as rows and columns and as a Markdown table, with or without borders, including multi-row headers. **Included at no extra cost** |
| 🔍 **OCR for scanned PDFs** (add-on) | Scans, faxes, photos and image-only pages read by OCR in 20 languages, several at once. Only pages without text go to OCR |
| 🖼️ **Export images** (add-on) | Every photo, logo and chart inside the PDF as its own file, cleaned up: no tiny icons or lines, a repeated logo comes out once, JPGs keep their original quality |
| 📸 **Page images** (add-on) | Each page as a PNG, JPG or WebP image (72 to 600 DPI, or 200 px thumbnails), great for AI vision models and previews |
| 🧩 **RAG chunks** | Text split into overlapping pieces, each with the pages it came from, ready for Pinecone, Weaviate, Chroma, Qdrant or any vector database |
| 🔑 **Passwords and page ranges** | Protected PDFs, `1-5, 8, 12-`, or only the first or last N pages |
| 🧹 **Clean-up** | Remove repeated headers and footers, page numbers, extra blank lines and empty pages |
| 🗂️ **PDF metadata** | Title, author, subject, creator, producer, dates, page count, protection and file size |
| 📈 **Live Run summary** | PDFs done, pages, OCR pages, images and amount charged, updated every 15 seconds |

### 🚀 How to extract text, tables and images from a PDF

1. Paste one or more links in **📄 PDF URLs** (up to 1,000 per run), upload a file in **📎 Upload a PDF or image**, or send base64 through the API. Images (JPG, PNG, TIFF, WebP) work too, with OCR on.
2. Pick the **🧾 Output format**: one row per PDF (full text + Markdown), one row per page, or RAG chunks.
3. Turn on the add-ons you need: **Add-on: OCR scanned pages** for scanned PDFs, **Add-on: Export images** for the images inside the PDF, **Add-on: Page images** for each page as an image.
4. Click **Start**. Text rows appear in the **PDFs** tab while the run goes; exported images appear in the **Images** tab and in **Images (ZIP)**; the **Run summary** shows progress.
5. Download the results as **JSON, CSV or Excel**, or get them through the API.

It runs on the Apify platform, so you can also schedule runs, call it from your own code, get a webhook when a run finishes and connect it to n8n, Make, Zapier or AI agents (see Integrations below).

### 📥 Which download should I choose?

| You want | Choose this | Where |
|---|---|---|
| Read or filter the text in **Excel or Google Sheets** | Output format **One row per page**, then export **Excel** or **CSV** | PDFs tab → Export |
| The **full text** of each PDF in one piece | Output format **One row per PDF**, then export **JSON** | PDFs tab → Export |
| Text for **ChatGPT, Claude or another LLM** | The **markdown** column (headings, lists and tables kept) | PDFs tab, or JSON |
| A **vector database / RAG** | Output format **RAG chunks**, then export **JSON** | PDFs tab → Export |
| **Tables** as rows and columns | The **tables** field in **JSON** (in Excel and CSV, tables are inside the markdown column) | PDFs tab → Export JSON |
| **Images**, one by one | The gallery, with a download button on each image | **Images** tab |
| **All images at once** | A **ZIP** file with every image and page image, one folder per PDF | **Images (ZIP)** in the Output tab, or the **Download all images (ZIP)** button in the Images tab |
| Everything **by API** | Dataset items (text) plus the `IMAGES_JSON` record (every image with its page, size and download link) | Apify API |

> **Good to know:**
>
> - Excel and CSV files contain **text only**. Spreadsheets can't hold images, so images are never inside them: get them from the **Images (ZIP)** download or the **Images** tab.
> - One Excel cell holds at most **32,767 characters**. Long PDFs don't fit in one cell, so for Excel use **One row per page**. JSON and the API always have the full text, with no limit. The Run summary reminds you when this happens.
> - Image download links work without logging in, so you can share them or use them in other tools.

### 💰 How much does it cost to extract data from PDFs?

You pay only for what is delivered (pay per event). Prices per 1,000, by your Apify plan:

| Event | Free | Bronze | Silver | Gold and above |
|---|---|---|---|---|
| Page extracted (text, Markdown, tables, metadata) | $1.00 | $0.90 | $0.80 | $0.70 |
| PDF processed | $5.00 | $4.50 | $4.00 | $3.50 |
| Add-on: OCR page (only pages without text) | $6.00 | $5.40 | $4.80 | $4.20 |
| Add-on: Image exported | $1.00 | $0.90 | $0.80 | $0.70 |
| Add-on: Page image (up to 300 DPI; above counts as two) | $5.00 | $4.50 | $4.00 | $3.50 |

Plus the Actor start fee of $0.005 per GB of memory. **Tables are free. Failed PDFs, skipped images and pages above your limits are not charged.**

**Examples (Free plan):** a 100-page digital PDF costs about $0.11; the same PDF fully scanned, with OCR on every page, about $0.71; 1,000 one-page digital invoices, about $6.00.

**Is it free to try?** Yes. The Apify Free plan includes $5 of usage every month, with no credit card, which covers about 4,700 pages of digital PDFs.

### ⬇️ Input example

```json
{
  "urls": ["https://example.com/annual-report.pdf"],
  "output_format": "document",
  "include_markdown": true,
  "extract_tables": true,
  "ocr_scanned_pages": false,
  "page_range": "1-5"
}
```

- `urls` (**📄 PDF URLs**): links to PDFs or images, up to 1,000 per run.
- `output_format` (**🧾 Output format**): `document` (one row per PDF), `pages` (one row per page) or `chunks` (RAG chunks).
- `ocr_scanned_pages` (**🔍 Add-on: OCR scanned pages**) with `ocr_languages`, for example `["eng", "por"]`.
- `export_images` (**🖼️ Add-on: Export images**) and `page_images` (**📸 Add-on: Page images**).
- `pdf_password` (**🔑 PDF password**), `page_range` (**📑 Page range**), `first_pages` and `last_pages` to read only part of a PDF.

### 📤 Output example

One row per PDF, shortened:

```json
{
  "source": "https://example.com/annual-report.pdf",
  "status": "success",
  "page_count": 3,
  "extracted_page_count": 3,
  "ocr_page_count": 0,
  "title": "Annual Report",
  "author": "Example Inc.",
  "char_count": 5120,
  "word_count": 812,
  "text": "Annual Report 2026 ...",
  "markdown": "# Annual Report 2026\n\n## Summary\n\n...\n\n| Product | Price |\n| --- | --- |\n| Coffee | 2.50 |",
  "tables": [{"page": 2, "rows": [["Product", "Price"], ["Coffee", "2.50"]]}],
  "is_encrypted": false,
  "processed_at": "2026-11-09T10:00:00Z"
}
```

Exported images are listed in the `IMAGES_JSON` record, with the ZIP files and every image grouped by PDF:

```json
{"zip_files": [{"part": 1, "file": "images.zip", "files": 42, "size_mb": 8.4, "url": "https://api.apify.com/v2/key-value-stores/.../records/images.zip?signature=..."}],
 "pdfs": [{"source": "https://example.com/annual-report.pdf",
           "images": [{"page": 1, "format": "jpg", "width": 1200, "height": 800, "size_kb": 184,
                       "url": "https://api.apify.com/v2/key-value-stores/.../records/annual-report-p001-img01.jpg?signature=..."}],
           "page_images": [{"page": 1, "format": "png", "dpi": 150, "width": 1275, "height": 1650, "url": "..."}]}]}
```

Status values: `success`, `partial` (time limit, page limit or your maximum charge reached; the pages already read are delivered) and `failed` (with `error_code`: `download_failed`, `not_a_pdf`, `corrupt_pdf`, `password_required`, `wrong_password`, `too_large`, `invalid_base64`, `image_needs_ocr`).

### 🧑‍💻 Use the PDF Extractor API from Python, JavaScript or cURL

**Python** (`pip install apify-client`):

```python
from apify_client import ApifyClient

client = ApifyClient("<YOUR_API_TOKEN>")
run = client.actor("t800solutions/pdf-extractor").call(run_input={
    "urls": ["https://www.w3.org/WAI/WCAG21/working-examples/pdf-table/table.pdf"],
    "include_markdown": True,
})
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item["source"], item["page_count"], item["markdown"][:200])
```

**JavaScript** (`npm install apify-client`):

```javascript
import { ApifyClient } from 'apify-client';

const client = new ApifyClient({ token: '<YOUR_API_TOKEN>' });
const run = await client.actor('t800solutions/pdf-extractor').call({
    urls: ['https://www.w3.org/WAI/WCAG21/working-examples/pdf-table/table.pdf'],
    include_markdown: true,
});
const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(items[0].markdown);
```

**cURL** (waits for the run and returns the rows; for runs of up to 5 minutes):

```bash
curl -X POST "https://api.apify.com/v2/acts/t800solutions~pdf-extractor/run-sync-get-dataset-items" \
  -H "Authorization: Bearer <YOUR_API_TOKEN>" \
  -H "Content-Type: application/json" \
  -d '{"urls": ["https://www.w3.org/WAI/WCAG21/working-examples/pdf-table/table.pdf"]}'
```

The **API** tab of this page has ready-made examples for more languages and the full list of endpoints.

More examples ready to copy (Python, JavaScript and cURL) on GitHub: [github.com/t800solutions/apify-actors/pdf-extractor](https://github.com/t800solutions/apify-actors/tree/main/pdf-extractor)

### 🔌 Integrations: n8n, Make, Zapier, LangChain, LlamaIndex and AI agents

- **n8n**: the [Apify node](https://docs.apify.com/platform/integrations/n8n) runs this Actor and returns the rows ("Run an Actor and get dataset"), for example to send each PDF's Markdown to an AI step or a database.
- **Make** and **Zapier**: the Apify apps for [Make](https://docs.apify.com/platform/integrations/make) and [Zapier](https://docs.apify.com/platform/integrations/zapier) start a run and read the results, for example from new files in a folder.
- **LangChain** and **LlamaIndex**: load the rows as documents with the Apify integrations for [LangChain](https://docs.apify.com/platform/integrations/langchain) and [LlamaIndex](https://docs.apify.com/platform/integrations/llama-index), then embed the RAG chunks in your vector store.
- **AI agents (MCP)**: Claude, Cursor and other MCP clients can find and run this Actor through the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp).
- **Webhooks and schedules**: get a [webhook](https://docs.apify.com/platform/integrations/webhooks) when a run finishes, or run it on a [schedule](https://docs.apify.com/platform/schedules).

### 💡 Use cases

- **RAG and AI pipelines**: feed documents to embeddings, vector stores and LLM prompts, with page numbers for citations.
- **Invoice and document processing**: text and tables from supplier invoices, receipts and statements, scanned or digital.
- **Research and analysis**: papers, reports and filings in bulk, tables straight to CSV or Excel.
- **AI vision**: page images for GPT-4o, Claude or Gemini when the layout matters.
- **Content and catalogs**: product images and photos out of brochures and catalogs.

### 🌍 OCR languages

English, Portuguese, Spanish, French, German, Italian, Dutch, Polish, Turkish, Russian, Ukrainian, Arabic, Hindi, Japanese, Korean, Chinese (Simplified and Traditional), Vietnamese, Indonesian and Thai.

### 🔒 Privacy

Your PDFs are used only to process your run. An uploaded file is deleted from storage right after it is processed. The Actor keeps no copy of your documents, and its logs contain only numbers (pages, size, time), never their content. Extracted images and page images are saved only in your own run storage.

### ❓ FAQ

**How do I convert a PDF to Markdown for ChatGPT, Claude or RAG?** Keep **📝 Markdown (LLM-ready)** on (the default) and use the `markdown` column. For a vector database, choose Output format **RAG chunks**: each chunk has the pages it came from, for citations.

**Can I extract tables from a PDF to Excel or CSV?** Yes. Tables are included at no extra cost. Choose **One row per page** and export Excel or CSV (each table is in the markdown column), or export JSON to get every table as rows and columns in the `tables` field.

**Does it work with scanned PDFs?** Yes, turn on **Add-on: OCR scanned pages**. Only pages without a text layer are read by OCR, so digital pages stay fast and cheap.

**Can it read password-protected PDFs?** Yes: type the password in **🔑 PDF password**. A wrong password gives a `wrong_password` row, which is not charged.

**Can I extract only some pages?** Yes: use **📑 Page range** (for example `1-5, 8, 12-`) or only the first or last N pages.

**Will a long PDF break the dataset?** No. A PDF too large for one row is split into one row per page automatically.

**What if a link is broken?** You get a row with `status: failed` and the reason, and it is not charged. The other PDFs keep going.

**I opened the Excel file and there are no images. Is something wrong?** No: spreadsheets hold only text. Your images are all together in **Images (ZIP)** in the Output tab, or one by one in the **Images** tab.

**My long PDF looks cut in Excel.** One Excel cell holds at most 32,767 characters. Choose **One row per page** for Excel, or download **JSON** for the full text in one piece.

### 🧩 More Actors by T800 Solutions

| Actor | What it does |
|---|---|
| [📍 Google Maps Scraper – Most Accurate Extractor](https://apify.com/t800solutions/google-maps-scraper) | Business names, phones, websites, addresses, ratings and reviews from Google Maps, across whole cities and only inside your area |
| [📹 YouTube Scraper All-in-One: Videos & Transcripts](https://apify.com/t800solutions/youtube-scraper) | Videos, Shorts, live streams, channels and playlists from YouTube, with comments and transcripts in one run |
| [📸 Instagram Scraper All-in-One: Posts & Comments](https://apify.com/t800solutions/instagram-scraper) | Public Instagram profiles, posts, reels, hashtags and comments in one run, without login |

All our Actors: [apify.com/t800solutions](https://apify.com/t800solutions) · Code examples for every Actor: [github.com/t800solutions/apify-actors](https://github.com/t800solutions/apify-actors)

### 💬 Support

Open an issue on the **Issues** tab. We answer in English.

⭐ **Happy with the results?** A short review on the **Reviews** tab helps other people find this Actor.

# Actor input Schema

## `urls` (type: `array`):

Replace the example link with links to your PDFs, one per line (up to 1,000 per run). Direct links work best, e.g. https://example.com/report.pdf. Images (JPG, PNG, TIFF, WebP) also work when OCR is on. If you also upload a file or add your own links, the example link is skipped automatically.

## `pdf_file` (type: `string`):

Upload one PDF from your computer. It is used only to process this run and is deleted right after.

## `pdf_password` (type: `string`):

Password for protected PDFs. Leave empty if your PDFs are not protected.

## `page_range` (type: `string`):

Only these pages, e.g. 1-5, 8, 12- (12- means page 12 to the end). Leave empty for all pages.

## `first_pages` (type: `integer`):

Extract only the first N pages of each PDF (0 or empty = no limit). Can be combined with the last N pages.

## `last_pages` (type: `integer`):

Extract only the last N pages of each PDF (0 or empty = no limit).

## `output_format` (type: `string`):

One row per PDF is the simplest. One row per page helps with long documents. RAG chunks are text pieces with their page numbers, ready for vector databases.

## `include_markdown` (type: `boolean`):

Headings, lists and tables rebuilt as clean Markdown, ready for ChatGPT, Claude or any LLM.

## `include_pages` (type: `boolean`):

Adds a pages list (page number, text, tables, OCR yes or no) to each PDF row.

## `extract_tables` (type: `boolean`):

Tables come out as rows and columns, and as Markdown tables.

## `chunk_size` (type: `integer`):

Only for RAG chunks.

## `chunk_overlap` (type: `integer`):

Only for RAG chunks. Text repeated between neighbour chunks, so no sentence is lost at the border.

## `ocr_scanned_pages` (type: `boolean`):

Reads pages that are images (scans) with OCR. Pages that already have text are not sent to OCR.

## `ocr_languages` (type: `array`):

Languages of your scanned pages (English by default). Pick the right one for the best accuracy; more than one for mixed documents (slower).

## `ocr_max_pages_per_pdf` (type: `integer`):

Pages read by OCR per PDF. Your maximum charge per run (set when you start the run) still protects your budget.

## `export_images` (type: `boolean`):

Exports every image inside the PDF as its own file, cleaned up: tiny icons and lines are skipped, a logo repeated on every page comes out once (with the list of pages), and JPG images keep their original quality. Each row gets the list with page, size, position and download link.

## `images_min_size_px` (type: `integer`):

Images smaller than this on their longest side are skipped (icons, bullets, dots). Not charged.

## `images_skip_duplicates` (type: `boolean`):

The same image on many pages (like a logo) is exported once, with all the pages where it appears.

## `images_format` (type: `string`):

Original keeps photos exactly as they are in the PDF, with no quality loss.

## `images_max_per_pdf` (type: `integer`):

Protects your budget on PDFs with thousands of images.

## `page_images` (type: `boolean`):

Turns each page into an image, exactly as it looks (text, tables, charts and layout). Great for AI vision models (GPT-4o, Claude, Gemini), previews and archiving.

## `page_images_dpi` (type: `integer`):

72 = small preview, 150 = screen (recommended), 200 = AI vision, 300 = print, 600 = maximum.

## `page_images_format` (type: `string`):

PNG keeps text sharpest; JPG and WebP make smaller files.

## `page_images_quality` (type: `integer`):

Only for JPG and WebP. 90 is a good balance between sharpness and size.

## `page_images_thumbnail` (type: `boolean`):

Small preview images instead of full pages.

## `page_images_max_per_pdf` (type: `integer`):

Pages above this number are not turned into images (and not charged).

## `remove_headers_footers` (type: `boolean`):

Lines that repeat at the top or bottom of most pages (like a company name or report title) are removed.

## `remove_page_numbers` (type: `boolean`):

Removes lines like '12', 'Page 12' or 'Page 12 of 40'.

## `remove_blank_lines` (type: `boolean`):

Keeps at most one blank line in a row and removes spaces at the end of lines.

## `skip_empty_pages` (type: `boolean`):

Pages with no text and no tables are left out of the result.

## `max_pages_per_pdf` (type: `integer`):

Pages above this number are not extracted (and not charged).

## `max_pdf_size_mb` (type: `integer`):

Larger files are skipped as failed rows (not charged).

## `timeout_per_pdf_secs` (type: `integer`):

If a PDF takes longer, the pages already read are delivered and the row gets a note. Long PDFs (hundreds of pages) need minutes, so keep it high.

## `max_concurrency` (type: `integer`):

How many PDFs are processed in parallel.

## `base64_pdfs` (type: `array`):

PDFs as base64 text, for API and automation users. Each item can be a base64 string or {"name": "invoice.pdf", "data": "<base64>"}.

## Actor input object example

```json
{
  "urls": [
    "https://www.w3.org/WAI/WCAG21/working-examples/pdf-table/table.pdf"
  ],
  "output_format": "document",
  "include_markdown": true,
  "include_pages": false,
  "extract_tables": true,
  "chunk_size": 1000,
  "chunk_overlap": 150,
  "ocr_scanned_pages": false,
  "ocr_languages": [
    "eng"
  ],
  "ocr_max_pages_per_pdf": 2000,
  "export_images": false,
  "images_min_size_px": 64,
  "images_skip_duplicates": true,
  "images_format": "original",
  "images_max_per_pdf": 500,
  "page_images": false,
  "page_images_dpi": 150,
  "page_images_format": "png",
  "page_images_quality": 90,
  "page_images_thumbnail": false,
  "page_images_max_per_pdf": 2000,
  "remove_headers_footers": false,
  "remove_page_numbers": false,
  "remove_blank_lines": false,
  "skip_empty_pages": false,
  "max_pages_per_pdf": 2000,
  "max_pdf_size_mb": 100,
  "timeout_per_pdf_secs": 1800,
  "max_concurrency": 3
}
```

# Actor output Schema

## `pdfs` (type: `string`):

All rows delivered by the run: source, status, pages, text, Markdown, tables and metadata.

## `summary` (type: `string`):

Status, PDFs done, PDFs failed (not charged), pages, OCR pages, amount charged so far and duration. Updated every 15 seconds while the run is going, and final at the end.

## `images` (type: `string`):

Gallery of the images and page images exported by the add-ons, grouped by PDF, each with a download button.

## `images_zip` (type: `string`):

All exported images and page images in one ZIP file, one folder per PDF. If a run has more than 200 MB of images, the rest is in images-part-02.zip and so on (links in the Images tab).

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "urls": [
        "https://www.w3.org/WAI/WCAG21/working-examples/pdf-table/table.pdf"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("t800solutions/pdf-extractor").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "urls": ["https://www.w3.org/WAI/WCAG21/working-examples/pdf-table/table.pdf"] }

# Run the Actor and wait for it to finish
run = client.actor("t800solutions/pdf-extractor").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "urls": [
    "https://www.w3.org/WAI/WCAG21/working-examples/pdf-table/table.pdf"
  ]
}' |
apify call t800solutions/pdf-extractor --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,t800solutions/pdf-extractor"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/NQlZkC4P0zBEwQxM3/builds/lnxIgrMCHmPl5Nrfp/openapi.json
