Skip to main content

API Documentation

Integrate PDF analysis into your applications with our REST API

Manage API Tokens

Your first analysis

Try a PDF analysis without an account. Add a token for your account limits and saved results.

POST/api/v1/pdf/analyze
Example Request
curl -X POST https://pdfcheck.online/api/v1/pdf/analyze \
  -H "Accept: application/json" \
  -F "file=@document.pdf"

Copy failed. Select the code and copy it manually.

Authentication
Optional
Upload limit
50 MB
Base URL
https://pdfcheck.online/api/v1

Authentication

A token is optional for PDF analysis. Account details, saved analyses and token management require a bearer token.

Treat tokens as secrets. Use an environment variable and revoke unused tokens in your account. Manage API Tokens

Example Request
curl -X POST https://pdfcheck.online/api/v1/pdf/analyze \
  -H "Accept: application/json" \
  -H "Authorization: Bearer $PDFCHECK_API_TOKEN" \
  -F "file=@document.pdf"

Copy failed. Select the code and copy it manually.

Usage and limits

Without an account: 10 analyses per day per IP address. Free: 100 per day. Pro and AI: no daily limit. Processing endpoints also have a 30-request-per-minute limit. Analysis responses include the remaining checks.

AccessDaily analysesUpload limit
No token required1050 MB
Free10050 MB
Pro / AINo daily limit100 MB

Processing endpoints also accept up to 30 requests per minute. A 429 response can mean a daily or per-minute limit.

POST/pdf/analyze

Upload and analyze a PDF file. Returns detailed metadata extracted from the PDF.

NameTypeDescription
filemultipart/form-dataRequired. PDF file to analyze: up to 50 MB for anonymous and Free users; 100 MB for Pro and AI.

Example response; values vary by document.

Example Response
{
    "success": true,
    "data": {
        "id": "example-analysis-token",
        "view_key": "example-view-key",
        "filename": "document.pdf",
        "file_size": 1048576,
        "file_size_formatted": "1.00 MB",
        "metadata": {
            "basic": {
                "pages": 10,
                "pdf_version": "1.7",
                "analysis_mode": "lightweight",
                "partial_analysis": true
            },
            "document": {
                "title": "Example document",
                "author": "Example author",
                "creator": "Microsoft Word",
                "producer": "Adobe PDF Library"
            }
        },
        "analyzed_at": "2026-09-29T12:00:00+00:00"
    },
    "remaining_checks": 9
}

Copy failed. Select the code and copy it manually.

API metadata analysis uses a bounded, lightweight mode. Detailed font, image and color analysis is skipped; metadata.basic.partial_analysis is true.

Metadata and software indicators do not prove authorship, authenticity or standards compliance.

Upload bytes are deleted after processing; analysis results and metadata may remain. See the privacy policy. Privacy policy

GET/user

Get information about the authenticated user including daily usage limits.

Token required. Example response; values vary by document.

Example Response
{
    "success": true,
    "data": {
        "name": "Example user",
        "email": "user@example.com",
        "daily_limit": 100,
        "remaining_checks": 99,
        "checks_used_today": 1
    }
}

Copy failed. Select the code and copy it manually.

GET/pdf

List all PDF analyses for the authenticated user with pagination.

Token required

Query ParametersDefaultDescription
per_page20Number of results per page (1-100)
page1integer
Example Response
{
    "success": true,
    "data": [
        {
            "id": "example-analysis-token",
            "filename": "document.pdf",
            "file_size": 1048576,
            "file_size_formatted": "1.00 MB",
            "analyzed_at": "2026-09-29T12:00:00+00:00"
        }
    ],
    "meta": {
        "current_page": 1,
        "last_page": 1,
        "per_page": 20,
        "total": 1
    }
}

Copy failed. Select the code and copy it manually.

GET/pdf/{token}

Get detailed analysis results by the analysis ID (share token).

Token required

Example Request
curl https://pdfcheck.online/api/v1/pdf/example-analysis-token \
  -H "Accept: application/json" \
  -H "Authorization: Bearer $PDFCHECK_API_TOKEN"

Copy failed. Select the code and copy it manually.

Endpoint reference

POST/pdf/extract-text

Extract text from a PDF. Send the file in the pdf field; this endpoint uses a 50 MB upload limit and returns data.pages.

