Document to JSON – PDF Invoice/Statement/Contract Parser

io.github.fashionmascherine-svg由 GitHub 帳號 fashionmascherine-svg 發布v1.0.0更新於 Oct 24, 2026

Turn any PDF into structured JSON via AI + OCR: invoices, bank statements, contracts.

發布方自己的服務:Parser Club

已驗證Streamable HTTP可網頁執行檔案與儲存資料與分析

概覽

AI 產生的概覽

由 Apify 託管的 MCP 伺服器,透過 AI 與 OCR 將 PDF 發票、銀行對帳單、合約及一般文件轉為結構化 JSON。

可以做什麼
解析發票,輸出賣方、買方、明細項目、合計、營業稅、IBAN 與付款資訊等 JSON,並可驗證合計與日期。解析銀行對帳單,擷取交易、餘額、手續費與帳戶持有人資訊。解析合約,擷取當事方、關鍵條款、日期、財務條件與管轄地。從任意一般文件中擷取全文與表格,推出期間免費。文件透過公開 PDF 網址讀取,結果以 JSON 回傳。
適用情境
適合需要把 PDF 發票、對帳單或合約轉成結構化資料,用於記帳、試算表整理、法務審閱或自動化流程的情境,也支援英文、義大利文與西班牙文的掃描檔。
執行需求
遠端 MCP 端點位於 mcp.apify.com,透過 streamable HTTP 存取。需要 Apify 帳戶,並在 Authorization 標頭中以 Bearer 形式提供 Apify API 權杖。PDF 必須可透過公開網址存取。需要能連線至 Apify 的網路。
安裝前請注意
每次擷取依文件透過 Apify 計費(發票 0.01 美元、銀行對帳單 0.015 美元、合約 0.02 美元,一般文件推出期間免費),使用會產生費用。Apify API 權杖屬於機密,須妥善保管。PDF 從公開網址取得並送往 Apify 的 AI 處理;README 稱擷取後不儲存檔案,但文件內容會離開本機。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Document to JSON – PDF Invoice/Statement/Contract Parser,將其新增到工作區。
  2. 連接 所需的 憑證。它們會被私密儲存,絕不會在公開頁面上展示。
  3. 為需要使用其工具的對話啟用該服務。

Web executable,透過 Streamable HTTP。 遠端服務在工作區中設定後即可從網頁執行環境執行。

交給代理程式安裝

把這段提示詞貼上到 Claude Code、Codex、Cursor 等代理程式,或 SourceWeft 對話中。代理程式會讀取該伺服器的安裝指南,先向你展示發布者、端點和登入方式,經你同意後再把它新增到你的客戶端。金鑰不會寫進任何命令。

閱讀 https://sourceweft.com/mcp/io.github.fashionmascherine-svg%2Fdocument-to-json-mcp/install.md,並按其中說明把這個 MCP 伺服器接入我的客戶端。修改任何設定之前,先告訴我它的發布者、端點和登入方式,等我確認。不要把 API 金鑰寫進命令或我會提交的檔案;問我金鑰應從哪裡取得。

檢視代理程式所依據的安裝指南

其他 MCP 客戶端

把它新增到你客戶端的 mcpServers 設定中。 客戶端會在首次連接時完成 OAuth 登入。

{
  "mcpServers": {
    "document-to-json-pdf-invoice-statement-c": {
      "type": "http",
      "url": "https://mcp.apify.com/?actors=opportunity-biz/document-to-json-mcp"
    }
  }
}

README

Document-to-JSON Converter

Turn PDFs into structured JSON in seconds. AI-powered, no coding needed.

[MCP Server] [License: MIT] [Apify]


🚀 What does it do?

Paste a PDF URL → get structured JSON. That's it.

Powered by AI. Instead of rigid templates or fragile regex, an AI model actually reads and understands each document — so it adapts to any layout, language, or vendor, and even handles scanned files. That's why the same tool works on an Italian invoice, a Spanish receipt, or an English contract without any configuration.

Perfect for:

  • Accountants — extract invoice data (numbers, dates, totals, VAT, IBAN)
  • Developers — automate document processing in your apps
  • Business analysts — convert bank statements to spreadsheets
  • Legal teams — extract contract clauses and dates automatically

📋 Supported documents

TypeWhat you getPrice
InvoiceSeller, buyer, line items, totals, VAT, IBAN, payment info$0.01
Bank StatementAll transactions, balances, fees, account holder$0.015
ContractParties, key clauses, dates, financial terms, jurisdiction$0.02
GenericFull text + tables from any documentFree during launch

✨ Example output

json
{  "success": true,  "data": {    "document_type": "invoice",    "confidence": 0.97,    "metadata": {      "invoice_number": "INV-2024-00123",      "invoice_date": "2024-03-15",      "currency": "EUR"    },    "seller": {      "name": "Acme S.p.A.",      "vat_id": "IT01234567890"    },    "line_items": [      {        "description": "Consulting services",        "quantity": 1,        "unit_price": 5000.00,        "net_amount": 5000.00,        "vat_rate": 22.0,        "total": 6100.00      }    ],    "totals": {      "net_total": 5000.00,      "vat_total": 1100.00,      "grand_total": 6100.00    },    "payment_info": {      "iban": "IT60X0542811101000000123456"    }  }}

