Skip to main content
POST
/
api
/
detect
curl -X POST https://api.veri.studio/api/detect \
  -H "X-API-Key: your-api-key" \
  -H "Content-Type: application/json" \
  -d '{
    "image": "iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==",
    "model": "veri_v0"
  }'
{
  "prediction": "likely_ai",
  "confidence": 0.64,
  "ensemble_score": 0.82,
  "verdict": "likely_ai",
  "models_succeeded": 1,
  "models_total": 1,
  "model_results": {
    "veri_face": {
      "score": 0.82,
      "status": "success",
      "latency_ms": 145,
      "error": null
    }
  },
  "detection_latency_ms": 180,
  "isFake": true,
  "processingTimeMs": 180,
  "imageHash": "a1b2c3d4e5f6...",
  "cached": false,
  "timestamp": "2024-01-15T10:30:00Z"
}

Request

image
string
required
Base64-encoded image data. Supports JPEG, PNG, WebP, and GIF formats. Maximum size: 10MB.
model
string
Specific model to use for detection. Defaults to veri_v0. Available models: veri_v0, veri_v1, veri_audio_v0.

Response

prediction
string
Classification label: "ai", "likely_ai", "uncertain", "likely_real", or "real".
confidence
number
How far the model score is from the 0.5 decision boundary (0-1). Higher values indicate the model is more decisive. A score near 0 means the model is unsure.
ensemble_score
number
Raw model probability (0-1). Higher values indicate a higher likelihood the image is AI-generated.
verdict
string
Human-readable verdict: "ai_generated", "likely_ai", "uncertain", "likely_real", or "real".
models_succeeded
number
Number of models that returned results successfully.
models_total
number
Total number of models invoked.
model_results
object
Per-model results keyed by model name.
detection_latency_ms
number
Total detection latency in milliseconds.
isFake
boolean | null
true if prediction is "ai" or "likely_ai", false if "real" or "likely_real", null if "uncertain".
processingTimeMs
number
Total processing time in milliseconds.
imageHash
string
SHA-256 hash of the image.
cached
boolean
true if result was returned from cache.
timestamp
string
ISO 8601 timestamp of detection.

Classification Thresholds

The ensemble_score (model probability) is mapped to predictions using 5 tiers:
Score RangePredictionVerdictisFake
>= 0.85aiai_generatedtrue
0.55 - 0.85likely_ailikely_aitrue
0.45 - 0.55uncertainuncertainnull
0.15 - 0.45likely_reallikely_realfalse
< 0.15realrealfalse
curl -X POST https://api.veri.studio/api/detect \
  -H "X-API-Key: your-api-key" \
  -H "Content-Type: application/json" \
  -d '{
    "image": "iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNk+M9QDwADhgGAWjR9awAAAABJRU5ErkJggg==",
    "model": "veri_v0"
  }'
{
  "prediction": "likely_ai",
  "confidence": 0.64,
  "ensemble_score": 0.82,
  "verdict": "likely_ai",
  "models_succeeded": 1,
  "models_total": 1,
  "model_results": {
    "veri_face": {
      "score": 0.82,
      "status": "success",
      "latency_ms": 145,
      "error": null
    }
  },
  "detection_latency_ms": 180,
  "isFake": true,
  "processingTimeMs": 180,
  "imageHash": "a1b2c3d4e5f6...",
  "cached": false,
  "timestamp": "2024-01-15T10:30:00Z"
}