PDF to JSON Parser avatar

PDF to JSON Parser

Under maintenance

Pricing

Pay per event

Go to Apify Store
PDF to JSON Parser

PDF to JSON Parser

Under maintenance

Convert PDF documents into structured JSON. Extracts text, tables, and fields from any PDF URL. Flip on AI Structuring to turn the raw text into clean, organized JSON ready for automation or analysis. No API key needed.

Pricing

Pay per event

Rating

0.0

(0)

Developer

BowTiedRaccoon

BowTiedRaccoon

Maintained by Community

Actor stats

0

Bookmarked

2

Total users

1

Monthly active users

2 days ago

Last modified

Share

Convert PDF documents into structured JSON. Supply a list of public PDF URLs — the actor downloads each file, extracts text from every page, and returns clean, organized output. Flip on AI Structuring to turn that raw text into categorized JSON fields. No API key, no setup.

What it does

  • Accepts a list of public PDF URLs (up to 50 MB per file)
  • Downloads each PDF to temporary storage and extracts text per page using native PDF parsing
  • Processes every page for complete coverage — no pages skipped
  • Optionally runs an AI structuring pass that organizes the raw text into titled sections, tables, key fields, and metadata
  • Returns one dataset record per PDF with the full extracted text, per-page breakdown, and AI output
  • Saves error records for PDFs that fail to download or parse — the run continues

Use cases

  • Invoice and receipt extraction for accounting automation
  • Contract and legal document analysis
  • Academic paper indexing and summarization
  • Form data extraction from government or regulatory PDFs
  • Report parsing for data pipelines
  • Bulk document conversion for RAG / LLM pipelines

Input

FieldTypeRequiredDescription
pdfUrlsArrayYesPublic PDF URLs to process. Must be directly downloadable.
aiStructuringBooleanNoTurn raw text into structured JSON using AI. Off by default; costs more per PDF.
extractionPromptStringNoWhat the AI should pull out. Blank uses a general document prompt. Only used when AI Structuring is on.
maxItemsIntegerNoMaximum PDFs to process per run. Default: 15.

Output

One dataset record per PDF:

FieldTypeDescription
sourceUrlStringOriginal PDF URL
pageCountNumberNumber of pages in the PDF
rawTextStringFull extracted text (all pages concatenated)
pagesStringJSON array of per-page text: [{"page": 1, "text": "..."}]
structuredJsonStringAI-structured output as JSON string (null unless AI Structuring was on)
aiStructuredBooleanTrue when the AI pass ran and produced output
modelStringModel used for the AI pass (null when not used)
processedAtStringISO timestamp when processing completed
statusStringsuccess or error
errorMsgStringError message on failure, null on success

Example record (text extraction only — the default)

{
"sourceUrl": "https://example.com/invoice-2024-01.pdf",
"pageCount": 2,
"rawText": "Invoice #INV-2024-001\nDate: January 15, 2024\n...",
"pages": "[{\"page\":1,\"text\":\"Invoice #INV-2024-001...\"},{\"page\":2,\"text\":\"Payment terms...\"}]",
"structuredJson": null,
"aiStructured": false,
"model": null,
"processedAt": "2026-08-04T12:00:00.000Z",
"status": "success",
"errorMsg": null
}

Example record (with AI Structuring on)

{
"sourceUrl": "https://example.com/invoice-2024-01.pdf",
"pageCount": 2,
"rawText": "Invoice #INV-2024-001\nDate: January 15, 2024\n...",
"pages": "[{\"page\":1,\"text\":\"Invoice #INV-2024-001...\"}]",
"structuredJson": "{\"title\":\"Invoice #INV-2024-001\",\"date\":\"January 15, 2024\",\"key_fields\":{\"invoice_number\":\"INV-2024-001\",\"amount\":\"$1,250.00\"}}",
"aiStructured": true,
"model": "gpt-4o-mini",
"processedAt": "2026-08-04T12:00:00.000Z",
"status": "success",
"errorMsg": null
}

Pricing

$0.10 per run start, then per PDF:

Per PDF
Text extraction (default)$0.015
With AI Structuring on$0.030

You only pay the higher rate on PDFs where the AI pass actually produced structured output. If the AI call fails, that PDF drops to the text-extraction rate and you still get rawText and pages.

No API key to obtain, and no separate vendor bill.

Notes

  • Native extraction works on any text-based PDF (invoices, reports, forms, contracts). Scanned image-only PDFs return empty text — OCR for image PDFs is not currently supported.
  • AI structuring is additive. Even when the AI call fails (rate limit, network error), the actor returns the native extraction record with structuredJson: null rather than failing the run.
  • Custom prompts let you tailor the structuring output for a specific document type. For example: "Extract all line items as an array of {description, quantity, unit_price, total}".
  • File size limit: 50 MB per PDF. Larger files are rejected with an error record.