API documentation
Run Probator's checks from your own software: AI detection (with our own detection model, a rewrite test and an expert reading), grammar and style suggestions, plagiarism and hidden-mark forensics. The API uses the same credits as your plan.
Overview
- API access is included in the Pro and Team plans.
- Send text as JSON, or upload a file (PDF, DOCX, TXT, MD, HTML, up to 20 MB) as
multipart/form-data. - Every response is JSON. Successful checks return the full report; errors return
{"detail": "...", "code": "..."}. - CORS is enabled, but never put an API key in code that runs in a user's browser. Call the API from your server.
Authentication
Create a key in the editor under Account → API keys. The full key is shown once. Send it in the Authorization header:
Authorization: Bearer pb_live_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Keys draw credits from the account that created them. Revoke a key immediately if it leaks.
Requests
JSON body fields:
| Field | Type | Description |
|---|---|---|
text | string | The text to check (up to 400,000 characters). Required unless you upload a file. |
checks | object | {"ai": true, "grammar": false, "plagiarism": false, "deep": false}. Only for /v1/analyze. |
ui_lang | string | Language for grammar explanations: en, pt, es, fr, de or it. Default en. |
store | boolean | Also add the text's fingerprints to your comparison library (plagiarism only). |
With multipart/form-data, send the same fields as form fields (booleans as "true") plus a file part. Check flags can be sent directly as ai, grammar, plagiarism, deep.
POST/v1/analyze
Runs any combination of checks in one request. AI detection is on by default.
curl https://probator.ai/v1/analyze \
-H "Authorization: Bearer $PROBATOR_KEY" \
-H "Content-Type: application/json" \
-d '{"text": "Paste the text to check here…", "checks": {"ai": true, "grammar": true}}'
# Upload a file instead
curl https://probator.ai/v1/analyze \
-H "Authorization: Bearer $PROBATOR_KEY" \
-F file=@essay.pdf -F ai=true -F plagiarism=true
import os, requests
r = requests.post(
"https://probator.ai/v1/analyze",
headers={"Authorization": f"Bearer {os.environ['PROBATOR_KEY']}"},
json={"text": open("essay.txt").read(), "checks": {"ai": True, "grammar": True}},
timeout=120,
)
r.raise_for_status()
report = r.json()
print(report["verdict"]["label"], report["verdict"]["p_ai"])
print("credits left:", r.headers.get("x-credits-remaining"))
const res = await fetch("https://probator.ai/v1/analyze", {
method: "POST",
headers: { Authorization: `Bearer ${process.env.PROBATOR_KEY}`, "Content-Type": "application/json" },
body: JSON.stringify({ text, checks: { ai: true, plagiarism: true } }),
});
if (!res.ok) throw new Error((await res.json()).detail);
const report = await res.json();
console.log(report.verdict.p_ai, report.plagiarism?.similarity);
Shortcut endpoints
Each runs a single check and accepts the same body (without checks):
POST/v1/detect | AI detection only. Send "deep": true for a deeper reading (+1,500 credits). |
POST/v1/grammar | Grammar and style suggestions only. |
POST/v1/plagiarism | Plagiarism check only. |
GET/v1/usage
Returns your plan and credit balance:
{
"plan": "pro",
"credits": { "allowance": 500000, "used": 18250, "bonus": 0, "remaining": 481750,
"period_start": 1791244800000, "period_end": 1793836800000 }
}
Response
The report contains the sections for the checks you ran. Character offsets (start, end) refer to the text field of the response, which is your text with invisible characters removed and look-alike letters normalised.
| Field | Description |
|---|---|
verdict | key (ai, likely_ai, uncertain, mixed, likely_human, human), label, p_ai (0–1), p_ai_own (our model's score), confidence, ai_share, hard_evidence |
sentences[] | Per-sentence start, end, p_ai |
evidence[] | Each signal with its label, description and weight |
review | Expert reading: summary, quoted indicators, human signals |
corrections | edits[] with start, end, original, replacement, type, explanation; score (0–100) |
plagiarism | similarity (0–1), sources[] with title, URL and coverage, matched spans[] |
findings[] | Hidden-mark and metadata findings with severity and evidence |
language, stylometry, typography, file | Language detection, style statistics and file metadata |
credits | used and remaining for this request |
AI-detection results are probabilities, not proof. If you show them to your users, follow our AI Policy.
Credits and headers
AI detection costs 1 credit per word, grammar 1 per 3 words, plagiarism 2 per word, and a deep scan adds 1,500. Failed checks are not charged, and an identical request repeated within 24 hours is served from cache for free (not for plagiarism). Each response includes:
x-credits-used: credits charged for this requestx-credits-remaining: balance after the requestx-cache:hitormiss
MCP server for AI agents
Probator is also a remote Model Context Protocol server, so assistants such as Claude, ChatGPT, Cursor or VS Code agents can run checks directly. It uses your API key and your plan's credits, exactly like the REST API.
| Endpoint | https://probator.ai/mcp (Streamable HTTP) |
| Authentication | Authorization: Bearer pb_live_… |
check_ai | AI-generated text detection with evidence and AI provenance marks (1 credit per word) |
check_grammar | Grammar and style corrections with explanations (1 credit per 3 words) |
check_plagiarism | Originality and matching sources (2 credits per word) |
check_all | All three checks in one call |
get_credits | Plan and remaining credits (free) |
Claude Code
claude mcp add --transport http probator https://probator.ai/mcp \ --header "Authorization: Bearer $PROBATOR_KEY"
Cursor, VS Code and other clients (MCP configuration file)
{
"mcpServers": {
"probator": {
"type": "http",
"url": "https://probator.ai/mcp",
"headers": { "Authorization": "Bearer pb_live_YOUR_KEY" }
}
}
}
Clients that only run local servers can connect through mcp-remote:
npx mcp-remote https://probator.ai/mcp --header "Authorization: Bearer pb_live_YOUR_KEY"
Keep the key out of shared configuration files. Results returned to the agent include the same "probabilities, not proof" notice as the editor.
Errors
| Status | code | Meaning |
|---|---|---|
| 400 | empty, no_checks, bad_json | The request is incomplete or malformed |
| 401 | unauthenticated, invalid_key | Missing, invalid or revoked API key |
| 402 | insufficient_credits | Not enough credits; needed says how many |
| 403 | plan_required | Your plan doesn't include this feature |
| 413 | file_too_large, text_too_long, too_many_words | Over a size limit |
| 415 | unsupported_type | File type not supported |
| 422 | unreadable | The file couldn't be read |
| 429 | rate_limited | Too many requests; retry after a minute |
| 5xx | internal | Our error; retry with exponential backoff |
Limits
- 60 requests per minute per key.
- Up to 60,000 words per check on paid plans.
- Files up to 20 MB.
- Requests can take 5–60 seconds depending on length and checks; use a timeout of at least 120 seconds.
Terms
Use of the API is subject to the Terms of Service, the AI Policy and, if you process other people's personal data, the Data Processing Agreement. Questions: hello@probator.ai.