How to integrate the Parashift Platform

Learn how to integrate the Parashift platform efficiently by leveraging available resources, understanding key concepts, and following simple steps to upload documents and retrieve processed data.

Key Resources

Before you begin, familiarize yourself with these resources:

User Guide Users & Configurators For document validation and configuration.
API Documentation Developers Full endpoint documentation with examples.

Key Concepts

Understand these fundamental concepts to ensure a seamless integration:

  • Workflows: Document classification, extraction, and processing steps.
  • Relationships: Links between batches, documents, pages, and fields.
  • Data Schemas: Structure and format of the extracted data.

Integration Requirements

Ensure you have:

  1. API Key – Obtain from your tenant for authentication (Managing API keys)
  2. Tenant ID – Required for API endpoints.

  3. Example Document – Convert files to base64 using e.g. base64.guru.

API Basics

All API requests follow the JSON API Standard. The base URL is https://api.parashift.io/v2/

Add these headers to every request:

Key Value Description
Content-Type application/vnd.api+json Must be exact; otherwise a 406 error occurs
Authorization Bearer [your API Key] Replace [Your API Key] with your key

Tip: Use tools like Postman to test and send your API requests quickly.

Upload your first document

Send a POST request to the /documents endpoint:

curl --location --request POST 'https://api.parashift.io/v2/documents' \
--header 'Content-Type: application/vnd.api+json' \
--data '{
"data": {
"type": "documents",
"attributes": {
"files": [
{
"file_name": "YourFileName.pdf",
"base64_file": "YourBase64File"
}
]
}
}
}'

Response: Save the document ID from the 201 Created response.

Retrieve Document Data

Check the document’s status and fetch the results:

curl --location --request GET 'https://api.parashift.io/v2/documents/[Document_ID]' \
--header 'Content-Type: application/vnd.api+json' \
--header 'Authorization: Bearer [Your API Key]'

Example Response

{
    "data": {
        "id": "1633723",
        "type": "documents",
        "attributes": {
            "batch_id": "1633723",
            "batch_index": 0,
            "classification_lower_threshold": 0,
            "classification_upper_threshold": 1,
            "created_at": "2022-06-17T08:01:50.016934Z",
            "custom_fields": {},
            "document_type_identifier": null,
            "error_codes": [],
            "exported_at": null,
            "external_id": null,
            "language": null,
            "language_confidence": null,
            "name": "#1633723",
            "not_for_training": false,
            "recognition_confidence": null,
            "sla_deadline": null,
            "status": "pending",
            "tenant_id": "543",
            "updated_at": "2022-06-17T08:01:50.427226Z",
            "upload_configuration": "client",
            "validation_required": true,
            "workflow_status": "started",
            "workflow_step": "inbound"
        },
        "relationships": {
            "comments": {
                "links": {
                    "related": "api.parashift.io/v2/comments?filter[document_id]=1633723"
                }
            },
            "document_fields": {
                "links": {
                    "related": "api.parashift.io/v2/document_fields?filter[document_id]=1633723"
                }
            },
            "output_files": {
                "links": {
                    "related": "api.parashift.io/v2/files?filter[document_id]=1633723&filter[file_type]=output_file"
                }
            },
            "pages": {
                "links": {
                    "related": "api.parashift.io/v2/pages?filter[document_id]=1633723"
                }
            }
        }
    },
    "meta": {}
}

Status Codes

  • done: Document fully processed.
  • in_progress: Processing still underway or awaiting validation.

Fetch Extracted Fields

To retrieve specific field data, such as identifier, value, and confidence, include document_fields:

curl --location --request GET 'https://api.parashift.io/v2/documents/[Document_ID]?include=document_fields&fields[document_fields]=identifier,value,confidence' \
--header 'Authorization: Bearer [Your API Key]'

Example Output

{
    "included": [
        {
            "attributes": {
                "identifier": "pp-subject",
                "value": "Awesome First Integration",
                "confidence": 0.98221
            }
        }
    ]
}

Troubleshooting & Notes

  • Use the correct headers, especially Content-Type: application/vnd.api+json.
  • If an error occurs, verify your API Key and request format.
  • Read up on advanced workflows, relationships, and field attributes in the full API documentation.

Need Help

If you encounter any issues or need further guidance, feel free to contact us at support@parashift.io. Our support team is available as part of your support package