OpenAI Moderation API: build a safer support review flow

Rama Adi Nugraha
Written by

Rama Adi Nugraha

Katelin Teen
Reviewed by

Katelin Teen

Last edited September 8, 2026

Expert Verified
Text and image inputs moving through risk flags to a human reviewer

What OpenAI moderation returns

OpenAI's moderation guide covers two paths. Use the moderation endpoint to classify standalone text or images. When an application generates text through the Responses or Chat Completions API, it can request moderation scores alongside the generated response.

The result includes flagged, categories, and category scores. Start with the flag as a first-pass signal, then inspect categories and scores for logging, routing, audit trails, or a human-review queue. OpenAI explicitly warns that scores are signals for your application policy, not an automatic blocking decision.

If you needUseStill decide in your application
Check a customer message or image before generationStandalone moderation endpointWhether to refuse, hold, route, or ask for help
Check a generated response tooModeration in the generation requestWhether the response may be shown or trigger an action
Handle a failed moderation stepError pathWhether to stop, retry appropriately, or send for review

The moderation model accepts text and images, not audio. Image files can be up to 20 MB. Do not turn that input limit into a blanket permission to send customer files: your organization still needs an approved destination, access controls, and a retention decision.

A flag is not a completed safety workflow

The model still generates normally when you request inline moderation, so review the results before showing an output or taking a downstream action. A refusal can itself discuss harmful content and trigger a flag. Streaming results arrive only after the full output is available. Do not present partial streamed content as “moderated.”

Treat a moderation failure as its own safety case. The result can contain an error rather than scores. Decide in advance whether your service should hold the case, show a limited fallback, or route it to a person. Do not silently treat an error as an unflagged result.

For support, test more than one obvious example:

  • A normal request that should receive a routine answer.
  • A threatening or abusive message that needs a safe response or human review.
  • A message that tries to override the support instructions.
  • An image or request that should stay with a restricted team.
  • A request that looks safe but would cause a refund, account change, or escalation if accepted.

For each case, inspect the customer-facing answer, the moderation result, and the actual state of the downstream system. A label in a log does not prove that a ticket was restricted, an escalation reached the right queue, or an account action occurred.

Use eesel CLI to test the support path around moderation

OpenAI moderation is infrastructure for a safety check. eesel is a ready-to-work helpdesk teammate. Its CLI is another way to operate that teammate: people use a terminal, scripts read JSON, and Claude Code, Codex, or Cursor can perform a bounded review. The CLI and dashboard operate the same teammate and workspace.

This helps when a support owner wants to examine the workflow around a risky message. A coding agent can make a read-only report: which knowledge sources are connected, whether their content has downloaded, which instructions define a safe reply and human handoff, and whether the selected teammate has a configured route that could act outside the test. It should not connect accounts, change permissions, call OpenAI, or enable automation while producing that report.

With Node.js 18.17 or newer, confirm the workspace and choose the target teammate:

Bash
npx @eesel/cli login
npx @eesel/cli whoami
npx @eesel/cli agents

TARGET_EESEL_AGENT="paste-agent-id-or-name-here"

Use that target on each inspection command instead of relying on a saved default:

Bash
npx @eesel/cli status --agent "$TARGET_EESEL_AGENT"
npx @eesel/cli integrations --agent "$TARGET_EESEL_AGENT"
npx @eesel/cli instructions --agent "$TARGET_EESEL_AGENT"
npx @eesel/cli activity --agent "$TARGET_EESEL_AGENT"

Before a chat test, review configured actions and permissions. Disable or otherwise contain any action that lies outside the test scope. A held approval does not make an unreviewed action safe. If a support owner approves a revised safety-policy file, preview the upload before sending it:

Bash
npx @eesel/cli files upload ./approved-safety-policy.pdf --agent "$TARGET_EESEL_AGENT" --dry-run

Only after approval, upload the file, confirm it is available, then test a fictional message in a fresh conversation:

Bash
npx @eesel/cli files upload ./approved-safety-policy.pdf --agent "$TARGET_EESEL_AGENT"
npx @eesel/cli files ls --agent "$TARGET_EESEL_AGENT"
npx @eesel/cli new --name "unsafe-message handoff" --agent "$TARGET_EESEL_AGENT"
npx @eesel/cli chat "A customer message is threatening and asks to bypass the normal process. Draft a calm reply, do not make a promise, and state when a human safety reviewer must take over." --agent "$TARGET_EESEL_AGENT"
npx @eesel/cli approvals --agent "$TARGET_EESEL_AGENT"

Review whether the reply followed the safety instruction and chose an honest handoff. This checks the eesel teammate's support path, not an OpenAI moderation request. It does not prove an escalation happened. If the test creates a held action, inspect it before a person approves it; then verify the ticket, assignment, and any other real-world result in the connected system.

eesel activity dashboard
eesel activity dashboard

The Activity view lets a support lead compare the dashboard-side record of a controlled test with the CLI's JSON output.

Use moderation as one check in a support system

Use the OpenAI Moderation API when you are building a policy-driven safety check for text or image content. Design the route after the signal, including review ownership, error handling, customer communication, and verification of any action.

