Skip to Content

Pipelines

Name, version, and reuse an extraction setup.

A pipeline bundles the models, JSON Schema, and options for an extraction. Your application sends a pipeline ID instead of repeating that configuration with every document.

Create a pipeline

curl -X POST 'https://api.openparser.dev/pipelines' \
  -H 'Authorization: Bearer YOUR_API_KEY' \
  -H 'Content-Type: application/json' \
  -d '{
    "name": "Invoice fields",
    "slug": "invoice-fields",
    "ocr_model": "paddleocr-vl-1.6",
    "llm_model": "openai/gpt-6-luna",
    "schema": {
      "type": "object",
      "properties": {
        "invoice_number": { "type": "string" }
      },
      "required": ["invoice_number"],
      "additionalProperties": false
    }
  }'

The response includes an oppl_… ID and a numeric version. Store the ID in your application configuration.

Choose llm_model from GET /models/llm. The compatible model list can change over time.

Use the pipeline

Pass the pipeline ID instead of inline model, schema, and extraction options:

curl -X POST 'https://api.openparser.dev/extract/async' \
  -H 'Authorization: Bearer YOUR_API_KEY' \
  -H "Idempotency-Key: $(uuidgen 2>/dev/null || openssl rand -hex 16)" \
  -F 'request={"pipeline_id":"oppl_REPLACE_ME"};type=application/json' \
  -F 'file=@./document.pdf'

OpenParser records the current pipeline version when it accepts the job. Later edits affect new jobs only; running and completed jobs keep their original configuration.

Manage pipelines

MethodPathPurpose
GET/pipelinesList active pipelines
POST/pipelinesCreate a pipeline
GET/pipelines/{id}Get a pipeline
PATCH/pipelines/{id}Update fields and increment the version
DELETE/pipelines/{id}Soft-delete a pipeline

Names and slugs must be unique within your organization. A duplicate returns 409 pipeline_name_conflict. Deleted pipelines and IDs owned by another organization return 404 Not Found.

On this page