Smart OCR / Technical reference

API Docs.

Everything needed to authenticate, upload, and process documents with the implemented developer API. The documentation shows routes even when they are not yet activated.

API Base URL

https://www.staging.smartocr.io/api/v1

Bearer token · HTTPS on production

01 / Get started

Authentication

Generate an API key in your Smart OCR account. Pass the key using the Authorization header for every developer request. Never expose keys in public JavaScript, URLs or logs.

Authorization: Bearer YOUR_API_KEY

POST uploads use multipart/form-data, and developer API requests do not require the website's Turnstile token.

02 / Endpoint catalog

Conversion routes

These three routes are implemented by the server. Their current enabled status depends on the active Tool Settings and your API subscription.

POST · /api/v1/image-to-text

Image to Text

Recognize text in an image or scanned page. Plain text and formatted modes are supported.

Not currently enabled
FieldRequiredValue / description
imageYesMultipart upload file
modeNosimple, formatted (aliases: plain, layout)
batch_totalNoOptional number of files in submitted batch

Output: JSON: text, mode, render_mode and formatting metadata. Response structure depends on conversion mode.

cURL example
curl -X POST 'https://www.staging.smartocr.io/api/v1/image-to-text' \
  -H 'Authorization: Bearer YOUR_API_KEY' \
  -F 'image={{ $detail['file'] ?? 'image.png' }}' \
  -F 'mode=simple'

This endpoint is documented but not enabled by current tool settings. Enable the appropriate modes through Smart OCR administration before attempting live requests. No credit price is asserted here.

POST · /api/v1/jpg-to-excel

JPG to Excel

Detect tables and text from uploaded images. Returns structured spreadsheet data.

Not currently enabled
FieldRequiredValue / description
imageYesMultipart upload file
modeNotable, auto, rows
batch_totalNoOptional number of files in submitted batch

Output: JSON conversion output including table data / export fields. Response structure depends on conversion mode.

cURL example
curl -X POST 'https://www.staging.smartocr.io/api/v1/jpg-to-excel' \
  -H 'Authorization: Bearer YOUR_API_KEY' \
  -F 'image={{ $detail['file'] ?? 'image.png' }}' \
  -F 'mode=table'

This endpoint is documented but not enabled by current tool settings. Enable the appropriate modes through Smart OCR administration before attempting live requests. No credit price is asserted here.

POST · /api/v1/jpg-to-word

JPG to Word

Create an editable Word document from one or more uploaded images.

Not currently enabled
FieldRequiredValue / description
images[]YesMultipart upload file
modeYesdirect, text, formatted
batch_totalNoOptional number of files in submitted batch

Output: Document download or conversion output depending on mode. Response structure depends on conversion mode.

cURL example
curl -X POST 'https://www.staging.smartocr.io/api/v1/jpg-to-word' \
  -H 'Authorization: Bearer YOUR_API_KEY' \
  -F 'images[]={{ $detail['file'] ?? 'image.png' }}' \
  -F 'mode=text'

This endpoint is documented but not enabled by current tool settings. Enable the appropriate modes through Smart OCR administration before attempting live requests. No credit price is asserted here.

Word to Excel website tool

Word to Excel is available on the public website. A separate /api/v1/word-to-excel developer route is not implemented in the provided Laravel API routes and is not advertised here.

03 / Handle responses

Responses and errors

Successful conversions return content or conversion-specific metadata. Check the response status and content type, and handle binary downloads as files when applicable. Validation errors use Laravel JSON responses.

HTTP codeMeaningAction
200Successful processingRead returned content or download
401Missing or invalid keyCheck bearer token
403Not authorized / permission deniedCheck subscription and API permissions
422Invalid file, mode or parametersCorrect upload fields and supported modes
429Rate or usage limit reachedWait, reduce usage or upgrade
500Server processing errorRetry later and contact support if persistent

04 / Production checklist

Limits & security

  • ✓ Use HTTPS in production and store API keys in server-side secrets.
  • ✓ Respect your plan's file-size, batch and credit allowances.
  • ✓ Use multipart/form-data for images and images[] for Word document conversion.
  • ✓ Handle rate limiting and failures without exposing uploaded user files.
  • ✓ Avoid logging authorization headers or raw file contents.
  • ✓ Enable only the modes you intend to offer in Tool Settings.
Contact support ↗