This API allows you to automatically detect human faces in images with high accuracy. When it receives an image as input, the system analyzes its content using advanced computer vision models and returns an array with the position and size of each identified face.
Each face is represented by a JSON object with four properties: x and y, which indicate the position of the face within the image (top-left coordinates), and width and height, which represent the dimensions of the detected area. This makes it easy to draw a rectangle around each face.
The output format facilitates integration with image editing, security, augmented reality, photography, emotion analysis, or simply visual detection applications. For example, it can be used to blur faces, crop them, apply filters, count how many people are in a photo, or feed facial recognition systems (in later stages).
To use this endpoint, you must upload an image to the parameter.
Face Detection - Endpoint Features
| Object | Description |
|---|---|
Request Body |
[Required] File Binary |
[{"x": 153, "y": 164, "width": 109, "height": 109}]
curl --location 'https://zylalabs.com/api/8489/face+box+content+extraction+api/14869/face+detection' \
--header 'Content-Type: application/json' \
--form 'image=@"FILE_PATH"'
| Header | Description |
|---|---|
Authorization
|
[Required] Should be Bearer access_key. See "Your API Access Key" above when you are subscribed. |
No long-term commitment. Upgrade, downgrade, or cancel anytime. Free Trial includes up to 50 requests.
The API returns an array of JSON objects, each representing a detected face in the input image. Each object contains the coordinates and dimensions of the face, allowing for easy integration into various applications.
Each JSON object in the response includes four key fields: `x` (top-left x-coordinate), `y` (top-left y-coordinate), `width` (face width), and `height` (face height). These fields provide the necessary information to locate and size the detected faces.
The response data is structured as a JSON array. Each element in the array corresponds to a detected face, containing the `x`, `y`, `width`, and `height` properties, making it straightforward to process and visualize the results.
The primary parameter for the Face Detection endpoint is the image file itself, which must be uploaded for analysis. Ensure the image is in a supported format (e.g., JPEG, PNG) for optimal results.
Common use cases include image editing (blurring or cropping faces), security applications (monitoring), augmented reality (face filters), and emotion analysis. The API can also assist in counting people in photos for various analytics.
The API utilizes advanced computer vision models trained on diverse datasets to ensure high accuracy in face detection. Continuous updates and improvements to the models help maintain data quality and reliability.
Users can leverage the returned coordinates and dimensions to draw rectangles around detected faces, apply filters, or integrate with facial recognition systems. The structured format allows for easy manipulation in various programming environments.
If the API returns an empty array, it indicates no faces were detected in the image. Users should implement checks in their application to handle such cases gracefully, possibly by notifying users or prompting for a different image.
To obtain your API key, you first need to sign in to your account and subscribe to the API you want to use. Once subscribed, go to your Profile, open the Subscription section, and select the specific API. Your API key will be available there and can be used to authenticate your requests.
You can’t switch APIs during the free trial. If you subscribe to a different API, your trial will end and the new subscription will start as a paid plan.
If you don’t cancel before the 7th day, your free trial will end automatically and your subscription will switch to a paid plan under the same plan you originally subscribed to, meaning you will be charged and gain access to the API calls included in that plan.
The free trial ends when you reach 50 API requests or after 7 days, whichever comes first.
No, the free trial is available only once, so we recommend using it on the API that interests you the most. Most of our APIs offer a free trial, but some may not include this option.
Yes, we offer a 7-day free trial that allows you to make up to 50 API calls at no cost, so you can test our APIs without any commitment.
Zyla API Hub is like a big store for APIs, where you can find thousands of them all in one place. We also offer dedicated support and real-time monitoring of all APIs. Once you sign up, you can pick and choose which APIs you want to use. Just remember, each API needs its own subscription. But if you subscribe to multiple ones, you'll use the same key for all of them, making things easier for you.
Service Level:
100%
Response Time:
0ms
Service Level:
100%
Response Time:
2,099ms
Service Level:
100%
Response Time:
0ms
Service Level:
100%
Response Time:
3,174ms
Service Level:
100%
Response Time:
7,933ms
Service Level:
100%
Response Time:
1,935ms
Service Level:
100%
Response Time:
1,831ms
Service Level:
100%
Response Time:
125ms
Service Level:
100%
Response Time:
2,354ms
Service Level:
100%
Response Time:
2,879ms
Service Level:
100%
Response Time:
10,743ms
Service Level:
100%
Response Time:
56ms
Service Level:
100%
Response Time:
585ms
Service Level:
100%
Response Time:
583ms
Service Level:
100%
Response Time:
10,182ms
Service Level:
100%
Response Time:
159ms
Service Level:
100%
Response Time:
597ms
Service Level:
100%
Response Time:
9,852ms
Service Level:
100%
Response Time:
467ms
Service Level:
100%
Response Time:
600ms