Référence de l'API

API Workflow

Tous les points de terminaison nécessitent une session connectée (cookie) sauf indication contraire. Les réponses sont en JSON : { ok: true, data } ou { ok: false, error }. Erreurs courantes : 400 validation, 401 non authentifié, 403 interdit, 404 introuvable, 429 limitation de débit, 502/503 en amont. Les points de terminaison publics /api/v1 s'authentifient avec Authorization: Bearer pdflean_… et doivent envoyer un type de contenu JSON.

Sur cette page

Workflows

MéthodeCheminDescription
GET/api/workflowsLister vos workflows
POST/api/workflowsCréer un workflow (brouillon)
GET/api/workflows/:idObtenir un workflow
PUT/api/workflows/:idMettre à jour un workflow (brouillon, version+1)
DELETE/api/workflows/:idSupprimer un workflow
POST/api/workflows/:id/publishPublier une version
GET/api/workflows/:id/versionsLister les versions
POST/api/workflows/:id/versions/:version/restoreRestaurer une version

Déclencheurs & Hooks

MéthodeCheminDescription
GET/api/workflows/triggersLister les déclencheurs
POST/api/workflows/triggersCréer un déclencheur (webhook/planification/e-mail/drive)
POST/api/workflows/triggers/:id/runExécuter un déclencheur maintenant
DELETE/api/workflows/triggers/:idSupprimer un déclencheur
POST/api/workflows/hook/:tokenWebhook entrant (auth par token, sans session ; corps JSON)

Exécutions & Revues

MéthodeCheminDescription
POST/api/workflows/runsCréer une exécution (en file d'attente)
GET/api/workflows/runsLister les exécutions
GET/api/workflows/runs/:idDétails de l'exécution et des étapes
POST/api/workflows/runs/:id/retryRéessayer une exécution échouée/en file d'attente
GET/api/workflows/reviewsRevues humaines en attente
POST/api/workflows/reviews/:idApprouver/rejeter une revue

Pont Cloud

MéthodeCheminDescription
GET/api/workflows/cloud/statusStatut du pont VPS autonome
POST/api/workflows/cloud/convertOffice → PDF via VPS autonome (LibreOffice)
POST/api/workflows/cloud/ocrOCR via VPS autonome (Tesseract)
POST/api/workflows/cloud/extractExtraire les champs de facture/génériques d'un PDF (pdfjs + règles)

Archivage & Rétention

MéthodeCheminDescription
GET/api/workflows/archiveLister les documents archivés et l'intégrité de la chaîne
POST/api/workflows/archiveArchiver un document (base64, chaîne de hachage SHA-256)
GET/api/workflows/archive/:id/verifyVérifier la chaîne de hachage de l'archive
GET/api/workflows/archive/exportExporter le CSV d'audit des archives (inclut les marqueurs de suppression)
POST/api/workflows/archive/:id/holdActiver/désactiver la conservation légale
POST/api/workflows/archive/:id/complianceActiver le verrouillage de conformité WORM irréversible
DELETE/api/workflows/archive/:idSupprimer une archive (bloquée sous conservation légale)

API Publique v1

MéthodeCheminDescription
GET/api/v1/openapi.jsonSpécification OpenAPI 3.1 (publique, sans authentification)
GET/api/v1/mePropriétaire actuel de la clé API (clé Bearer)
GET/api/v1/usageTableau de bord d'utilisation : solde, historique sur 30 jours, appels récents
GET/api/v1/workflowsLister les workflows (portée workflow.read)
GET/api/v1/workflows/:idObtenir un workflow (portée workflow.read)
POST/api/v1/workflows/:id/runMettre en file d'attente une exécution (portée workflow.run)
GET/api/v1/runsLister les exécutions (portée workflow.read)
POST/api/v1/pdf/mergeFusionner des PDF (portée pdf.merge ; 2 à 10 fichiers en base64)
POST/api/v1/pdf/splitConserver les pages sélectionnées (portée pdf.split ; plages comme « 1-3,5 »)
POST/api/v1/pdf/compressCompresser structurellement un PDF (portée pdf.compress)
GET/api/v1/jobs/:idStatut du job (gratuit)
GET/api/v1/jobs/:id/downloadTélécharger le résultat d'un job (gratuit)
POST/api/v1/convert/officeConvertir des documents Office/ODF (portée pdf.convert)
POST/api/v1/convert/linearizeLinéariser un PDF pour un affichage web rapide (portée pdf.convert)
POST/api/v1/convert/typstCompiler une source Typst/Markdown en PDF (portée pdf.convert)
POST/api/v1/ocrEffectuer l'OCR d'un PDF scanné en PDF interrogeable (portée pdf.ocr)
POST/api/v1/ocr/textEffectuer l'OCR d'une seule image en texte (portée pdf.ocr)
POST/api/v1/validate/pdfaVérification de conformité PDF/A (portée pdf.validate)
POST/api/v1/validate/pdfuaVérification d'accessibilité PDF/UA (portée pdf.validate)
POST/api/v1/validate/signatureRapport de vérification de signature numérique (portée pdf.validate)
POST/api/v1/signSignature numérique PAdES (portée pdf.sign ; paire de clés PEM optionnelle)
POST/api/v1/redactSuppression définitive des occurrences textuelles ou zones correspondantes (portée pdf.redact)
POST/api/v1/extractExtraction de champs basée sur texte et règles (portée pdf.extract)
POST/api/v1/doclingAnalyse de mise en page structurée via Docling (portée pdf.extract)
POST/api/v1/scan/piiAnalyser le texte pour détecter des informations personnelles (portée pii.detect)

Credit consumption

Member credits refresh each billing cycle (no rollover) and are spent before purchased credits. Credits are $0.001 each.

Top up API credits in your account (from $5, never expires)

MethodEndpointCredits
GET/jobs/:id0 per call
GET/jobs/:id/download0 per call
GET/me0 per call
GET/runs0 per call
GET/usage0 per call
GET/workflows0 per call
GET/workflows/:id0 per call
POST/ai/chat3 per call
POST/ai/extract5 per call
POST/ai/pii-detect4 per call
POST/ai/summarize3 per call
POST/ai/translate3 per call
POST/convert/linearize1 per call
POST/convert/office2 per call
POST/convert/typst1 per call
POST/docling3 per call
POST/extract2 per call
POST/ocr3 per page
POST/ocr/text1 per call
POST/pdf/compress1 per call
POST/pdf/merge1 per call
POST/pdf/split1 per call
POST/redact3 per call
POST/scan/pii2 per call
POST/sign5 per envelope
POST/validate/pdfa2 per call
POST/validate/pdfua2 per call
POST/validate/signature2 per call
POST/workflows/:id/run1 per call
ai.chat2 per call
convert.html_to_pdf4 per page
convert.office_to_pdf10 per page
convert.pdf_to_office12 per page
convert.pdfa8 per page
esign.envelope750 per envelope
pdf.ocr3 per page
pdf.ocr.high8 per page