API Documentation
Detect sensitive data with our simple REST API.
Post
/api/analyze
Analyze text for sensitive data detection.
Base URL
https://promptguard.buildswithmike.com
Request
text (string, required) - Text to analyze
Response
success (boolean)label (string) - "Sensitive" or "Non-Sensitive"confidence (number) - Score 0-100is_sensitive (boolean)
Get
/health
Check if API is operational.
Error Codes
400
Bad Request
500
Server Error
429
Too Many Requests (throttled)
Rate Limits
POST /api/analyze: 20 requests per minute per IP
POST /api/contact: 10 requests per hour per IP
Example
import requests url = "https://promptguard.buildswithmike.com/api/analyze" payload = { "text": "My SSN is 123-45-6789" } response = requests.post(url, json=payload) print(response.json())
Response
{
"success": true,
"label": "Sensitive",
"confidence": 98.5,
"is_sensitive": true
}
lightbulb
Tip
Check /health first to ensure the model is ready.