Scan text for threats
promptguard_scan_textScan text for security threats including prompt injection, jailbreaks, PII leakage, and toxic content. Returns a decision (allow/block), confidence score, threat type, and reason. Each call counts as one Request on your PromptGuard plan. When to use: When reviewing user-facing prompts, testing LLM inputs for safety, or verifying that content is free of injection attacks before sending to an LLM.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| text | Yes | The text content to scan for security threats | |
| content_type | No | Whether the text is a prompt sent to a model or a model's response | prompt |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||