This page covers the most common issues you may encounter when using the Datalab API, organized by the error messages you’ll see.Documentation Index
Fetch the complete documentation index at: https://documentation.datalab.to/llms.txt
Use this file to discover all available pages before exploring further.
Authentication Errors
”Invalid API key provided”
X-API-Key header is missing or contains an invalid key.
Solution:
- Check that you’re passing the header:
X-API-Key: YOUR_KEY - Verify your key at datalab.to/app/keys
- If using the SDK, set
DATALAB_API_KEYenvironment variable or passapi_keyto the client - If the key was recently created, wait a few seconds and retry
”You need an active, paid subscription”
- Sign up for a plan at datalab.to/pricing
- If you recently signed up, check that payment was processed successfully
- Contact support@datalab.to if you believe this is in error
”Your subscription has expired”
”Your payment has failed”
Rate Limiting
”Rate limit exceeded”
- Wait and retry with exponential backoff (the SDK does this automatically)
- Reduce request frequency or spread requests over time
- For higher limits, contact support@datalab.to
”Concurrency exceeded”
”Page rate limit exceeded”
success: false
Cause: Your team has too many pages being processed concurrently across all requests. The default limit is 5,000 concurrent pages.
Solution:
- Wait for in-flight requests to complete before submitting more documents
- If you’re polling for results, back off when you see this error and retry after some results return
- If you’re using webhooks, wait for completion notifications before submitting more
- For a higher page limit, contact support@datalab.to
File Errors
”Invalid file type”
- Check Supported File Types for the full list
- Ensure the file extension matches the actual content type
- If uploading via cURL, the content type may be auto-detected from the extension
”File size exceeds upload limit”
- Split large PDFs into smaller files using page ranges
- Use the
page_rangeparameter to process specific pages - See API Limits for current limits
”File too large”
Request Errors
”Request not found”
- Results are deleted one hour after processing completes — retrieve them promptly
- Verify the request ID is correct
- Submit a new request if the results have expired
”This resource has expired”
”This request was not made by you”
Webhook Issues
Webhook not firing
Possible causes:- Webhook URL is not configured — set it at dashboard or per-request via
webhook_url - Your server is not reachable from Datalab’s servers
- Your server is returning 4xx errors (webhooks are not retried for client errors)
- Check your webhook URL is accessible from the internet
- Verify HTTPS is properly configured (self-signed certificates may cause issues)
- Check your server logs for incoming requests
- Use a tool like webhook.site to test webhook delivery
Webhook signature verification failing
Possible causes:- Using the wrong webhook secret
- Request body is being modified by middleware before verification
- Encoding issues (verify UTF-8 encoding)
Processing Issues
Conversion returns empty or poor results
Possible causes:- Scanned PDF with no OCR layer — use
mode: "accurate"for better OCR - Very complex layout — try
mode: "accurate" - File is corrupted or password-protected
- Try a different processing mode (fast → balanced → accurate)
- Check the
parse_quality_scorein the response (0-5 scale) to assess output quality - For scanned documents,
accuratemode provides the best OCR
Conversion is slow
Possible causes:- Using
accuratemode on large documents - Large file with many pages
- Use
fastorbalancedmode for lower latency - Use
page_rangeto process only the pages you need - Use
max_pagesto limit processing
Server Errors
”Database error” / “Redis error”
529 Service Overloaded
Cause: Datalab’s servers are temporarily overloaded. Solution: Wait and retry with exponential backoff. The SDK handles this automatically.Next Steps
Error Codes
Complete HTTP error code reference
API Limits
Rate limits and file size limits
Webhooks
Set up webhook notifications
SDK Reference
SDK with built-in error handling and retries