docsapi_key

Nanonets OCR

Nanonets OCR extracts structured data from documents using trained, model-based OCR workflows.

Verdict

Nanonets OCR lets your team extract structured data from invoices, receipts, contracts, and forms without writing parsers. @mention it to pull line items from a PDF URL, retrieve past extraction results by date range, or check which OCR models your account has trained. Designers and ops teams get the most value—they can turn scanned documents into spreadsheet rows or validate vendor invoices against POs in seconds. The API-key setup is straightforward, but you'll need a Nanonets account with at least one trained model before extraction works.

Common use cases

  • Extract invoice line items into spreadsheets
  • Validate expense receipts against policy rules
  • Pull contract dates and parties for review
  • Audit past extractions by date range
  • Check OCR model accuracy before production

Integration

Vendor
Nanonets OCR
Category
docs
Auth
API_KEY
Tools
6
Composio slug
nanonets_ocr

Tools

  • Extract From Public URL

    Synchronously extract model-defined fields and tables from one publicly reachable document URL. Returns durable page and file IDs even when the model finds no matching fields.

  • Get OCR Model

    Get readiness, accuracy, extraction fields, and table configuration for one Nanonets OCR model.

  • Get OCR Prediction File

    Get normalized extraction results for every page of one previously processed Nanonets OCR file. A successful page can have no extracted fields.

  • Get OCR Prediction Page

    Get normalized extracted fields and tables for one OCR prediction page.

  • List OCR Models

    List the OCR models available to the connected Nanonets account, including each model's ID, readiness state, and extraction categories.

  • List OCR Predictions

    List compact OCR prediction-page summaries for a model within an inclusive UTC date range. Nanonets returns the entire matching range without pagination, so prefer narrow ranges when a model has substantial history.

Setup

Setup guide

  1. 11. Open your Switchy workspace settings and navigate to the Integrations tab. 2. Click 'Add Integration' and select Nanonets OCR from the list. 3. Log in to your Nanonets dashboard, go to API Keys under your account menu, and copy your API key. 4. Paste the key into Switchy's auth dialog and click Connect. 5. Switchy will verify the key by listing your OCR models—if you see model IDs, the connection succeeded. 6. Inside any Project, create a new chat and type '@Nanonets list my OCR models' to confirm the integration responds. 7. To extract data, share a public document URL (Dropbox, Google Drive, S3) and prompt '@Nanonets extract fields from [URL] using model [model_id]'. 8. The response includes extracted fields, tables, and page-level confidence scores you can review or export.

What teammates see: by default, memories from Nanonets OCR are scoped to the Project (PROJECT visibility) - you can mark any memory PRIVATE or share it ORG-wide.

Works well with

Top models

Compatibility data appears once enough Projects have used this MCP together with a given model.

How Switchy teams use it

Not enough Projects yet to publish anonymised usage stats (we require ≥ 50 Projects per week).

Starter prompts

List Available Models

@Nanonets list all my OCR models and tell me which ones are ready for production use.

Extract Invoice Fields

@Nanonets extract fields from https://example.com/invoice.pdf using model abc123 and format the line items as a table.

Retrieve Past Predictions

@Nanonets list all OCR predictions for model abc123 between 2025-01-01 and 2025-01-31 and summarize the document types.

Check Model Configuration

@Nanonets get details for OCR model abc123 and show me which fields it extracts and the current accuracy score.

Review Specific Page

@Nanonets get OCR prediction for page xyz789 and highlight any fields with confidence below 90%.

Example outputs

Illustrative - representative of the model's voice and quality, not literal recordings.

Prompt

@Nanonets OCR list all my OCR models and show me which ones are ready to extract invoices or receipts

Output

The account has 4 OCR models configured. Two are production-ready: 'Invoice Extractor v2' (model ID: inv_9x3k) extracts vendor name, invoice number, line items, and totals; 'Receipt Parser' (model ID: rcp_4m1a) extracts merchant, date, and amount. 'Expense Report Beta' is still training (78% accuracy). 'Purchase Order Draft' has no training data yet. Both ready models support table extraction for line-item details.

Notes

This example shows how the List OCR Models tool surfaces model readiness and extraction scope before you commit a document. Useful when you inherit a Nanonets account or need to route different document types to different models. Requires a valid API key with read access to all models in the workspace.

Prompt

@Nanonets OCR extract all fields from this invoice PDF https://example.com/invoice-2024-Q4.pdf using my invoice model

Output

Processed 3 pages from invoice-2024-Q4.pdf (file ID: file_7h2p). Page 1 extracted: Vendor='Acme Supplies Inc.', Invoice Number='INV-2024-1847', Date='2024-12-15', Total='$4,287.50', and a 12-row line-item table with descriptions, quantities, and unit prices. Pages 2–3 contained terms and conditions; no additional fields extracted. Confidence scores range from 0.91 to 0.98 for all extracted values.

Notes

The Extract From Public URL tool runs synchronously, so large multi-page documents may time out. Nanonets returns durable file and page IDs even when confidence is low or no fields match the model's schema. You can later call Get OCR Prediction Page to retrieve per-page details or re-check extraction after model retraining.