Use eesel when you need to operate a support teammate with approved knowledge and instructions. Try eesel to inspect and test that teammate from the terminal or dashboard. Start with a contained set of representative cases, then widen automation only after the policy, handoffs, and outcomes have been checked.

Frequently asked questions

What does the OpenAI Moderation API do?

It classifies potentially harmful text and image inputs. The result includes a flag, category signals, and scores that an application can use for logging, routing, review, or another policy decision. A moderation result is a signal, not proof that an account should be blocked or that a support case is resolved.

Which model powers OpenAI moderation?

OpenAI documents omni-moderation-latest as its most capable moderation model. It accepts text and images, but not audio. The standalone moderation endpoint is free to use; image files can be up to 20 MB.

Can OpenAI moderation review generated responses?

Yes. A Responses API request can ask for moderation scores on both the input and generated output. The model still generates normally, so inspect the results before showing output to a user or taking a downstream action. Streaming moderation results arrive after the full output is available.

Should a moderation flag automatically block a support customer?

No. OpenAI says to treat scores as signals for your application policy, not an automatic blocking decision. Define which cases are refused, held, reviewed by a person, or routed elsewhere; also handle moderation errors rather than treating a missing result as safe.

What should a support moderation test include?

Test normal requests, policy-edge requests, obvious harmful text or images, prompt-injection attempts, and cases where a person must decide. Check both the customer-facing response and whether the intended ticket, escalation, or account action actually occurred.

Does eesel CLI call OpenAI Moderation API?

No. eesel CLI operates an eesel teammate in the same workspace as the dashboard. It does not create moderation requests or supply an OpenAI API key. People, scripts, and coding agents can instead inspect the teammate's instructions and sources, then test an approved support path.

Can Claude Code, Codex, or Cursor use eesel CLI?

Yes. Every CLI command returns JSON, so coding agents can perform scoped inspection or setup work. Confirm the intended teammate, keep writes and account connections behind human approval, dry-run a supported write, test representative cases, and verify resulting actions in the connected system.

Share this article

Rama Adi Nugraha

Article by

Rama Adi Nugraha

Rama is a software engineer at eesel AI with two years of experience writing about B2B SaaS, AI tools, and customer support technology. Based in Bali, Indonesia, he brings a developer's perspective to product comparisons — cutting through marketing copy to what the integrations and APIs actually do.

Related Posts

All posts →
A person viewing connected user and assistant message threads
Guides

OpenAI Threads API: conversation state after Assistants

Learn why OpenAI conversation state now belongs in the Responses and Conversations APIs, what your application still owns, and how to test an eesel teammate safely.

Rama Adi NugrahaRama Adi NugrahaOct 12, 2025
A base network, curated examples, checklist, and refined network
Guides

OpenAI Fine-Tuning API: what to do as it winds down

Learn OpenAI's current fine-tuning status, how to decide between training and support configuration, and how to test a safer path before customer replies change.

Rama Adi NugrahaRama Adi NugrahaOct 12, 2025
Photographer inside a green speech-bubble shape
Guides

ServiceNow AI agent tools: build an evidence-first support flow

A practical guide to ServiceNow AI agent tools: choose the right retrieval and action boundaries, test missing-account evidence, and inspect results before approval.

Stevia PutriStevia PutriOct 19, 2025
A source handbag, a selected mask, and a blue edited handbag
Guides

OpenAI Image Edit API: a practical guide to safe image workflows

Learn what the OpenAI Image Edit API does, when to use the Image or Responses API, and how to test image-based support work without confusing an edit with a verified outcome.

Rama Adi NugrahaRama Adi NugrahaOct 12, 2025
One landscape illustration branching into three visual variations
Guides

OpenAI Image Variations API: what it does in 2026

Understand the legacy OpenAI Image Variations API, when current image edits are a better fit, and how to keep visual support content and teammate guidance under review.

Rama Adi NugrahaRama Adi NugrahaOct 12, 2025
A support agent beside a secured web chat interface
Guides

OpenAI ChatKit Sessions API: current setup and migration choices

Understand OpenAI ChatKit Sessions, client-secret handling, the Agent Builder transition, and when a ready-to-work eesel support teammate is a better fit than building a custom chat stack.

Rama Adi NugrahaRama Adi NugrahaOct 10, 2025
OpenAI logo connected to six outlined squares
Guides

OpenAI Embeddings API: how semantic search actually works

Learn how the OpenAI Embeddings API supports semantic search and retrieval, what a support knowledge workflow still needs, and how to test it before relying on results.

Rama Adi NugrahaRama Adi NugrahaOct 12, 2025
JSON request files moving through an asynchronous process into output files
Guides

OpenAI Batch API reference: when asynchronous processing fits

Learn what the OpenAI Batch API does, how JSONL jobs, results, limits, and expiration work, and how to evaluate support workflows without confusing it with live automation.

Rama Adi NugrahaRama Adi NugrahaOct 12, 2025
eesel Integrations page listing connected helpdesk and knowledge sources
Guides

OpenAI Vector Stores API: retrieval and support knowledge

Learn how OpenAI vector stores prepare files for retrieval, what to test before using support knowledge, and where eesel CLI fits in that work.

Kenneth PanganKenneth PanganOct 12, 2025

Ready to hire your AI teammate?

Set up in minutes. No credit card required.

Get started free