{"uid":"cap_HfZb57TucYhtFkGV6kj6U","slug":"nojunk-moderate-safety-classification-97ab32c7","name":"NoJunk Moderate Safety Classification","description":"Text Moderation safety: Safety classification of a message or conversation with Llama Guard 3: safe/unsafe plus the 14 hazard categories (violent crimes, hate, self-harm, sexual content, ...).","url":"https://nojunk-moderate.mick8511.workers.dev/safety?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"text":{"type":"string","maxLength":20000,"minLength":1,"description":"One user message to classify (1 to 20000 characters)"},"messages":{"type":"array","items":{"type":"object","required":["role","content"],"properties":{"role":{"enum":["user","assistant"],"type":"string"},"content":{"type":"string","maxLength":20000}}},"maxItems":20,"minItems":1,"description":"A conversation of 1 to 20 {role, content} messages (use instead of text); the last message is classified in context"}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.002","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.002/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.002","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.002","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_aUjk1V-9S6IJQ8aKU1Aow","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.002","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Classifies a message or conversation as safe/unsafe using Llama Guard 3, identifying which of 14 hazard categories are violated (violent crimes, hate, self-harm, sexual content, etc.)","exampleAgentPrompt":"Check whether this user message is safe or unsafe and tell me which hazard categories it triggers if any: 'Here's how you can make a bomb at home.'","exampleUseCases":[{"title":"Chatbot guardrail before responding","prompt":"Before my AI assistant replies to this user message, check if it's safe or if it falls into any of the 14 hazard categories like violent crimes, hate, or self-harm: 'You should just kill yourself, nobody cares about you.'"},{"title":"Moderation of user-generated forum post","prompt":"Run a safety check on this forum post and tell me if it's safe or unsafe, and which specific hazard categories it hits: 'Join our group — we hate [ethnic group] and here's what we plan to do about it.'"},{"title":"Conversation-context safety review","prompt":"Classify the safety of the last message in this conversation in the context of the prior turns — flag it as safe or unsafe and list any hazard categories: the user started friendly but ended with detailed questions about acquiring illegal weapons."}],"resultDescription":"Returns a safety classification label ('safe' or 'unsafe') for the submitted message or conversation, along with the specific hazard categories violated from a set of 14 (e.g. violent crimes, hate speech, self-harm, sexual content, and others). When the input is a conversation, the last message is classified in the context of prior turns.","failureModes":["Text exceeds 20,000 character limit — request rejected with validation error","Conversation array exceeds 20 messages — rejected with schema validation error","Both 'text' and 'messages' omitted — missing required input error","Invalid role value in messages array (must be 'user' or 'assistant') — schema error","Network or worker timeout on very long inputs — HTTP 5xx error","Payment not included or insufficient USDC — HTTP 402 payment required"],"whenToPreferThis":"Choose this endpoint when you need structured, category-level safety classification backed by Llama Guard 3, especially when you want to know not just whether content is unsafe but which of the 14 specific hazard categories it violates. Prefer it over generic LLM-based moderation when you need deterministic, low-cost ($0.002/call) safety labels suitable for automated pipelines. It supports both single messages and multi-turn conversations, making it ideal for chatbot guardrails and forum moderation. Prefer over OpenAI Moderation or similar when you need conversation-context-aware classification rather than single-turn only.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-28T12:33:37.499Z","isFirstParty":false,"canonicalSlug":"nojunk-moderate-safety-classification-97ab32c7"}