POST
https://your-instance.com/v1/moderationsReturns per-category flags and scores. Useful for screening user input before it reaches an expensive model, or screening output before it reaches a person.
modelstringModeration model. Defaults to the instance's configured one.
inputstring | string[]requiredText to classify.
curl
curl https://your-instance.com/v1/moderations \
-H "Authorization: Bearer $CLAWROUTER_API_KEY" \
-H "Content-Type: application/json" \
-d '{"input": "text to check"}'200 OK
{
"results": [
{
"flagged": false,
"categories": { "violence": false, "hate": false },
"category_scores": { "violence": 0.0002, "hate": 0.0001 }
}
]
}