AI Generated Image Detector from URLs avatar

AI Generated Image Detector from URLs

Pricing

$5.00 / 1,000 successful ai image detections

Go to Apify Store
AI Generated Image Detector from URLs

AI Generated Image Detector from URLs

Detect AI-generated vs real images from public URLs. No limit on how many images you can test submit them in batches of 32 URLs per run. Get ai_generated, deepfake, and generator scores. $0.50/100 successes; pay only when detection works. URLs only - no file upload.

Pricing

$5.00 / 1,000 successful ai image detections

Rating

0.0

(0)

Developer

Manas Khandelwal

Manas Khandelwal

Maintained by Community

Actor stats

0

Bookmarked

4

Total users

3

Monthly active users

9 days ago

Last modified

Share

AI Image Detector

Who this guide is for: Anyone running this actor on Apify — via the Console, API, or integrations.
(Developer setup, deploy, and secrets are in the GitHub repo README, not here.)


Quick start

AI image detection from URLs — test any number of images in batches of up to 32 URLs per run (start multiple runs or loop the API for larger jobs). Paste public image links, click Start, open the Dataset for scores. Detect AI-generated, deepfake, and generator-specific probabilities (Midjourney, DALL·E, Stable Diffusion, and more). $0.50 per 100 successful detections — failed URLs are not charged.

{
"imageUrls": ["https://picsum.photos/id/237/400/300"],
"maxConcurrency": 3
}

What this actor does

Provide public image URLs (up to 32 per run — run again for more). For each URL you get one row in the Dataset with:

  • Success: probability scores for AI-generated content, deepfake, and specific AI generators
  • Failure: a clear error code (e.g. broken link, file too large)

You do not upload files directly — only http/https links to images that are reachable from the internet.


Before you run

Your URLs must be:

RequirementDetail
PublicNo login, no signed URLs that expire mid-run
Direct image linksJPEG, PNG, WebP, GIF, etc. — not an HTML page
SizeUp to 8 MB per image
CountUp to 32 URLs per run — any total volume via multiple runs or API loops
Schemehttp or https only

Pricing: $0.50 per 100 successful detections ($0.005 per image). You are only charged when detection succeeds — see Billing.

Not supported: localhost, private IPs, file://, or URLs behind your firewall.


How to run (Apify Console)

Step 1 — Open the actor

  1. Go to Apify Console
  2. Open ActorsAI Image Detector

Step 2 — Enter input

  1. Click the Input tab
  2. Paste or edit JSON. Minimal example:
{
"imageUrls": [
"https://picsum.photos/id/237/400/300"
]
}
  1. Or use the Image URLs field in the form UI — one URL per line (up to 32 per run)

Optional fields (defaults are fine for most runs). You cannot exceed the hard limits below — the actor clamps or rejects values server-side, even via API:

{
"imageUrls": [
"https://picsum.photos/id/237/400/300"
],
"maxConcurrency": 3,
"maxRetries": 3,
"requestTimeoutSeconds": 30
}
If you sendActor uses
maxConcurrency: 995 (capped)
maxRetries: 103 (capped)
requestTimeoutSeconds: 600120 (capped)
33+ URLsRun fails immediately (not started)

Step 3 — Start the run

  1. Click Start (or Save & Start)
  2. You are taken to the Run page — wait until status is Succeeded

Typical timing: a few seconds for one small image; longer for many or large images.

Step 4 — Read results

  1. On the run page, open the Dataset tab
  2. Each row = one input URL
  3. Click a row to expand JSON, or use Export → JSON / CSV / Excel

Success: open resulttypeai_generated (0.0–1.0). Higher = more likely AI-generated.

Failure: top-level error field explains what went wrong.

Step 5 — Re-run or schedule (optional)

  • Run again: change input → Start
  • Schedule: Schedules tab → create a cron job with the same input JSON
  • Integrate: use the API tab on the actor page for code snippets and your actor ID

Input reference

FieldRequiredDefaultDescription
imageUrlsYesList of public image URLs (1–32 per run)
maxConcurrencyNo3Parallel images (1–5, hard cap)
maxRetriesNo3Retries on transient errors (1–3, hard cap)
requestTimeoutSecondsNo30Per-request timeout in seconds (5–120, hard cap)

Values above the maximum (or below the minimum) are automatically reduced to the nearest allowed value. More than 32 URLs rejects the entire run before processing starts.

Large images are automatically resized before analysis — you do not need to compress them yourself.


How users access this actor (Console vs API)

This actor runs on Apify’s cloud. Users do not run Python on their machine — they start a run with JSON input and read results from the dataset.

Apify Console (click UI)

  1. Paste input → Start
  2. Wait for run to finish
  3. Open Dataset tab → view or export JSON/CSV

Best for manual tests and small batches.

Apify API (programmatic — “call and get results”)

Typical flow:

POST /runs → start job with { "imageUrls": [...] }
GET /runs/{id} → poll until status = SUCCEEDED
GET /datasets/{id}/items → JSON array of detection results

Example — start and wait in one call (waitForFinish waits up to 120 s):

