Back to Blog

PDF Processing API Integration Guide

Why Use the PDFDrill API?

Upload a PDF, check its job status and download available outputs. Business API eligibility or explicitly enabled Enterprise API access is required; having a key alone does not bypass plan or page-allowance checks. General document output is not a balance-checked bank ledger.

Getting Started

1. Get Your API Key

  1. Use an account eligible for Business API access
  2. Navigate to the API-key section in Settings
  3. Generate a key if API access is enabled
  4. Store it securely (it won't be shown again)

2. Authentication

All API requests require authentication via Bearer token:

Send your own PDFDrill key as a Bearer token to the routes on https://pdfdrill.com. Keep it out of source control and browser code.

Core Endpoints

Upload and Convert

POST /api/api/upload with a multipart file. The response includes id, status, output_types and result_paths. Upload does not accept a file_url or a format field selecting conversion options.

Check Job Status

GET /api/api/jobs/{id}. Wait for status done; handle error instead of assuming processing succeeded.

Download Results

GET /api/api/jobs/{id}/download?output_type=csv, or another available output type. The response is the file bytes, not a JSON download URL. Supported type names are text, excel, csv, json, images and ocr; a job may not have every artifact.

The current API documentation includes request examples, job fields and error handling.

Webhooks

Upload may include webhook_url and an optional webhook_secret. The URL is validated; webhook_secret requires webhook_url. Follow the timestamp/signature verification instructions in the API documentation. A webhook is not permission to skip authorization or source review.

Rate Limits

Handle rate-limited responses, upload-size limits, page allowance and plan eligibility. Do not assume that a lower-tier account can use the API or that a particular concurrency allowance is promised.

Error Handling

Check HTTP status before decoding a response. Handle unavailable output, expired results and failed jobs. Do not log document contents or authorization headers.

Best Practices

1. Use Async Processing

Uploads create asynchronous jobs. Poll job status or use a validated webhook URL.

2. Implement Retries

Back off when retrying status reads. An upload retry can create a second job and consume additional allowance; inspect the original job before submitting again.

3. Validate Input

Check file types and sizes before uploading to avoid wasted API calls.

4. Cache Results

Store converted files to avoid re-processing identical documents.

Review structured output

JSON fields depend on the document. Custom schemas are not offered. Verify important values against the source and handle missing fields in your application.

For bank statements, follow the bank statement PDF to Excel guide. Generic API text or JSON should not be described as an accounting-ready ledger.

Conclusion

Use the supported upload, status and download flow, and keep extracted content within a review workflow.

Share this article:

Ready to Try PDFDrill?

Convert a bank statement into a balance-checked Excel or CSV file. 10 pages free every month.

Start free (10 pages a month)