🧪 Live examples — try them now

Run the Actor on these public sample PDFs (synthetic data) to see the extraction quality for yourself:

TypeSample PDFWhat the AI extracts (highlights)
Invoicesample-invoice.pdfInvoice INV-2026-0042, seller + buyer with VAT IDs, 2 line items, VAT 22%, grand total €1,889.78 — confidence 1.0
Bank statementsample-bank-statement.pdf7 transactions auto-categorized, opening/closing balances reconciled to €8,655.28 — confidence 1.0
Contractsample-contract.pdf2 parties + roles, effective/expiry/renewal dates, fee €5,000, 5 key clauses with summaries, jurisdiction — confidence 0.95

Just paste one of these URLs as file_url, pick the matching document_type, and run. Each extraction takes ~15–20 seconds.

🎯 Why this Actor?

FeatureBenefit
AI understandingAn AI reads documents like a human — adapts to any layout, no templates or rules to maintain
Multi-languageEnglish, Italian, Spanish (OCR)
OCR includedWorks with scanned documents too
ValidationAuto-checks totals and dates for accuracy
Pay per useNo subscription, pay only for what you process

🔧 How to use

  1. Get a public PDF URL (Dropbox, Google Drive, your server)
  2. Select the document type
  3. Run the Actor
  4. Get your JSON in seconds

That's it. No configuration, no API keys needed.

💰 Pricing

Document typePrice
Invoice$0.01 ($10/1000)
Bank statement$0.015 ($15/1000)
Contract$0.02 ($20/1000)
GenericFree during launch

Pay-per-event via Apify. Pay only for successful extractions. No subscription, no hidden fees.

🔒 Privacy

  • PDFs are processed and not stored after extraction
  • Data is available in your private dataset
  • All API keys stay encrypted

📚 Supported OCR languages

eng (English), ita (Italian), spa (Spanish)

Combine with + for multi-language scanned documents: eng+ita+spa (default)

🤖 Built for AI agents (MCP)

This Actor is an MCP server: AI agents can call it directly as a tool to turn any PDF into JSON, with zero configuration — just pass a public file_url. Specialized tools (parse_invoice, parse_bank_statement, parse_contract) and a free parse_generic_document make it easy for an LLM to pick the right one for the task.

🔌 Integrations

Replace YOUR_APIFY_TOKEN with your token from Apify → Settings → Integrations.

Claude Code (CLI)

bash
claude mcp add --transport http apify \  "https://mcp.apify.com/?actors=opportunity-biz/document-to-json-mcp"

Claude Desktop / Cursor (MCP)

Add to your MCP config (claude_desktop_config.json or Cursor's mcp.json):

json
{  "mcpServers": {    "document-to-json": {      "command": "npx",      "args": [        "-y", "mcp-remote",        "https://mcp.apify.com/?actors=opportunity-biz/document-to-json-mcp",        "--header", "Authorization: Bearer YOUR_APIFY_TOKEN"      ]    }  }}

The agent then sees parse_invoice, parse_bank_statement, parse_contract, and parse_generic_document as tools and calls them on its own.

REST API (any language)

One call in, JSON out — run-sync-get-dataset-items returns the result directly:

bash
curl -X POST \  "https://api.apify.com/v2/acts/opportunity-biz~document-to-json-mcp/run-sync-get-dataset-items?token=YOUR_APIFY_TOKEN" \  -H "Content-Type: application/json" \  -d '{"file_url": "https://example.com/invoice.pdf", "document_type": "invoice", "validate_totals": true}'

Python

python
from apify_client import ApifyClient
client = ApifyClient("YOUR_APIFY_TOKEN")run = client.actor("opportunity-biz/document-to-json-mcp").call(run_input={    "file_url": "https://example.com/invoice.pdf",    "document_type": "invoice",})for item in client.dataset(run["defaultDatasetId"]).iterate_items():    print(item)

JavaScript / TypeScript

javascript
import { ApifyClient } from 'apify-client';
const client = new ApifyClient({ token: 'YOUR_APIFY_TOKEN' });const run = await client.actor('opportunity-biz/document-to-json-mcp').call({  file_url: 'https://example.com/invoice.pdf',  document_type: 'invoice',});const { items } = await client.dataset(run.defaultDatasetId).listItems();console.log(items);

n8n

Use an HTTP Request node (POST) to the REST API URL above, or the official Apify node → select document-to-json-mcp → set file_url and document_type. Great for "watch inbox → extract invoice → append to Google Sheet" workflows.

LangChain / CrewAI / any MCP framework

Point your agent framework's MCP client at https://mcp.apify.com/?actors=opportunity-biz/document-to-json-mcp — the parsing tools are exposed automatically.

來源:README.md,提交 2580cf9

工具

0
該伺服器需要登入,因此 SourceWeft 無法在沒有帳號的情況下讀取其工具,也未收錄。已連接帳號所能看到的內容可能因帳號及其權限而異。

版本歷史

1
  1. v1.0.0最新Sep 16, 2026

評分

已滿足適用檢查項的 85%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通必需25 分
  • 已宣告認證方式必需10 分
  • 已列出工具15 分

    請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。

  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分

其他 Parser 整合