Skip to main content

NSFW Image Check

Overview

This endpoint is useful to check if an image is nsfw or not

Request

--request POST 'https://stablediffusionapi.com/api/v3/nsfw_image_check' \

Send a POST request to https://stablediffusionapi.com/api/v3/nsfw_image_check endpoint to check if an image is nsfw or not.

Attributes

ParameterDescription
keyYour enterprise API Key used for request authorization.
init_imageThe image you want to check.

Example

Body

Body Raw
{
"key": "enterprise_api_key",
"init_image": "http://your-image-url.com"
}

Request

var myHeaders = new Headers();
myHeaders.append("Content-Type", "application/json");

var raw = JSON.stringify({
"key": "",
"init_image": "http://your-image-url.com"
});

var requestOptions = {
method: 'POST',
headers: myHeaders,
body: raw,
redirect: 'follow'
};

fetch("https://stablediffusionapi.com/api/v3/nsfw_image_check", requestOptions)
.then(response => response.text())
.then(result => console.log(result))
.catch(error => console.log('error', error))

Response

{
"images": "http://your-image-url.com",
"has_nsfw_concept": [
true
]
}