Sonny Labs Docs
Scans

Scans

Conceptual documentation for the `/v1/scans` endpoint — how scans work, how the `tier` option selects a detector, and how to act on the returned decision.

A scan is a single POST /v1/scans call against an LLM input or output. The backend runs the configured detectors (prompt injection, PII, toxicity, policy), evaluates the active policy, and returns an allow / warn / flag / block decision your application can act on. The same surface is exposed in SaaS at https://api.sonnylabs.ai and in self-hosted deployments.

This section covers the conceptual pieces of /v1/scans that do not fit cleanly into the REST reference or an SDK quickstart.