API Reference

Base URL: https://api.parseloom.com/v1

Authentication

All API requests require an API key sent in the Authorization header as a Bearer token.

Authorization: Bearer sk_live_your_api_key_here

API keys are available in your account dashboard under Settings > API Keys. Generate a separate key per integration for easier revocation. Test keys (sk_test_) are rate-limited to 10 req/min and extractions do not count against your monthly page quota.

POST /v1/extract

Submit a document for extraction. Returns a JSON object with extracted fields.

Request

Content-Type: multipart/form-data

curl -X POST https://api.parseloom.com/v1/extract \
  -H "Authorization: Bearer sk_live_..." \
  -F "[email protected]" \
  -F "template=invoice_standard"
ParameterTypeRequiredDescription
filefileYesPDF, TIFF, PNG, or JPEG. Max 20 MB per file.
templatestringYesTemplate ID or slug. Use invoice_standard, bol_standard, or a custom template ID.
webhook_urlstringNoPOST destination for async delivery. If omitted, response is synchronous (max 30s).

Response

{
  "extraction_id": "ext_9f2a4d8c",
  "status": "complete",
  "template": "invoice_standard",
  "pages_processed": 2,
  "fields": {
    "vendor_name": "Acme Supplies LLC",
    "invoice_number": "INV-20260601-00441",
    "invoice_date": "2026-06-01",
    "due_date": "2026-06-30",
    "subtotal": 3900.00,
    "tax_amount": 282.00,
    "total_amount": 4182.00,
    "line_items": [
      { "description": "Office furniture", "qty": 4, "unit_price": 975.00 }
    ]
  },
  "confidence": {
    "overall": 0.97,
    "low_confidence_fields": []
  }
}

Webhooks

Webhooks deliver extraction results to your endpoint as soon as processing completes. Use them for batch processing or when document size exceeds the 30-second sync window.

Parseloom signs each webhook payload with a shared secret. Verify the X-Parseloom-Signature header against an HMAC-SHA256 of the raw body using your webhook secret.

POST https://your-endpoint.com/parseloom-hook
Content-Type: application/json
X-Parseloom-Signature: sha256=abc123...

{
  "event": "extraction.complete",
  "extraction_id": "ext_9f2a4d8c",
  "fields": { ... }
}

Field schemas

You can override the field output schema per request, or set a default schema per template. Schema fields define the name, type, and required status of each extracted field.

{
  "schema": [
    { "name": "vendor_name",   "type": "text",       "required": true },
    { "name": "invoice_date",  "type": "date",        "required": true },
    { "name": "total_amount",  "type": "currency",    "required": true },
    { "name": "line_items",    "type": "table",
      "columns": ["description", "qty", "unit_price"]
    }
  ]
}

Templates API

List, create, and manage your extraction templates via API. All template operations require a Professional or Scale plan.

MethodEndpointDescription
GET/v1/templatesList all templates in your account
GET/v1/templates/:idGet a single template with field definitions
POST/v1/templatesCreate a new template (requires training examples)
PATCH/v1/templates/:idUpdate template name or field schema
DELETE/v1/templates/:idArchive a template (extractions continue for 30 days)

Errors

The API uses standard HTTP status codes. Error responses include a machine-readable code and a human-readable message.

CodeHTTPMeaning
auth_invalid401Missing or invalid API key
template_not_found404Template ID does not exist in your account
file_unreadable422File is corrupt, password-protected, or unsupported format
extraction_failed422Extraction ran but returned no fields - page not billed
quota_exceeded429Monthly page quota reached for your plan
rate_limited429Per-minute request rate exceeded

Rate limits

Limits apply per API key. Burst allowance: 2x the per-minute limit for up to 10 seconds.

PlanRequests/minPages/month
Starter10100
Professional605,000
Scale300Unlimited
Test key10Not counted