Integrate our powerful AI content detection into your applications with our free API.
Base URL
https://api.sapling.ai/api/v1/aidetect
Authentication
All API requests require an API key. Get your free API key from your admin dashboard.
Endpoint
POST /aidetect
Request Parameters
{
"key": "your_api_key_here",
"text": "Text to analyze",
"sent_scores": true
}
Example Request (cURL)
curl -X POST https://api.sapling.ai/api/v1/aidetect \
-H "Content-Type: application/json" \
-d '{
"key": "19K88WNW6VSCE7KZGQ0YJI0JO0FVL6RA",
"text": "The quick brown fox jumps over the lazy dog.",
"sent_scores": true
}'
Example Request (JavaScript)
fetch('https://api.sapling.ai/api/v1/aidetect', {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({
key: '19K88WNW6VSCE7KZGQ0YJI0JO0FVL6RA',
text: 'Your text here',
sent_scores: true
})
})
.then(response => response.json())
.then(data => console.log(data));
Example Request (Python)
import requests
url = "https://api.sapling.ai/api/v1/aidetect"
data = {
"key": "19K88WNW6VSCE7KZGQ0YJI0JO0FVL6RA",
"text": "Your text here",
"sent_scores": True
}
response = requests.post(url, json=data)
print(response.json())
Response Format
{
"score": 0.85,
"sentence_scores": [
{"sentence": "First sentence.", "score": 0.90},
{"sentence": "Second sentence.", "score": 0.80}
]
}
Response Fields
score- Overall AI probability (0 = human, 1 = AI)sentence_scores- Per-sentence analysis (if sent_scores=true)
Interpretation
- 0-0.4 (0-40%) - Likely human-written
- 0.41-0.7 (41-70%) - Mixed / unclear
- 0.71-1.0 (71-100%) - Likely AI-generated
Rate Limits
Free tier: 50,000 characters per day. For higher limits, contact us.
Error Codes
401- Invalid API key400- Missing required parameters429- Rate limit exceeded500- Internal server error
Support
For API support, email: support@zerogpt.getbit.me