Depth map
POST/v2/artworks/depth-map
Generate a depth map from an image. Returns a grayscale image where lighter pixels are closer to the camera and darker pixels are farther away.
Request
- application/json
Body
required
URL of the image to generate a depth map from.
Whether to invert the depth image.
Possible values: >= 256 and <= 2048
Default value: 1024
Lower limit of the resolution. Must be a multiple of 64.
Whether the depth map gets resized to original resolution.
Optional webhook URL. When provided, the server will POST the final artwork result to this URL upon completion.
When true, uses DepthAnythingV3. When false, uses V2. Determines which model values are valid.
Default value: large
Depth map model name. V2: giant, large, base, small. V3: small, base, large, giant, mono_large, metric_large, nested_giant_large.
Possible values: [Standard, V2-Style, Raw]
Default value: Standard
Normalization mode (V3 only). Values: Standard, V2-Style, Raw.
Responses
- 202
- 400
- 401
- 403
- 429
- 500
Depth map artwork creation accepted for processing.
- application/json
- Schema
- Example (from schema)
Schema
Possible values: [depth_map]
parameters
object
required
URL of the image to generate a depth map from.
Whether to invert the depth image.
Possible values: >= 256 and <= 2048
Default value: 1024
Lower limit of the resolution. Must be a multiple of 64.
Whether the depth map gets resized to original resolution.
Optional webhook URL. When provided, the server will POST the final artwork result to this URL upon completion.
When true, uses DepthAnythingV3. When false, uses V2. Determines which model values are valid.
Default value: large
Depth map model name. V2: giant, large, base, small. V3: small, base, large, giant, mono_large, metric_large, nested_giant_large.
Possible values: [Standard, V2-Style, Raw]
Default value: Standard
Normalization mode (V3 only). Values: Standard, V2-Style, Raw.
Possible values: [starting, processing, succeeded, failed, canceled]
{
"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"artworkType": "depth_map",
"parameters": {
"imageUrl": "string",
"invertDepth": false,
"resolutionLowerLimit": 1024,
"usePostResize": false,
"webhook": "string",
"useVersion3": false,
"model": "large",
"normalizationMode": "Standard"
},
"duration": 0,
"results": [
"string"
],
"status": "starting",
"createdAt": "2024-07-29T15:51:28.071Z"
}
Bad Request
- application/json
- Schema
- Example (from schema)
Schema
Available only when the message includes additional error details.
{
"message": "string",
"statusCode": 0,
"error": "string"
}
Unauthorized
- application/json
- Schema
- Example (from schema)
Schema
Available only when the message includes additional error details.
{
"message": "string",
"statusCode": 0,
"error": "string"
}
Forbidden
- application/json
- Schema
- Example (from schema)
Schema
Available only when the message includes additional error details.
{
"message": "string",
"statusCode": 0,
"error": "string"
}
Too Many Requests
- application/json
- Schema
- Example (from schema)
Schema
Available only when the message includes additional error details.
{
"message": "string",
"statusCode": 0,
"error": "string"
}
Internal Server Error
- application/json
- Schema
- Example (from schema)
Schema
Available only when the message includes additional error details.
{
"message": "string",
"statusCode": 0,
"error": "string"
}