Loading...
Animal Detect logo

Batch Detect Urban

1 credit / image
POST /api/v1/batch-detect-urban

Best for urban, indoor, roadside, zoo, farm, and other human-modified settings when you need bounding boxes plus taxonomy-rich labels across many files.

Try in Playground

Required Parameters

  • images (file[] | base64[]) Array of 1-10 images. Practical combined raw limit is about 1.1MB because Vertex enforces a 1.5MB encoded request cap.

Optional Parameters

  • country (string) Optional shared geofencing hint (CCA2/CCA3/full country name).
  • threshold (number) Confidence threshold between 0.01 and 0.99. Default: 0.2.

Supports multipart/form-data (`images` repeated) and application/json with base64 string array. This Vertex-backed route enforces the upstream 1.5MB request cap, so keep combined raw image payloads around 1.1MB or less.

Status Codes

200Batch detection completed.
400Validation error (empty list, too many images, invalid threshold).
413Batch payload too large for the Vertex-backed request limit.
401Invalid, missing, or revoked API key.
402Credit limit exceeded.
429Rate limit exceeded.
503Upstream Vertex service error.
  • Best for: bulk urban-focused detection with taxonomy-rich output.
Node.js / Express
const form = new FormData()
form.append('images', firstFile)
form.append('images', secondFile)
form.append('country', 'USA')
form.append('threshold', '0.2')

const response = await fetch('https://www.animaldetect.com/api/v1/batch-detect-urban', {
  method: 'POST',
  headers: {
    Authorization: 'Bearer ' + process.env.ANIMAL_DETECT_API_KEY,
  },
  body: form,
})

const data = await response.json()

Example Response

JSON
{
  "id": "f7956216-c346-4fbf-a693-3eefc0148125",
  "expires_at": "2026-03-12T09:44:20.954Z",
  "results": [
    {
      "index": 0,
      "filename": "street-fox.jpg",
      "annotations": [],
      "info": {
        "processing_time_ms": 410,
        "model_version": "mdv5-speciesnet",
        "model_id": "mdv5-speciesnet",
        "country_processed": "USA",
        "threshold_applied": 0.2
      }
    }
  ],
  "info": {
    "total_processed": 1,
    "total_time_ms": 410,
    "model_version": "mdv5-speciesnet",
    "model_id": "mdv5-speciesnet",
    "country_processed": "USA",
    "threshold_applied": 0.2
  }
}