curl -X POST \
"https://api.apify.com/v2/acts/YOUR_USERNAME~ai-image-detector/runs?token=YOUR_TOKEN&waitForFinish=120" \
-H "Content-Type: application/json" \
-d '{"imageUrls": ["https://picsum.photos/id/237/400/300"]}'

The response includes defaultDatasetId. Fetch rows:

$curl "https://api.apify.com/v2/datasets/DATASET_ID/items?token=YOUR_TOKEN"

Important: This is an async job, not a single instant HTTP response with scores. Each run takes seconds to minutes depending on image count and size. For long batches, poll the run status or use Apify webhooks when the run finishes.

Your actor ID format: YOUR_USERNAME~ai-image-detector (e.g. playful_ultrasound~ai-image-detector). Find exact URLs on the actor page → API tab.


Understanding the output

Every dataset row has the same shape:

FieldMeaning
imageUrlThe URL you submitted
modeupload = processed · rejected = blocked before download (e.g. SSRF)
attemptsHow many tries were made (includes retries)
httpStatusHTTP status from the detection service (null if not reached)
resultDetection scores on success (status + type), or error details on failure
errorPresent only when failed — see error codes below

Successful detection

{
"imageUrl": "https://picsum.photos/id/237/400/300",
"mode": "upload",
"attempts": 1,
"httpStatus": 200,
"result": {
"status": "success",
"type": {
"ai_generated": 0.02,
"ai_generators": {
"midjourney": 0.01,
"dalle": 0.01,
"stable_diffusion": 0.01
},
"deepfake": 0.01
}
}
}

How to interpret scores

FieldMeaning
result.type.ai_generatedOverall AI-generated probability (0–1)
result.type.deepfakeDeepfake probability (0–1)
result.type.ai_generators.*Per-generator hints (Midjourney, DALL·E, etc.)

There is no fixed “threshold” in the actor — your app decides what counts as “AI” (e.g. ai_generated > 0.5).

Failed detection

{
"imageUrl": "https://example.com/not-an-image.html",
"mode": "upload",
"attempts": 1,
"httpStatus": null,
"result": {
"status": "error",
"error": {
"type": "download_failed",
"message": "download_failed"
}
},
"error": "download_failed"
}

One bad URL does not stop other URLs in the same run — each row is independent.


Batch run (multiple images)

{
"imageUrls": [
"https://picsum.photos/id/237/400/300",
"https://picsum.photos/id/238/400/300",
"https://picsum.photos/id/239/400/300"
],
"maxConcurrency": 3
}
  • Up to 32 URLs per run — process any total volume by starting multiple runs or looping the API
  • Use Export on the dataset to download all results at once

Limits (hard — enforced in code)

These cannot be overridden by input, API, or Console. The actor enforces them on every run.

LimitMaximumIf exceeded
URLs per run32Run fails before processing
maxConcurrency5Silently capped to 5
maxRetries3Silently capped to 3
requestTimeoutSeconds120Silently capped to 120
requestTimeoutSeconds (min)5Silently raised to 5
Image download size8 MBRow error image_too_large
URL schemeshttp, https onlyRow error blocked_url / invalid_url_scheme

Error codes

CodeWhat happenedWhat to do
blocked_urlURL blocked (localhost, private IP, etc.)Use a public internet URL
invalid_urlMalformed URLFix the URL string
invalid_url_schemeNot http/httpsUse https://...
image_too_largeFile > 8 MBHost a smaller copy or resize before linking
download_failedCould not fetch URLCheck link works in a browser; fix 404/auth/hotlink blocking
decode_failedResponse is not a valid imageLink must point to image bytes, not HTML
compress_failedCould not prepare imageTry another format (JPEG/PNG)
rate_limitedToo many requestsLower maxConcurrency, wait, retry
request_failedTemporary network/service errorRetry the run
service_unavailableService in maintenanceTry again later (message suggests ~12 hours)

Billing

This actor uses pay per event. You pay for successful AI detections only.

Price

Rate$0.005 per successful detection
In practice$0.50 per 100 images (100 successes)
Event namedetection-result

What you pay for

ResultCharged?
result.status = "success"Yes — one detection-result event
Failed row (bad URL, >8 MB, blocked, rate limit, etc.)No — row still appears in the dataset

Example costs

RunSuccessful imagesYou pay
1 test URL1$0.005
Batch10$0.05
Full batch (max)32$0.16
Large job100 (e.g. 4 runs × 25)$0.50

Failed URLs in the same run do not increase the detection charge (you still pay normal Apify compute for the run itself — see Cost on the run detail page).

Before you start

Set a max cost per run in the Console if you want a spending cap. With 32 URLs, the maximum detection charge is 32 × $0.005 = $0.16 (plus Apify platform usage for the run).


Common questions

Can I upload a file from my computer?
No. Host the image somewhere public (S3, R2, CDN, your server) and pass the URL.

Why did my CDN URL fail?
Some CDNs block automated downloads. Test the URL in an incognito window; ensure it returns image bytes, not a login page.

Can I process more than 32 images?
Start multiple runs with 32 URLs each, or call the API in a loop from your own workflow.

Where is my API token?
Console → SettingsIntegrationsPersonal API tokens.


Need help?

Open a run → Log tab for technical details. For billing or access issues, contact the actor owner through Apify.