Image Moderation - Find Faces Url Input
Returns the list of faces found.
POST {Endpoint}/contentmoderator/moderate/v1.0/ProcessImage/FindFaces
POST {Endpoint}/contentmoderator/moderate/v1.0/ProcessImage/FindFaces?overload=url&CacheImage={CacheImage}
URI Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
|
Endpoint
|
path | True |
string |
Supported Azure Cognitive Services endpoints (protocol and host name, such as https://westus.api.cognitive.microsoft.com). |
|
Cache
|
query |
boolean |
Whether to retain the submitted image for future use. If it's omitted, the default is false. |
Request Header
| Name | Required | Type | Description |
|---|---|---|---|
| Ocp-Apim-Subscription-Key | True |
string |
|
| Content-Type | True |
string |
Content type. |
Request Body
| Name | Type | Description |
|---|---|---|
| DataRepresentation |
string |
|
| Value |
string |
Responses
| Name | Type | Description |
|---|---|---|
| 200 OK |
List of faces found. |
|
| Other Status Codes |
Error response. |
Security
Ocp-Apim-Subscription-Key
Type:
apiKey
In:
header
Examples
Find Faces request
Sample request
POST {Endpoint}/contentmoderator/moderate/v1.0/ProcessImage/FindFaces?overload=url
{
"DataRepresentation": "URL",
"Value": "https://moderatorsampleimages.blob.core.windows.net/samples/img_300.jpg"
}
Sample response
{
"Faces": [
{
"Left": 80,
"Right": 118,
"Top": 44,
"Bottom": 82
}
],
"Count": 1,
"AdvancedInfo": [],
"Result": true,
"Status": {
"Code": 3000,
"Description": "OK",
"Exception": ""
},
"TrackingId": "SEA_ad975eeae1f24f81bebb40be0c3ba4fd_ContentModerator.Preview_01158625-4fea-4dd5-8f21-5e2657ea2eee"
}
Definitions
| Name | Description |
|---|---|
| APIError |
Error information that the API returns. |
| Error |
Error body. |
| Face |
Coordinates to the found face. |
|
Found |
Request object that contains found faces. |
|
Key |
Key/value pair object properties. |
| Status |
Status properties. |
APIError
Error information that the API returns.
| Name | Type | Description |
|---|---|---|
| Error |
Error body. |
Error
Error body.
| Name | Type | Description |
|---|---|---|
| Code |
string |
|
| Message |
string |
Face
Coordinates to the found face.
| Name | Type | Description |
|---|---|---|
| Bottom |
integer |
Bottom coordinate. |
| Left |
integer |
Left coordinate. |
| Right |
integer |
Right coordinate. |
| Top |
integer |
Top coordinate. |
FoundFaces
Request object that contains found faces.
| Name | Type | Description |
|---|---|---|
| AdvancedInfo |
Advanced info. |
|
| CacheId |
string |
Cache ID. |
| Count |
integer |
Number of faces found. |
| Faces |
Face[] |
List of faces. |
| Result |
boolean |
True if a result was found. |
| Status |
Evaluation status. |
|
| TrackingId |
string |
Tracking ID. |
KeyValuePair
Key/value pair object properties.
| Name | Type | Description |
|---|---|---|
| Key |
string |
Key parameter. |
| Value |
string |
Value parameter. |
Status
Status properties.
| Name | Type | Description |
|---|---|---|
| Code |
integer |
Status code. |
| Description |
string |
Status description. |
| Exception |
string |
Exception status. |