apyhub
ARTIFICIAL INTELLIGENCE · IMAGE PROCESSING

AI Image Face Detection API

What it does

Face Detection finds human faces in an image and returns the detector response from the service you choose. Send either an image URL or a binary file, and choose requested_service as apyhub, azure, or google when you need a specific vision backend.

Use the /url endpoint when the image is already hosted online. Include body.url, and optionally supply Azure credentials in body.azure or Google credentials in body.google if you want to route the request through those providers. Use /file when you want to upload an image directly; it accepts body.file and optional Azure fields such as azure_key, azure_region, azure_endpoint, azure_account_id, and azure_access_token, plus google_key if needed.

The response is grouped under data and includes one of three provider objects: data.apyhub, data.azure, or data.google. That makes it easy to plug Face Detection into moderation flows, identity-related prechecks, photo organization, or any pipeline that needs to know whether a face is present before taking the next step.

Use this when you need face detection as a lightweight image-analysis step without building or maintaining your own vision stack.

▣ ENDPOINT 01 / 02
POST
Detect human faces (URL input)
https://api.eu.apyverse.com/apyhub/detect-human-faces/url

QUICKSTART

GUIDE

Quickstart

Send an image URL to detect faces.

curl -X POST "https://api.eu.apyverse.com/apyhub/detect-human-faces/url" \
  -H "apy-token: $APY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"url":"https://example.com/faces.jpg"}'

What you'll get back

Returns a JSON object with a data object. The data object can contain azure, apyhub, and google response objects, depending on the service used.

{
  "data": {
    "apyhub": {},
    "azure": {},
    "google": {}
  }
}
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.
google
Custom credentials for Google services.
Target language locale.
google_credential_json

About this endpoint

What it does

Detects human faces from an image URL. You send the image url plus optional service credentials/settings, and the endpoint returns a JSON object containing a data object with provider-specific result objects for Azure, ApyHub, and Google.

Request Body

ParameterTypeMandatoryDescription
urlStringYesImage URL to analyze. Must be a URI.
azureObjectNoCustom credentials for Azure services.
azure.keyStringNoAzure subscription key.
azure.regionStringNoAzure service region.
azure.endpointStringNoAzure endpoint URL.
azure.account_idStringNoAzure account ID.
azure.access_tokenStringNoOAuth access token for Azure service.
googleObjectNoCustom credentials for Google services.
google.google_languageStringNoTarget language locale.
google.google_credential_jsonObjectNoGoogle credential JSON object. See schema for nested fields.
requested_serviceENUMNoWhich service to use. Allowed values: azure, google, apyhub. Default: apyhub.

Response

Returns a JSON object with a data object field. The data object can contain provider-specific response objects in azure, apyhub, and google fields, each of which is an object when present.

ParameterTypeMandatoryDescription
dataObjectNoContainer for provider-specific response objects.
data.azureObjectNoResponse object from Microsoft Azure Computer Vision.
data.apyhubObjectNoResponse object from ApyHub Vision detector.
data.googleObjectNoResponse object from Google Cloud Vision.

Body

Name
Type
Description
bodyREQUIRED
object
▣ ENDPOINT 02 / 02
POST
Detect human faces (file upload)
https://api.eu.apyverse.com/apyhub/detect-human-faces/file

QUICKSTART

GUIDE

Quickstart

Upload an image file to detect human faces.

curl -X POST "https://api.eu.apyverse.com/apyhub/detect-human-faces/file" \
  -H "apy-token: $APY_TOKEN" \
  -F "file=@/path/to/image.jpg"

What you'll get back

Returns a JSON object with a data object. That data object may include azure, apyhub, and google objects, depending on the detection service used.

{
  "data": {
    "azure": {},
    "apyhub": {},
    "google": {}
  }
}
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

Detects human faces from an uploaded file and returns a JSON object with face-detection results from one or more providers under data.

Request Body

ParameterTypeMandatoryDescription
fileStringYesBinary file upload.
azure_keyStringNoAzure key.
google_keyStringNoGoogle key.
azure_regionStringNoAzure region.
azure_endpointStringNoAzure endpoint.
azure_account_idStringNoAzure account ID.
requested_serviceENUMNoAllowed values: azure, google, apyhub. Default: apyhub.
azure_access_tokenStringNoAzure access token.

Response

Returns a JSON object with a top-level data object field. data may contain azure, apyhub, and google object fields, each representing the corresponding provider response.

ParameterTypeMandatoryDescription
dataObjectNoContainer for provider-specific face-detection responses.
data.azureObjectNoResponse object from Microsoft Azure Computer Vision.
data.apyhubObjectNoResponse object from ApyHub Vision detector.
data.googleObjectNoResponse object from Google Cloud Vision.

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.

▣ 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.