Skip to main content
A policy is a single rule the API runs against submitted content. Each channel has its own set of enabled policies, and every API response includes a policies array with one entry per enabled policy.
const toxicityPolicy = response.policies.find(p => p.id === "toxicity");

if (toxicityPolicy?.flagged) {
  // act on the result
}
See Understanding API responses for the full response shape.

Policy types

Every policy returns a type that tells you how to read its result:
TypeWhat it doesExample fields
classifierScores content against one or more labels and returns a probabilityprobability, labels[]
entity_matcherExtracts specific entities (URLs, emails, phone numbers, etc.) from contentmatches[], signals

Available policies

Guidelines

Define custom rules in natural language. Each guideline is evaluated by an LLM and returned as its own policy.

Privacy

Personal information detection, intent to share contact details, and PII masking.

Toxicity & Hate

Toxicity, severe toxicity, and hate-based content including discrimination and extremism.

NSFW

Sexual content, flirtation, profanity, violence, and self-harm across text, image, video, and audio.

Illicit & Regulated

Drugs, alcohol, firearms, gambling, adult products, cannabis, crypto, and other regulated categories.

Spam & Security

Spam, self-promotion, code abuse, phishing, and URL extraction.

URL Risk

Real-time risk scoring for URLs — phishing, malware, brand impersonation, credential harvesting.

Topics

Political and religious content for platforms that want to keep discussions on-topic.
Insights like sentiment and language aren’t policies — they’re returned in the separate insights array and don’t affect flagging. See Understanding API responses.