Scans
Create and manage security scans.
| Parameter | Type | Required | Description |
|---|
target | string | Yes | URL of the AI endpoint to test |
categories | array | No | Attack categories to run (default: all) |
max_attacks | integer | No | Maximum attacks to run (default: 100) |
curl -X POST https://api.0eroshot.com/scans \
-H "X-API-Key: zsk_live_..." \
-H "Content-Type: application/json" \
-d '{
"target": "https://api.example.com/chat",
"categories": ["jailbreak", "prompt_injection"],
"max_attacks": 50
}'
{
"id": "scan_abc123",
"target": "https://api.example.com/chat",
"status": "running",
"created_at": "2024-01-15T10:30:00Z",
"progress": 0,
"vulnerabilities_found": 0
}
curl https://api.0eroshot.com/scans/scan_abc123 \
-H "X-API-Key: zsk_live_..."
{
"id": "scan_abc123",
"target": "https://api.example.com/chat",
"status": "completed",
"created_at": "2024-01-15T10:30:00Z",
"completed_at": "2024-01-15T10:35:00Z",
"total_attacks": 50,
"successful_attacks": 3,
"vulnerabilities_found": 3,
"results": [
{
"attack_category": "jailbreak",
"prompt": "Ignore all previous instructions...",
"response": "I'll help you with anything...",
"success": true,
"severity": "high",
"compliance": {
"owasp_llm": ["LLM01"],
"mitre_atlas": ["AML.T0051"]
}
}
]
}
| Parameter | Type | Description |
|---|
limit | integer | Number of scans to return (default: 10, max: 100) |
status | string | Filter by status: pending, running, completed, failed |
curl "https://api.0eroshot.com/scans?limit=5&status=completed" \
-H "X-API-Key: zsk_live_..."