{
"swagger": "2.0",
"info": {
"title": "Content Moderator Client",
"version": "1.0",
"description": "You use the API to scan your content as it is generated. Content Moderator then processes your content and sends the results along with relevant information either back to your systems or to the built-in review tool. You can use this information to take decisions e.g. take it down, send to human judge, etc.\r\n\r\nWhen using the API, images need to have a minimum of 128 pixels and a maximum file size of 4MB. \r\nText can be at most 1024 characters long. \r\nIf the content passed to the text API or the image API exceeds the size limits, the API will return an error code that informs about the issue.\r\n\r\nThis API is currently available in:\r\n\r\n* West US - westus.api.cognitive.microsoft.com\r\n* East US 2 - eastus2.api.cognitive.microsoft.com\r\n* West Central US - westcentralus.api.cognitive.microsoft.com\r\n* West Europe - westeurope.api.cognitive.microsoft.com\r\n* Southeast Asia - southeastasia.api.cognitive.microsoft.com ."
},
"securityDefinitions": {
"apim_key": {
"type": "apiKey",
"name": "Ocp-Apim-Subscription-Key",
"in": "header"
}
},
"security": [
{
"apim_key": []
}
],
"x-ms-parameterized-host": {
"hostTemplate": "{baseUrl}",
"parameters": [
{
"$ref": "#/parameters/baseUrl"
}
]
},
"basePath": "/",
"schemes": [
"https"
],
"paths": {
"/contentmoderator/moderate/v1.0/ProcessImage/FindFaces": {
"post": {
"tags": [
"ImageModeration"
],
"operationId": "ImageModeration_FindFaces",
"description": "Returns the list of faces found.",
"parameters": [
{
"$ref": "#/parameters/CacheImage"
}
],
"consumes": [
"application/json",
"image/gif",
"image/jpeg",
"image/png",
"image/bmp",
"image/tiff"
],
"responses": {
"200": {
"description": "The list of faces found.",
"schema": {
"$ref": "#/definitions/FoundFaces"
}
},
"default": {
"description": "Error response.",
"schema": {
"$ref": "#/definitions/APIError"
}
}
},
"produces": [
"application/json"
]
}
},
"/contentmoderator/moderate/v1.0/ProcessImage/OCR": {
"post": {
"tags": [
"ImageModeration"
],
"operationId": "ImageModeration_OCR",
"description": "Returns any text found in the image for the language specified. If no language is specified in input then the detection defaults to English.",
"parameters": [
{
"$ref": "#/parameters/language"
},
{
"$ref": "#/parameters/CacheImage"
},
{
"$ref": "#/parameters/enhanced"
}
],
"consumes": [
"application/json",
"image/gif",
"image/jpeg",
"image/png",
"image/bmp",
"image/tiff"
],
"responses": {
"200": {
"description": "The text found and list of candidate text details.",
"schema": {
"$ref": "#/definitions/OCR"
}
},
"default": {
"description": "Error response.",
"schema": {
"$ref": "#/definitions/APIError"
}
}
},
"produces": [
"application/json"
]
}
},
"/contentmoderator/moderate/v1.0/ProcessImage/Evaluate": {
"post": {
"tags": [
"ImageModeration"
],
"operationId": "ImageModeration_Evaluate",
"description": "Returns probabilities of the image containing racy or adult content.",
"parameters": [
{
"$ref": "#/parameters/CacheImage"
}
],
"consumes": [
"application/json",
"image/gif",
"image/jpeg",
"image/png",
"image/bmp",
"image/tiff"
],
"responses": {
"200": {
"description": "",
"schema": {
"$ref": "#/definitions/Evaluate"
}
},
"default": {
"description": "Error response.",
"schema": {
"$ref": "#/definitions/APIError"
}
}
},
"produces": [
"application/json"
]
}
},
"/contentmoderator/moderate/v1.0/ProcessImage/Match": {
"post": {
"tags": [
"ImageModeration"
],
"operationId": "ImageModeration_Match",
"description": "Fuzzily match an image against one of your custom Image Lists. You can create and manage your custom image lists using this API. \r\n\r\nReturns ID and tags of matching image.
\r\n
\r\nNote: Refresh Index must be run on the corresponding Image List before additions and removals are reflected in the response.",
"parameters": [
{
"$ref": "#/parameters/listIdQueryParameter"
},
{
"$ref": "#/parameters/CacheImage"
}
],
"consumes": [
"application/json",
"image/gif",
"image/jpeg",
"image/png",
"image/bmp",
"image/tiff"
],
"responses": {
"200": {
"description": "Supported values for tags are:\r\n
\r\n{
\r\n \"ReviewId\": \"
\r\n \"ModifiedOn\": \"2016-10-11T22:36:32.9934851Z\",
\r\n \"ModifiedBy\": \"
\r\n \"CallBackType\": \"Review\",
\r\n \"ContentId\": \"
\r\n \"Metadata\": {
\r\n \"adultscore\": \"0.xxx\",
\r\n \"a\": \"False\",
\r\n \"racyscore\": \"0.xxx\",
\r\n \"r\": \"True\"
\r\n },
\r\n \"ReviewerResultTags\": {
\r\n \"a\": \"False\",
\r\n \"r\": \"True\"
\r\n }
\r\n}
\r\n\r\n
\r\n
\r\n
\r\n{
\r\n \"ReviewId\": \"
\r\n \"ModifiedOn\": \"2016-10-11T22:36:32.9934851Z\",
\r\n \"ModifiedBy\": \"
\r\n \"CallBackType\": \"Review\",
\r\n \"ContentId\": \"
\r\n \"Metadata\": {
\r\n \"adultscore\": \"0.xxx\",
\r\n \"a\": \"False\",
\r\n \"racyscore\": \"0.xxx\",
\r\n \"r\": \"True\"
\r\n },
\r\n \"ReviewerResultTags\": {
\r\n \"a\": \"False\",
\r\n \"r\": \"True\"
\r\n }
\r\n}
\r\n\r\n
\r\n{
\r\n \"ReviewId\": \"
\r\n \"ModifiedOn\": \"2016-10-11T22:36:32.9934851Z\",
\r\n \"ModifiedBy\": \"
\r\n \"CallBackType\": \"Review\",
\r\n \"ContentId\": \"
\r\n \"Metadata\": {
\r\n \"adultscore\": \"0.xxx\",
\r\n \"a\": \"False\",
\r\n \"racyscore\": \"0.xxx\",
\r\n \"r\": \"True\"
\r\n },
\r\n \"ReviewerResultTags\": {
\r\n \"a\": \"False\",
\r\n \"r\": \"True\"
\r\n }
\r\n}
\r\n\r\n
\r\n{
\r\n \"ReviewId\": \"
\r\n \"ModifiedOn\": \"2016-10-11T22:36:32.9934851Z\",
\r\n \"ModifiedBy\": \"
\r\n \"CallBackType\": \"Review\",
\r\n \"ContentId\": \"
\r\n \"Metadata\": {
\r\n \"adultscore\": \"0.xxx\",
\r\n \"a\": \"False\",
\r\n \"racyscore\": \"0.xxx\",
\r\n \"r\": \"True\"
\r\n },
\r\n \"ReviewerResultTags\": {
\r\n \"a\": \"False\",
\r\n \"r\": \"True\"
\r\n }
\r\n}
\r\n\r\n