Image

Image Sensitive Content Detection

0calls
4 credits / call

This is an image content moderation API that automatically detects prohibited content in uploaded images and returns handling recommendations.

Feature Overview

Upload an image file or provide an image URL, and the API will automatically analyze the image content, returning whether it violates rules, risk level, and handling suggestions. Suitable for integration into user upload workflows to achieve automated content moderation.

Response Field Descriptions

  • is_nsfw: Whether the content is flagged as prohibited, true means prohibited, false means normal
  • nsfw_score: Confidence score for prohibited content, between 0-1, higher values indicate higher likelihood of violation
  • normal_score: Confidence score for normal content, between 0-1, complementary to nsfw_score
  • suggestion: Handling recommendation
    • pass: Content is normal, can be allowed directly
    • review: Risk detected, recommend manual review
    • block: High-risk content, recommend direct blocking
  • risk_level: Risk level
    • low: Low risk
    • medium: Medium risk
    • high: High risk
  • label: Content label, nsfw or normal
  • confidence: Overall confidence of the model's judgment
  • inference_time_ms: Model inference time in milliseconds

Request body

Form data containing image source. Must provide either 'file' or 'url'.

file
fileoptional

Image file to be detected. Supports JPG, JPEG, PNG, GIF, WebP formats, up to 20MB.

url
stringoptional

Image URL address. If both file and url are provided, file will be prioritized.

Response

200 / OK

Detection successful! Returns the NSFW analysis results of the image.

JSON

400 / Bad Request

Request parameter error. This could be due to no image provided, unsupported file format, or file too large.

JSON

413 /

File too large. The uploaded image exceeds the 20MB limit.

JSON

500 / Internal Server Error

Internal server error. An error occurred while processing the image or performing NSFW detection.

JSON