openai · OpenAI Platform Docs
Moderation | OpenAI API
Explains how to implement the Moderation API to check content for violations of safety policies such as hate speech, self-harm, and sexual content.
Derived skill
Files assembled from official documentation
Viewing SKILL.md
Moderation | OpenAI API
Explains how to implement the Moderation API to check content for violations of safety policies such as hate speech, self-harm, and sexual content.
When To Use
Use when you need to programmatically detect and filter unsafe or policy-violating text input or output in an AI-powered application.
Reference Files
| File | Contains | Use For |
|---|---|---|
SKILL.md | Entry point: scope, routing table, and workflow. | Start here. |
docs/moderation-openai-api-workflow-guide.md | A guide explaining how to use the OpenAI moderation endpoint to identify and take action on potentially harmful text or image content. | Questions about a guide explaining how to use the OpenAI moderation endpoint to identify and take action on potentially harmful text... |
examples/moderation-openai-api-openai-moderation-api-python-client.text | A Python code snippet demonstrating how to use the OpenAI client to create a moderation request using the omni-moderation-latest model. | Exact payloads, commands, or snippets shown in A Python code snippet demonstrating how to use the OpenAI client to create a moderation request using the omni-modera... |
examples/moderation-openai-api-openai-moderation-api-nodejs-quickstart.text | A JavaScript code snippet demonstrating how to use the OpenAI Node.js SDK to create a moderation request using the omni-moderation-latest model. | Exact payloads, commands, or snippets shown in A JavaScript code snippet demonstrating how to use the OpenAI Node.js SDK to create a moderation request using the om... |
examples/moderation-openai-api-openai-moderation-api-curl-request.text | A curl command demonstrating how to send a POST request to the OpenAI Moderation API using the omni-moderation-latest model. | Exact payloads, commands, or snippets shown in A curl command demonstrating how to send a POST request to the OpenAI Moderation API using the omni-moderation-latest... |
examples/moderation-openai-api-openai-moderation-python-client.text | A Python code snippet demonstrating how to use the OpenAI client to create a moderation request with text and image inputs. | Exact payloads, commands, or snippets shown in A Python code snippet demonstrating how to use the OpenAI client to create a moderation request with text and image i... |
examples/moderation-openai-api-openai-moderation-api-nodejs-omni-moderation-lates.text | A Node.js code example demonstrating how to use the omni-moderation-latest model to classify text and image inputs via the OpenAI Moderation API. | Exact payloads, commands, or snippets shown in A Node.js code example demonstrating how to use the omni-moderation-latest model to classify text and image inputs vi... |
examples/moderation-openai-api-openai-moderation-api-curl-request-2.text | A curl command demonstrating how to send a POST request to the OpenAI Moderation API using the omni-moderation-latest model with text and image inputs. | Exact payloads, commands, or snippets shown in A curl command demonstrating how to send a POST request to the OpenAI Moderation API using the omni-moderation-latest... |
examples/moderation-openai-api-openai-moderation-api-response.text | A sample JSON response from the OpenAI Moderation API showing flagged categories and model metadata. | Exact payloads, commands, or snippets shown in A sample JSON response from the OpenAI Moderation API showing flagged categories and model metadata. |
What This Skill Covers
- Use the moderations endpoint to check whether text or images are potentially harmful. If harmful content is identified, you can take corrective action, like...
- Main sections:
Quickstart,Content classifications.
Workflow
- Open the most relevant file under
docs/for the exact documented workflow and wording. - Open
schemas/files for exact structured contracts. - Open
examples/files for concrete requests, commands, snippets, and manifests. - Do not add behavior or configuration that is not present in the attached source files.
Canonical source: https://developers.openai.com/api/docs/guides/moderation
