Deepfake Detection API
API reference for detecting AI-generated and manipulated images, videos, audio, and documents using advanced deepfake detection algorithms.
Deepfake Detection API
Detect AI-generated and manipulated media including face swaps, voice cloning, synthetic images, and forged documents.
Overview
Deepfake Detection API supports:
- Image analysis - Face swap, GAN-generated images, document forgery
- Video analysis - Real-time deepfakes, liveness spoofing, screen replay
- Audio analysis - Voice cloning, synthetic speech detection
- Document analysis - Forged ID documents, manipulated PDFs
2 Credits Image analysis 5 Credits Video analysis (<1 min) 10 Credits Video analysis (>1 min) 3 Credits Audio analysis 2 Credits Document analysis
Analyze Image
/api/v4/deepfake/analyse/image🔒 Auth Required2 CreditsDetect deepfake in image
Analyze an image for AI manipulation or generation.
Request (multipart/form-data)
| Field | Type | Required | Description |
|---|---|---|---|
image | file | Yes | Image file (JPEG, PNG, WebP) |
analysisType | string | No | FACE, DOCUMENT, or GENERAL (default: GENERAL) |
returnDetails | boolean | No | Include detailed analysis (default: false) |
Example Request
const formData = new FormData();
formData.append('image', imageFile);
formData.append('analysisType', 'FACE');
formData.append('returnDetails', 'true');
const response = await fetch('https://api.veriplus.co.uk/api/v4/deepfake/analyse/image', {
method: 'POST',
headers: {
'Authorization': `Bearer ${apiKey}`
},
body: formData
});
const data = await response.json();
console.log('Is deepfake:', data.data.isDeepfake);
console.log('Confidence:', data.data.confidence);Response
{
"success": true,
"data": {
"jobId": "job_img_abc123",
"isDeepfake": true,
"confidence": 87,
"manipulationType": "FACE_SWAP",
"riskScore": 82,
"recommendation": "REJECT",
"analysis": {
"faceRegions": [
{
"bbox": [120, 80, 280, 320],
"deepfakeScore": 89,
"artifacts": [
"Inconsistent lighting on face",
"Blending artifacts around jawline",
"GAN fingerprint detected"
]
}
],
"metadata": {
"resolution": "1920x1080",
"format": "JPEG",
"exifStripped": true
}
},
"creditsUsed": 2,
"processedAt": "2024-01-15T10:30:05Z"
}
}Analyze Video
/api/v4/deepfake/analyse/video🔒 Auth Required5 CreditsDetect deepfake in video
Analyze a video for face swaps, liveness spoofing, and screen replay attacks.
Request (multipart/form-data)
| Field | Type | Required | Description |
|---|---|---|---|
video | file | Yes | Video file (MP4, MOV, WebM, max 50MB) |
analysisType | string | No | VERIFICATION or GENERAL (default: GENERAL) |
includeLiveness | boolean | No | Include liveness detection (default: false) |
returnSuspiciousFrames | boolean | No | Return frame numbers (default: false) |
Example Request
const formData = new FormData();
formData.append('video', videoFile);
formData.append('analysisType', 'VERIFICATION');
formData.append('includeLiveness', 'true');
formData.append('returnSuspiciousFrames', 'true');
const response = await fetch('https://api.veriplus.co.uk/api/v4/deepfake/analyse/video', {
method: 'POST',
headers: {
'Authorization': `Bearer ${apiKey}`
},
body: formData
});
const data = await response.json();
console.log('Job ID:', data.data.jobId);
// Poll for results
const pollResults = async (jobId) => {
while (true) {
const res = await fetch(`https://api.veriplus.co.uk/api/v4/deepfake/jobs/${jobId}`, {
headers: { 'Authorization': `Bearer ${apiKey}` }
});
const result = await res.json();
if (result.data.status === 'COMPLETED') {
return result.data;
}
await new Promise(resolve => setTimeout(resolve, 3000));
}
};
const results = await pollResults(data.data.jobId);
console.log('Is deepfake:', results.result.isDeepfake);Response (Job Created)
{
"success": true,
"data": {
"jobId": "job_vid_xyz789",
"status": "PROCESSING",
"estimatedTime": "45 seconds"
}
}Processing Time: 30-120 seconds depending on video length.
Get Job Status
/api/v4/deepfake/jobs/:id🔒 Auth Required0Check analysis job status
Check the status of an ongoing or completed deepfake analysis job.
const response = await fetch(
`https://api.veriplus.co.uk/api/v4/deepfake/jobs/${jobId}`,
{
headers: {
'Authorization': `Bearer ${apiKey}`
}
}
);
const data = await response.json();
console.log('Status:', data.data.status);Response (Completed)
{
"success": true,
"data": {
"jobId": "job_vid_xyz789",
"status": "COMPLETED",
"video": {
"filename": "verification_video.mp4",
"duration": "12.5 seconds",
"frameCount": 375,
"resolution": "1280x720",
"fps": 30
},
"result": {
"isDeepfake": true,
"confidence": 89,
"manipulationType": "FACE_SWAP",
"riskScore": 85,
"recommendation": "REJECT"
},
"analysis": {
"temporalCoherence": {
"score": 42,
"issues": ["Irregular blinking", "Micro-jitter"]
},
"faceDetection": {
"averageConfidence": 76,
"stableDetection": false
},
"audioVisualSync": {
"lipSyncScore": 65,
"verdict": "POOR_SYNC"
},
"screenReplay": {
"detected": false
},
"liveness": {
"result": "FAIL",
"spoofingType": "DEEPFAKE_VIDEO"
}
},
"suspiciousFrames": [
{
"frameNumber": 45,
"timestamp": "1.5s",
"issue": "Face detection dropped",
"confidence": 42
}
],
"creditsUsed": 5,
"completedAt": "2024-01-15T10:31:05Z"
}
}Analyze Audio
/api/v4/deepfake/analyse/audio🔒 Auth Required3 CreditsDetect voice cloning and synthetic speech
Analyze audio for voice cloning, synthetic speech, and audio manipulation.
Request (multipart/form-data)
| Field | Type | Required | Description |
|---|---|---|---|
audio | file | Yes | Audio file (MP3, WAV, M4A, max 10MB) |
referenceAudio | file | No | Known authentic sample for comparison |
const formData = new FormData();
formData.append('audio', audioFile);
const response = await fetch('https://api.veriplus.co.uk/api/v4/deepfake/analyse/audio', {
method: 'POST',
headers: {
'Authorization': `Bearer ${apiKey}`
},
body: formData
});
const data = await response.json();
console.log('Is synthetic:', data.data.isSynthetic);
console.log('Confidence:', data.data.confidence);Response
{
"success": true,
"data": {
"jobId": "job_aud_abc123",
"isSynthetic": true,
"confidence": 94,
"method": "TTS_ENGINE",
"riskScore": 91,
"recommendation": "REJECT",
"analysis": {
"spectralAnomalies": true,
"unnaturalProsody": true,
"modelFingerprint": "OpenAI_TTS_v1",
"voicePrintMatch": false
},
"creditsUsed": 3,
"processedAt": "2024-01-15T10:30:08Z"
}
}List Jobs
/api/v4/deepfake/jobs🔒 Auth Required0List all deepfake analysis jobs
Retrieve a paginated list of deepfake analysis jobs.
const params = new URLSearchParams({
status: 'COMPLETED',
mediaType: 'VIDEO',
limit: '50'
});
const response = await fetch(
`https://api.veriplus.co.uk/api/v4/deepfake/jobs?${params}`,
{
headers: {
'Authorization': `Bearer ${apiKey}`
}
}
);
const data = await response.json();
console.log(`Found ${data.data.length} jobs`);Confidence Scores
| Score | Assessment | Recommendation |
|---|---|---|
| 90-100% | Highly likely deepfake | Reject |
| 70-89% | Likely deepfake | Manual review |
| 40-69% | Uncertain | Enhanced verification |
| 0-39% | Likely authentic | Accept |
Manipulation Types
Images
FACE_SWAP- Face replaced with different personGAN_GENERATED- Entirely AI-generated imagePHOTO_MANIPULATION- Edited/composited imageDOCUMENT_FORGERY- Forged ID document
Videos
FACE_SWAP- Real-time or post-processed face replacementVIDEO_REPLAY- Pre-recorded video played to cameraLIVENESS_SPOOF- Deepfake passing liveness checksAUDIO_VISUAL_MISMATCH- Lip-sync inconsistencies
Audio
VOICE_CLONING- Cloned voice using TTSTTS_ENGINE- Synthetic speech from textAUDIO_MANIPULATION- Edited/spliced audio
Webhooks
Receive notifications when analysis completes:
Events:
deepfake.scan_completed- Analysis finisheddeepfake.deepfake_detected- Deepfake confirmed (high confidence)deepfake.job_failed- Analysis failed
Webhook Payload:
{
"event": "deepfake.deepfake_detected",
"timestamp": "2024-01-15T10:31:05Z",
"data": {
"jobId": "job_vid_xyz789",
"mediaType": "VIDEO",
"isDeepfake": true,
"confidence": 89,
"manipulationType": "FACE_SWAP"
}
}Best Practices
- Use in Verification Workflows: Scan selfies and ID documents during identity verification
- Set Appropriate Thresholds: Use 70%+ confidence for rejection
- Manual Review Uncertain Cases: 70-89% confidence should be reviewed by humans
- Check Videos with Liveness: Always enable liveness detection for verification videos
- Monitor False Positives: Track rejection rate to tune thresholds
- Use Webhooks for Videos: Don't poll - video analysis takes 30-120 seconds
Error Handling
| Error Code | HTTP Status | Description | Solution |
|---|---|---|---|
INVALID_FILE_FORMAT | 400 | Unsupported file format | Use JPEG/PNG/MP4/WAV |
FILE_TOO_LARGE | 413 | File exceeds size limit | Reduce file size |
INSUFFICIENT_CREDITS | 402 | Not enough credits | Purchase credits |
ANALYSIS_FAILED | 500 | Technical failure | Retry or contact support |
NO_FACE_DETECTED | 400 | No face found in image/video | Upload image with visible face |
Rate Limits
| Plan | Concurrent Jobs |
|---|---|
| FREE | 1 |
| BASIC | 3 |
| PROFESSIONAL | 10 |
| ENTERPRISE | 50 |
Queuing: Jobs exceeding concurrent limit are queued and processed when slots available.
Next Steps
Ready to get started?
Start with our free plan. No credit card required.