Nexus
All models
Other Image Available

Content NSFW Moderation

Check text, one image, or both in a single request with KIE NSFW Moderation and get a `pass` or `block` verdict for sexual content at the `adult`, `social` or `strict` level. Every result also includes the NSFW level and separate details for the text and the image. The model uses the parameter `model=kie/nsfw-moderation`. Try it online and see pricing on the KIE NSFW Moderation API page.

Text to Image

From 60 credits (≈ ₹60.00) per request.

Parameters

ParameterTypeDescription
text string Text to review, such as a generation prompt. Any language, up to 12,000 characters. Provide `text`, `image_url`, or both.
max length 12000
image_url string Publicly downloadable URL of one image to review. JPG, PNG, WEBP or GIF (for animated images, the first frame is reviewed), up to 20 MB and 50 megapixels. Provide `text`, `image_url`, or both.
format: uri
scene string Moderation level: `adult`, `social` or `strict`. Defaults to `social`. `adult` allows adult content and blocks detected sexual content involving minors; `social` blocks nudity and explicit content and usually allows content that is only suggestive; `strict` blocks anything above `none`, including suggestive content. Detected sexual content involving minors is blocked in every scene.
one of: "adult", "social", "strict" · default "social"

What you get back

Files arrive in output.files[] as private links that expire, with their type and size.

Use it from your code

# 1. Create the task
curl https://nexus.promptscenes.in/api/v1/tasks \
  -H "Authorization: Bearer $NEXUS_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{
    "model": "content-nsfw-moderation",
    "input": {
        "scene": "social"
    },
    "callback_url": "https://your-app.com/webhooks/nexus"
}'

# 2. Poll for the result
curl https://nexus.promptscenes.in/api/v1/tasks/TASK_ID \
  -H "Authorization: Bearer $NEXUS_API_KEY"
import os, time, uuid, requests

API = "https://nexus.promptscenes.in/api/v1"
HEADERS = {"Authorization": f"Bearer {os.environ['NEXUS_API_KEY']}"}

task = requests.post(
    f"{API}/tasks",
    headers={**HEADERS, "Idempotency-Key": str(uuid.uuid4())},
    json={
        "model": "content-nsfw-moderation",
        "input": {
            "scene": "social",
        },
        "callback_url": "https://your-app.com/webhooks/nexus",
    },
).json()

while task["status"] not in ("succeeded", "failed", "cancelled"):
    time.sleep(3)
    task = requests.get(f"{API}/tasks/{task['id']}", headers=HEADERS).json()

print(task["status"], task.get("output"))
const API = "https://nexus.promptscenes.in/api/v1";
const headers = {
  Authorization: `Bearer ${process.env.NEXUS_API_KEY}`,
  "Content-Type": "application/json",
};

let task = await fetch(`${API}/tasks`, {
  method: "POST",
  headers: { ...headers, "Idempotency-Key": crypto.randomUUID() },
  body: JSON.stringify({
      "model": "content-nsfw-moderation",
      "input": {
          "scene": "social"
      },
      "callback_url": "https://your-app.com/webhooks/nexus"
  }),
}).then((r) => r.json());

while (!["succeeded", "failed", "cancelled"].includes(task.status)) {
  await new Promise((r) => setTimeout(r, 3000));
  task = await fetch(`${API}/tasks/${task.id}`, { headers }).then((r) => r.json());
}
console.log(task.status, task.output);

Request

{
    "model": "content-nsfw-moderation",
    "input": {
        "scene": "social"
    }
}

Response

{
    "id": "6f1c…",
    "object": "task",
    "model": "content-nsfw-moderation",
    "status": "succeeded",
    "output": {
        "files": [
            {
                "url": "https://…signed…",
                "mime": "…",
                "size": 0
            }
        ]
    },
    "estimated_cost": "…",
    "charged": "…"
}