Prompt

@Nanonets OCR pull the last 30 days of receipt predictions from my expense model and draft a spend summary by merchant category

Output

Retrieved 47 receipt predictions from the past 30 days (model: rcp_4m1a). Top spending categories: Meals & Entertainment $1,823 (18 receipts), Office Supplies $1,104 (12 receipts), Travel & Lodging $987 (9 receipts), Software Subscriptions $640 (5 receipts), Miscellaneous $203 (3 receipts). Total extracted spend: $4,757. Note: 4 receipts had low-confidence merchant names and were grouped under Miscellaneous. Consider reviewing file IDs file_9k3x, file_2p7n for manual validation.

Notes

This synthesis example pairs List OCR Predictions (which fetches compact summaries over a date range) with the AI's categorization logic. Nanonets returns all matching predictions without pagination, so narrow your date range if the model processes hundreds of documents daily. The AI flags low-confidence extractions, prompting human review before financial reconciliation.

Use-case deep-dives

Invoice processing for 3-person accounting team

When Nanonets OCR beats manual invoice entry at small scale

A 3-person accounting team processing 40-80 vendor invoices a week hits the sweet spot for this MCP. One person trains a Nanonets model on the five invoice layouts they see most often—vendor name, date, line items, total—then the team uses Switchy to extract fields from new PDFs as they arrive in Slack or email. The Extract From Public URL tool pulls structured data in under 10 seconds, and the team reviews extracted fields in the same chat thread where they discuss payment approval. This works because Nanonets handles layout variance better than regex scripts, and 80 invoices a week justifies the API cost without needing a full AP automation platform. If your invoice volume drops below 20 a week or you need real-time processing inside an ERP, the setup overhead outweighs the time saved.

Customer support ticket attachment triage

Using OCR predictions to route support docs faster

A 6-person support team receives 200 tickets a day, and 30 percent include scanned forms, screenshots, or PDFs that need manual review before routing. They configure a Nanonets model to extract claim numbers, account IDs, and issue categories from the five most common document types, then use Switchy to run Get OCR Prediction File on new attachments during ticket intake. The MCP returns structured fields within seconds, and the team uses those fields to tag tickets and assign them to the right specialist without opening every PDF. This cuts first-response time by 15 minutes per ticket when the document matches a trained layout. The trade-off: if more than half your attachments are one-off formats or handwritten notes, Nanonets accuracy drops below 70 percent and manual review becomes faster than fixing bad extractions.

Contract clause extraction for legal ops

When Nanonets OCR makes sense for recurring contract review

A 2-person legal ops team reviews 15-25 vendor contracts a month, each 8-12 pages, looking for liability caps, termination clauses, and renewal terms. They train a Nanonets model on their standard contract template and three common vendor formats, then use Switchy to extract those clauses from new PDFs before redline review. The Get OCR Model tool shows which fields the model reliably finds, and the team uses List OCR Predictions to audit extraction accuracy over the prior 30 days. This setup works because the contract formats repeat and the team needs structured data for a compliance dashboard, not just search. If your contracts are one-off MSAs with no layout consistency, or you process fewer than 10 a month, a paralegal with Ctrl+F is faster and cheaper than training and maintaining an OCR model.

Frequently asked

What does the Nanonets OCR MCP do in Switchy?

It extracts structured data from documents—invoices, receipts, forms—using your trained Nanonets models. The MCP pulls field values and tables from PDFs or images via public URLs, then surfaces the results in Switchy conversations. You get the same extraction accuracy Nanonets delivers through their web UI, but your team can query and act on document data without leaving the workspace.

Do I need admin access to connect Nanonets OCR?

You need a Nanonets API key, which any account member can generate from the Nanonets dashboard under API settings. The key grants read and write access to all models in that account, so treat it like a password. If your Nanonets plan restricts API access to certain roles, check with your account owner before connecting.

Can the MCP train or retrain OCR models?

No. The MCP reads existing models and runs predictions against them—it cannot upload training documents, annotate fields, or trigger retraining. You still configure extraction fields and tables in the Nanonets web UI. Once a model is trained and active, Switchy can send documents to it and retrieve the structured output.

How does this compare to uploading documents to Nanonets directly?

The MCP automates what you'd otherwise do manually: paste a document URL into Nanonets, wait for extraction, then copy results into Slack or a spreadsheet. In Switchy, an AI agent can trigger extraction mid-conversation, compare outputs across models, or route extracted data to another tool—all without tab-switching. You trade the Nanonets UI's annotation features for workflow speed.

Does running OCR through Switchy count against my Nanonets page quota?

Yes. Every document the MCP sends to Nanonets consumes pages from your plan's monthly allowance, exactly as if you'd processed it through the web UI or API. Switchy does not cache or deduplicate requests, so if an agent extracts the same invoice twice, Nanonets bills two pages. Monitor usage in your Nanonets dashboard to avoid overage charges.

More docs MCPs

See all docs MCPs →

Data last verified 61 hours ago.Sources aggregated hourly to weekly. See docs/architecture/model-directory.md.