apyhub

AI Document ID Extraction API

Hosted on ApyHub

What it does

ID Data Extraction lets you send an ID document as a file or by URL and get extracted identity data back. Choose the requested_service value to route the request to apyhub or azure, and, for Azure-backed requests, provide the Azure credential fields supported by the endpoint.

Use POST /file to upload a binary file, or POST /url to point the service at a url. Both endpoints accept the same service selection pattern, and the URL flow also supports an azure object with key, region, endpoint, account_id, and access_token for custom Azure configuration.

The response returns a data object with azure and apyhub objects. azure contains the raw Azure Document Intelligence parsing output, while apyhub contains the structured ApyHub ID extraction output. That makes the service useful when you need to read identity documents from uploads or hosted files and compare the structured result with the underlying Azure parse.

Typical uses include onboarding flows, account verification, and document intake pipelines where you need extracted ID details from PDFs or other supported file inputs.

Provider (requested_service)Atoms
Azure500
ApyHub2000
▣ ENDPOINT 01 / 02
POST
Extract id data (file upload)
http://localhost:8080/apyhub/extract-id-data/file
QUICKSTARTGUIDE

Quickstart

Upload an ID file to extract data from it using ApyHub.

curl -X POST "http://localhost:8080/apyhub/extract-id-data/file" \
  -H "apy-token: $APY_TOKEN" \
  -F "file=@/path/to/id-document.jpg" \
  -F 'requested_service=apyhub'

What you'll get back

Returns a JSON object with a data object. That data object may include azure for raw Azure Document Intelligence output and/or apyhub for structured ApyHub ID extraction output.

{
  "data": {
    "azure": {},
    "apyhub": {}
  }
}
TRY ITLIVE · 500 ATOMS
Loading your default key…
The full key is used to call the gateway and stays in this tab — never sent to orbit or saved.
Max 100MB total per request (all files combined). Larger? Use this API's URL-based endpoint instead, if it has one.
body*

About this endpoint

What it does

Uploads an ID document file and returns parsed extraction results. The response is a JSON object with a data object containing azure and apyhub result objects.

Request Body

ParameterTypeMandatoryDescription
fileStringYesBinary file upload containing the ID document to parse.
azure_keyStringNoAzure key used when requesting Azure-based processing.
azure_regionStringNoAzure region value; example format is a region string such as eastus.
azure_endpointStringNoAzure endpoint URL.
azure_account_idStringNoAzure account identifier.
requested_serviceENUMNoWhich service to use for extraction. Allowed values: azure, apyhub. Default: apyhub.
azure_access_tokenStringNoAzure access token.

Response

Returns a JSON object with a data object field. Inside data, the response may include azure and apyhub object fields, which contain the raw Azure Document Intelligence parsing output and the structured ApyHub ID extraction parsing output, respectively.

ParameterTypeMandatoryDescription
dataObjectNoResponse wrapper that may contain service-specific extraction results.
data.azureObjectNoRaw Azure Document Intelligence parsing output.
data.apyhubObjectNoStructured ApyHub ID extraction parsing output.

Body

Name
Type
Description
bodyREQUIRED
object

Max 100MB total per request (all files combined). Larger? Use this API's URL-based endpoint instead, if it has one.

▣ ENDPOINT 02 / 02
POST
Extract id data (URL input)
http://localhost:8080/apyhub/extract-id-data/url
QUICKSTARTGUIDE

Quickstart

Call this endpoint with your ApyHub API key:

curl -X POST "http://localhost:8080/apyhub/extract-id-data/url" \
  -H 'apy-token: $APY_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{"requested_service":"apyhub", "url":"https://assets.apyhub.com/samples/sample.pdf"}'
TRY ITLIVE · 500 ATOMS
Loading your default key…
The full key is used to call the gateway and stays in this tab — never sent to orbit or saved.
body*
azure
Custom credentials for Azure services.
Azure subscription key.
Azure service region.
Azure endpoint URL.
Azure account ID.
OAuth access token for Azure service.

About this endpoint

Extract id data (URL input)

Extract id data (URL input)

Analyze id at the provided URL. Note: The optional 'requested_service' selector and 'azure' configuration fields are omitted in this basic example for simplicity.


Documentation imported from spec — please review and complete before submitting.


Documentation imported from spec — please review and complete before submitting.

Body

Name
Type
Description
bodyREQUIRED
object
▣ COMMON ERRORS

Errors any endpoint can return

400bad_request

Required parameter missing or malformed body.

401unauthorized

API key missing, revoked, or not authorized for this service.

429rate_limited

Your plan's per-second rate exceeded. Retry with exponential backoff.

503upstream_busy

Backend temporarily unavailable. Try again in a few seconds.