Search by

dessop / ocr

dessop.mx

DESSOP OCR API PHP SDK

Package info

github.com/Dessop/ocr

pkg:composer/dessop/ocr

Statistics

Installs: 6

Dependents: 1

Suggesters: 0

Stars: 0

Open Issues: 0

v1.0.0 2026-09-15 21:50 UTC

This package is auto-updated.

Last update: 2026-09-15 22:15:40 UTC


README

Official PHP SDK for the DESSOP OCR API.

Package: dessop/ocr
API: https://ocr.dessop.com

Requirements

  • PHP 8.2+
  • Composer 2+

Installation

composer require dessop/ocr

Configuration

use Dessop\Ocr\OcrClient;

$ocr = new OcrClient(
    'https://ocr.dessop.com',
    getenv('DESSOP_OCR_API_KEY'),
    300,
);

Process a document

$result = $ocr->process('/path/to/document.pdf');

if ($result->successful()) {
    echo $result->text();
}

Available methods:

$result->jobId();
$result->filename();
$result->pages();
$result->text();
$result->client();
$result->data();
$result->get('some.nested.value');

Health check

if ($ocr->health()) {
    // DESSOP OCR is available.
}

Exceptions

  • OcrAuthenticationException
  • OcrValidationException
  • OcrTimeoutException
  • OcrServerException
  • OcrException

Security

Never hardcode the API key. Store it in an environment variable or secret manager. Never log the key or send it to frontend code.

License

MIT. Copyright (c) 2026 DESSOP.