Skip to main content
[Important Notice: API Integration Update Required]Dear Developers,Thank you for your continued support of the AILabTools API.We would like to inform you that the current API has been updated with changes to the request and response specifications. These changes involve adjustments to parameters and response fields, and may affect existing integrations that rely on the previous API behavior.To ensure your application continues to work correctly, we strongly recommend that you review and update your current API integration as soon as possible.If you have any questions or need assistance with updating your integration, please feel free to contact our support team: 📧 support@ailabtools.comThank you for your understanding and cooperation. We appreciate your continued trust in AILabTools.Best regards,AILabTools Support Team

Request

  • URL: https://www.ailabapi.com/api/portrait/analysis/skin-analysis-pro
  • Method: POST
  • Content-Type: multipart/form-data

Image requirements

  • Image format: JPG JPEG
  • Image size: No more than 8 MB.
  • Image resolution: Larger than 200x200px, smaller than 4096x4096px.
  • Minimum face pixel size: To ensure the effect, the minimum value of the face box (square) side length in the image should preferably be higher than 400px.
  • Face quality: The higher the face quality, the more accurate the skin analysis. Factors affecting face quality include: occlusion of facial features, blurred images, improper lighting (bright, dark, backlight), excessive face angle (yaw ≤ ±30°, pitch ≤ ±40° recommended), etc.

Headers

Body

return_maps

  • Request Example red_area,brown_area
  • Field Parsing

return_marks

  • Request Example wrinkle_mark,right_nasolabial_list
  • Field Parsing

roi_outline_color

  • Request Example
  • Field Parsing
Example: CC00FF format stands for R:CC, G:00, B:FF respectively. The input format is limited to a 6-bit hexadecimal string and is not case-sensitive. If not modified, it will draw directly using the default parameter colors.

return_side_results

  • Request Example jawline_info
  • Field Parsing

Response

Response Field Handling Flow
  1. Handle Public Response Fields Parse and validate the Public Response Fields, checking the status code or response message to ensure the request is successful and error-free.
  2. Handle Business Response Fields If the Public Response Fields are valid and error-free, proceed with processing the business logic in the Business Response Fields.

Public Response Fields

Viewing Public Response Fields and Error Codes

Business Response Fields

face_rectangle

side_result

result

Skin Type Analysis
Roughness analysis
Pigmentation
Acne Analysis
Sensitivity Analysis
Senescence analysis
Eye Analysis
Overall Score
Customization

skintone_ita

ITA (Individual Typology Angle) is an international standard for skin color, which is a method to classify skin color by measuring the color attributes of skin color Lab space. The method is strongly dependent on ambient light, we recommend using flash to take HD face photos for uploading and processing, the ITA angle value measured in natural light or dark environment may not be allowed or abnormal. According to the data taken by the rear flash of the phone, the current skin color classification reference. You can also use the returned ITA value to define your classification based on the returned ITA angle at the time of access.

skin_hue_ha

HA (Hue Angle) is an international standard for skin color, which is a method to classify skin color by measuring the color attributes of skin color Lab space. The method is strongly dependent on ambient light, we recommend using flash to take HD face photos for uploading and processing, the HA angle value measured in natural light or dark light environment may not be allowed or abnormal. According to the data taken by the rear flash of the phone, the current skin tone classification reference. You can also use the returned HA value to define your classification based on the returned HA angle at the time of access.

Coordinate conversion formula between original image and black and white enhanced image

x_enhance = (x_img - left) * ratio y_enhance = (y_img - top) * ratio Coordinates of original image: x_img, y_img, coordinates of black and white enhanced image: x_enhance, y_enhance.

Response Example

This API has been discontinued. Please refer to the latest API documentation.