Skip to main content
Digital human

Wan — Detect a portrait image

Check whether an image meets the portrait requirements of wan2.2-s2v

POST
/services/aigc/image2video/face-detect
cURL
# China North 2 (Beijing). This model is available only in this region.
# API keys are region-specific. See https://docs.qwencloud.com/developer-guides/getting-started/regions
curl --request POST \
  --url https://cn-beijing.maas.qwencloudapi.com/api/v1/services/aigc/image2video/face-detect \
  --header "Authorization: Bearer $DASHSCOPE_API_KEY" \
  --header 'Content-Type: application/json' \
  --data '{
    "model": "wan2.2-s2v-detect",
    "input": {
      "image_url": "https://img.alicdn.com/imgextra/i3/O1CN011FObkp1T7Ttowoq4F_!!6000000002335-0-tps-1440-1797.jpg"
    }
  }'
{
  "output": {
    "check_pass": true,
    "humanoid": true
  },
  "usage": {
    "image_count": 1
  },
  "request_id": "c56f62df-724e-9c19-96bd-xxxxxx"
}
Use portrait image detection to check whether an input image meets the portrait image requirements of wan2.2-s2v. Run it before generating a digital human video to filter out images that would fail. Supported regions: China North 2 (Beijing) only. Use an API key created in that region and the https://cn-beijing.maas.qwencloudapi.com endpoint. See Regions and endpoints. The response returns check_pass and humanoid:
  • check_pass — true if the image meets the requirements of wan2.2-s2v.
  • humanoid — true if a human portrait is detected in the image.
When the check fails, code and message describe the reason.

Authorizations

string
header
required

QwenCloud API key. See Get an API key.

Body

application/json
enum<string>
required

Model name. Fixed value: wan2.2-s2v-detect.

wan2.2-s2v-detect
wan2.2-s2v-detect
object
required

Input image parameters.

Response

200-application/json
string

Unique request ID used for tracing and troubleshooting.

c56f62df-724e-9c19-96bd-xxxxxx
object

Detection result.

object

Usage statistics.