Example Request
curl -X POST https://pdfcheck.online/api/v1/pdf/extract-text \
  -H "Accept: application/json" \
  -F "pdf=@document.pdf"

Copy failed. Select the code and copy it manually.

POST/pdf/to-markdown

Convert a PDF to Markdown. Send the file in the pdf field (50 MB limit). Separate allowance: 10 conversions/day for anonymous and Free users; 100/day for Pro and AI. Scanned pages may use external AI OCR. The response includes remaining_conversions.

Example Request
curl -X POST https://pdfcheck.online/api/v1/pdf/to-markdown \
  -H "Accept: application/json" \
  -F "pdf=@document.pdf"

Copy failed. Select the code and copy it manually.

Token Management

Creating tokens through the API requires an existing token. Create your first token in your account. Manage API Tokens

EndpointsDescription
GET /tokensList all API tokens for the authenticated user.
POST /tokensCreate a new API token. The token is only shown once in the response. name: string (max: 255)
DELETE /tokens/{tokenId}Revoke (delete) an API token permanently.
Example Request
curl -X POST https://pdfcheck.online/api/v1/tokens \
  -H "Accept: application/json" \
  -H "Authorization: Bearer $PDFCHECK_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"name":"My integration"}'

Copy failed. Select the code and copy it manually.

Error Codes

HTTP CodeError CodeDescription
401Unauthenticated.Invalid or missing API token
404not_foundResource not found or access denied
422message / errors
corrupted_pdf
password_protected
analysis_failed
Invalid request or PDF processing failure, including an unsupported file, upload too large, corrupted PDF or password protection
429daily_limit_exceeded
message
Daily or per-minute limit exceeded; retry when the applicable limit resets

Code Examples

Read the result from data.metadata.basic.pages. All response snippets are illustrative.

Node.js 20 or later; uses native fetch, FormData and Blob.

analyze-pdf.mjs
import { readFile } from 'node:fs/promises';

const form = new FormData();
form.append('file', new Blob([await readFile('document.pdf')], {
  type: 'application/pdf'
}), 'document.pdf');

const headers = { Accept: 'application/json' };
if (process.env.PDFCHECK_API_TOKEN) {
  headers.Authorization = `Bearer ${process.env.PDFCHECK_API_TOKEN}`;
}

const response = await fetch('https://pdfcheck.online/api/v1/pdf/analyze', {
  method: 'POST', headers, body: form
});
const result = await response.json();
if (!response.ok || !result.success) throw new Error(JSON.stringify(result));
console.log(result.data.metadata.basic.pages);
console.log(result.remaining_checks);

Copy failed. Select the code and copy it manually.

Python (requests)
Python
import os
import requests

headers = {'Accept': 'application/json'}
if os.getenv('PDFCHECK_API_TOKEN'):
    headers['Authorization'] = f"Bearer {os.environ['PDFCHECK_API_TOKEN']}"

with open('document.pdf', 'rb') as pdf:
    response = requests.post(
        'https://pdfcheck.online/api/v1/pdf/analyze',
        headers=headers,
        files={'file': ('document.pdf', pdf, 'application/pdf')},
        timeout=120,
    )
response.raise_for_status()
result = response.json()
print(result['data']['metadata']['basic']['pages'])
print(result['remaining_checks'])

Copy failed. Select the code and copy it manually.

PHP (cURL)
PHP
<?php
$headers = ['Accept: application/json'];
if ($token = getenv('PDFCHECK_API_TOKEN')) {
    $headers[] = 'Authorization: Bearer ' . $token;
}
$curl = curl_init('https://pdfcheck.online/api/v1/pdf/analyze');
curl_setopt_array($curl, [
    CURLOPT_POST => true,
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_HTTPHEADER => $headers,
    CURLOPT_POSTFIELDS => ['file' => new CURLFile('document.pdf', 'application/pdf')],
]);
$body = curl_exec($curl);
if ($body === false) throw new RuntimeException(curl_error($curl));
$status = curl_getinfo($curl, CURLINFO_HTTP_CODE);
curl_close($curl);
$result = json_decode($body, true, flags: JSON_THROW_ON_ERROR);
if ($status >= 400 || !($result['success'] ?? false)) {
    throw new RuntimeException($body);
}
echo $result['data']['metadata']['basic']['pages'];

Copy failed. Select the code and copy it manually.