API Documentation

Access Ukraine War Analytics data programmatically through our REST API. Build applications, conduct research, or integrate conflict data into your projects.

REST APIJSON ResponsesRate Limited

Quick Start

1. Base URL

https://ukraine-war-analytics.online/api/v1

All API requests should be made to this base URL.

2. Authentication

Authorization: Bearer YOUR_API_KEY

Include your API key in the header for all requests.

Quick Example

curl -X GET "https://ukraine-war-analytics.online/api/v1/statistics/summary" \
  -H "Authorization: Bearer YOUR_API_KEY"

Rate Limits & Quotas

Free Tier

  • β€’1,000 requests/day
  • β€’60 requests/minute
  • β€’100 results per request
  • β€’Basic endpoints only

Researcher

  • β€’50,000 requests/day
  • β€’300 requests/minute
  • β€’500 results per request
  • β€’All endpoints
  • β€’Bulk export available

Enterprise

  • β€’Unlimited requests
  • β€’Dedicated rate limit
  • β€’Full data export
  • β€’Priority support
  • β€’Custom integrations

Academic & Research Access: Researchers and journalists can apply for free elevated access. Contact us with your credentials and use case.

API Endpoints

GET/api/v1/events

Retrieve a paginated list of conflict events. Supports filtering by date range, region, event type, and other criteria.

Parameters

NameTypeRequiredDescription
start_datestring (YYYY-MM-DD)NoFilter events from this date onwards
end_datestring (YYYY-MM-DD)NoFilter events up to this date
regionstringNoFilter by oblast/region name (e.g., "Kharkiv Oblast")
event_typestringNoFilter by event type (battles, shelling, explosions, etc.)
pageintegerNoPage number for pagination (default: 1)
limitintegerNoResults per page (default: 50, max: 500)
sortstringNoSort order: "date_asc" or "date_desc" (default)

Response Fields

totalintegerβ€” Total number of events matching criteria
pageintegerβ€” Current page number
pagesintegerβ€” Total number of pages
eventsarrayβ€” Array of event objects

Example Response

{
  "total": 123747,
  "page": 1,
  "pages": 2475,
  "events": [
    {
      "id": "UKR2024-01-15-0001",
      "date": "2024-01-15",
      "event_type": "Shelling/artillery/missile attack",
      "sub_event_type": "Shelling",
      "location": {
        "name": "Kharkiv",
        "oblast": "Kharkiv Oblast",
        "latitude": 49.9935,
        "longitude": 36.2304
      },
      "actors": {
        "actor1": "Military Forces of Russia",
        "actor2": "Civilians (Ukraine)"
      },
      "fatalities": 2,
      "notes": "Russian missile strike hit residential area...",
      "source": "ACLED"
    }
  ]
}
GET/api/v1/events/{id}

Retrieve detailed information about a specific event by its unique identifier.

Parameters

NameTypeRequiredDescription
idstringYesUnique event identifier (e.g., "UKR2024-01-15-0001")

Response Fields

idstringβ€” Unique event identifier
datestringβ€” Event date (YYYY-MM-DD)
event_typestringβ€” Primary event classification
sub_event_typestringβ€” Detailed event classification
locationobjectβ€” Geographic information
actorsobjectβ€” Parties involved
fatalitiesintegerβ€” Documented fatalities
notesstringβ€” Detailed event description
sourcestringβ€” Data source attribution
related_eventsarrayβ€” IDs of related events
GET/api/v1/statistics/summary

Get overall conflict statistics including total events, fatalities, date range coverage, and high-level metrics.

Response Fields

total_eventsintegerβ€” Total documented events
total_fatalitiesintegerβ€” Total documented fatalities
total_daysintegerβ€” Days of conflict covered
date_rangeobjectβ€” Start and end dates of data
events_by_typeobjectβ€” Event counts by category
last_updatedstringβ€” Data last update timestamp

Example Response

{
  "total_events": 123747,
  "total_fatalities": 28450,
  "total_days": 1442,
  "date_range": {
    "start": "2022-02-24",
    "end": "2026-02-04"
  },
  "events_by_type": {
    "Battles": 42156,
    "Shelling/artillery/missile attack": 38924,
    "Explosions/Remote violence": 21547,
    "Violence against civilians": 15234,
    "Strategic developments": 5886
  },
  "last_updated": "2026-02-04T06:00:00Z"
}
GET/api/v1/statistics/timeline

Get time-series data for events and fatalities. Supports daily, weekly, and monthly granularity.

Parameters

NameTypeRequiredDescription
granularitystringNo"day", "week", or "month" (default: "day")
start_datestringNoStart date for the timeline
end_datestringNoEnd date for the timeline
regionstringNoFilter by region
event_typestringNoFilter by event type

Response Fields

granularitystringβ€” Time granularity used
dataarrayβ€” Array of time period objects with events and fatalities
GET/api/v1/regions

List all Ukrainian regions (oblasts) with summary statistics.

Response Fields

regionsarrayβ€” Array of region objects

Example Response

{
  "regions": [
    {
      "id": "kharkiv-oblast",
      "name": "Kharkiv Oblast",
      "name_ua": "Π₯Π°Ρ€ΠΊΡ–Π²ΡΡŒΠΊΠ° ΠΎΠ±Π»Π°ΡΡ‚ΡŒ",
      "capital": "Kharkiv",
      "total_events": 18547,
      "total_fatalities": 4231,
      "area_km2": 31415,
      "population_2021": 2658461,
      "coordinates": {
        "latitude": 49.9935,
        "longitude": 36.2304
      }
    }
  ]
}
GET/api/v1/regions/{region_id}

Get detailed information about a specific region including monthly statistics and top affected locations.

Parameters

NameTypeRequiredDescription
region_idstringYesRegion identifier (e.g., "kharkiv-oblast")

Response Fields

regionobjectβ€” Region details
monthly_statsarrayβ€” Monthly event/fatality counts
top_locationsarrayβ€” Most affected locations in region
event_typesobjectβ€” Breakdown by event type
GET/api/v1/equipment

Get documented military equipment losses for both Russia and Ukraine.

Parameters

NameTypeRequiredDescription
countrystringNo"russia" or "ukraine" (default: both)
categorystringNoEquipment category (tanks, ifvs, aircraft, etc.)
statusstringNoLoss status (destroyed, damaged, captured, abandoned)

Response Fields

russiaobjectβ€” Russian equipment losses by category
ukraineobjectβ€” Ukrainian equipment losses by category
last_updatedstringβ€” Data last update timestamp

Example Response

{
  "russia": {
    "tanks": {
      "total": 3247,
      "destroyed": 2156,
      "damaged": 234,
      "captured": 567,
      "abandoned": 290
    },
    "ifvs": {
      "total": 6521,
      "destroyed": 4123,
      "damaged": 567,
      "captured": 1231,
      "abandoned": 600
    }
  },
  "ukraine": {
    "tanks": {
      "total": 892,
      "destroyed": 612,
      "damaged": 89,
      "captured": 145,
      "abandoned": 46
    }
  },
  "last_updated": "2026-02-04T06:00:00Z"
}
GET/api/v1/equipment/{category}

Get detailed equipment losses for a specific category with model-level breakdown.

Parameters

NameTypeRequiredDescription
categorystringYesEquipment category (tanks, ifvs, artillery, etc.)
countrystringNoFilter by country

Response Fields

categorystringβ€” Equipment category
modelsarrayβ€” Losses by specific model
timelinearrayβ€” Monthly loss progression
GET/api/v1/locations

List all tracked locations with event counts and geographic coordinates.

Parameters

NameTypeRequiredDescription
regionstringNoFilter by oblast
min_eventsintegerNoMinimum event count
sortstringNo"events" or "name" (default: "events")

Response Fields

totalintegerβ€” Total locations
locationsarrayβ€” Array of location objects
GET/api/v1/locations/{location_id}

Get detailed information about a specific location including all recorded events.

Parameters

NameTypeRequiredDescription
location_idstringYesLocation identifier

Response Fields

locationobjectβ€” Location details
eventsarrayβ€” All events at this location
statisticsobjectβ€” Location statistics
GET/api/v1/refugees

Get Ukrainian refugee statistics by host country and time series data.

Parameters

NameTypeRequiredDescription
countrystringNoFilter by host country

Response Fields

total_refugeesintegerβ€” Total refugees abroad
total_idpintegerβ€” Internally displaced persons
by_countryarrayβ€” Refugees by host country
timelinearrayβ€” Monthly refugee numbers

Code Examples

Python
JavaScript
cURL

🐍 Python

import requests

# Base URL for the API
BASE_URL = "https://ukraine-war-analytics.online/api/v1"

# Your API key (required for authenticated requests)
headers = {
    "Authorization": "Bearer YOUR_API_KEY",
    "Content-Type": "application/json"
}

# Example 1: Get recent events
def get_recent_events(days=7, region=None):
    """Fetch events from the last N days"""
    from datetime import datetime, timedelta
    
    end_date = datetime.now().strftime("%Y-%m-%d")
    start_date = (datetime.now() - timedelta(days=days)).strftime("%Y-%m-%d")
    
    params = {
        "start_date": start_date,
        "end_date": end_date,
        "limit": 100
    }
    
    if region:
        params["region"] = region
    
    response = requests.get(
        f"{BASE_URL}/events",
        headers=headers,
        params=params
    )
    
    return response.json()

# Example 2: Get statistics summary
def get_summary():
    """Fetch overall conflict statistics"""
    response = requests.get(
        f"{BASE_URL}/statistics/summary",
        headers=headers
    )
    return response.json()

# Example 3: Get equipment losses
def get_equipment_losses(category=None, country=None):
    """Fetch equipment loss data"""
    params = {}
    if category:
        params["category"] = category
    if country:
        params["country"] = country
    
    response = requests.get(
        f"{BASE_URL}/equipment",
        headers=headers,
        params=params
    )
    return response.json()

# Example 4: Build a timeline chart
def get_timeline_data(granularity="week", months=6):
    """Get time series data for visualization"""
    from datetime import datetime, timedelta
    
    end_date = datetime.now()
    start_date = end_date - timedelta(days=30*months)
    
    params = {
        "granularity": granularity,
        "start_date": start_date.strftime("%Y-%m-%d"),
        "end_date": end_date.strftime("%Y-%m-%d")
    }
    
    response = requests.get(
        f"{BASE_URL}/statistics/timeline",
        headers=headers,
        params=params
    )
    
    return response.json()

# Usage examples
if __name__ == "__main__":
    # Get events from Kharkiv in the last week
    kharkiv_events = get_recent_events(days=7, region="Kharkiv Oblast")
    print(f"Events in Kharkiv (last 7 days): {len(kharkiv_events['events'])}")
    
    # Get summary statistics
    summary = get_summary()
    print(f"Total events documented: {summary['total_events']:,}")
    print(f"Days of conflict: {summary['total_days']}")
    
    # Get Russian tank losses
    tanks = get_equipment_losses(category="tanks", country="russia")
    print(f"Russian tanks lost: {tanks['russia']['tanks']['total']:,}")

πŸ“œ JavaScript / Node.js

// Using fetch API (Browser/Node.js 18+)
const BASE_URL = "https://ukraine-war-analytics.online/api/v1";
const API_KEY = "YOUR_API_KEY";

const headers = {
  "Authorization": `Bearer ${API_KEY}`,
  "Content-Type": "application/json"
};

// Example 1: Get recent events
async function getRecentEvents(days = 7, region = null) {
  const endDate = new Date().toISOString().split('T')[0];
  const startDate = new Date(Date.now() - days * 24 * 60 * 60 * 1000)
    .toISOString().split('T')[0];
  
  const params = new URLSearchParams({
    start_date: startDate,
    end_date: endDate,
    limit: 100
  });
  
  if (region) {
    params.append('region', region);
  }
  
  const response = await fetch(
    `${BASE_URL}/events?${params}`,
    { headers }
  );
  
  return response.json();
}

// Example 2: Get statistics summary
async function getSummary() {
  const response = await fetch(
    `${BASE_URL}/statistics/summary`,
    { headers }
  );
  return response.json();
}

// Example 3: Get equipment losses
async function getEquipmentLosses(category = null, country = null) {
  const params = new URLSearchParams();
  if (category) params.append('category', category);
  if (country) params.append('country', country);
  
  const url = params.toString() 
    ? `${BASE_URL}/equipment?${params}` 
    : `${BASE_URL}/equipment`;
  
  const response = await fetch(url, { headers });
  return response.json();
}

// Example 4: React hook for events
function useConflictEvents(region, days = 7) {
  const [events, setEvents] = React.useState([]);
  const [loading, setLoading] = React.useState(true);
  const [error, setError] = React.useState(null);
  
  React.useEffect(() => {
    setLoading(true);
    getRecentEvents(days, region)
      .then(data => {
        setEvents(data.events);
        setLoading(false);
      })
      .catch(err => {
        setError(err);
        setLoading(false);
      });
  }, [region, days]);
  
  return { events, loading, error };
}

// Usage examples
async function main() {
  // Get events from Donetsk
  const donetskEvents = await getRecentEvents(7, "Donetsk Oblast");
  console.log(`Events in Donetsk: ${donetskEvents.events.length}`);
  
  // Get summary
  const summary = await getSummary();
  console.log(`Total events: ${summary.total_events.toLocaleString()}`);
  
  // Get equipment losses
  const equipment = await getEquipmentLosses();
  console.log(`Russian tanks lost: ${equipment.russia.tanks.total}`);
}

main().catch(console.error);

πŸ’» cURL

# Get recent events
curl -X GET "https://ukraine-war-analytics.online/api/v1/events?start_date=2024-01-01&end_date=2024-01-31&limit=10" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json"

# Get events for specific region
curl -X GET "https://ukraine-war-analytics.online/api/v1/events?region=Kharkiv%20Oblast&limit=50" \
  -H "Authorization: Bearer YOUR_API_KEY"

# Get summary statistics
curl -X GET "https://ukraine-war-analytics.online/api/v1/statistics/summary" \
  -H "Authorization: Bearer YOUR_API_KEY"

# Get timeline data (weekly granularity)
curl -X GET "https://ukraine-war-analytics.online/api/v1/statistics/timeline?granularity=week&start_date=2023-01-01" \
  -H "Authorization: Bearer YOUR_API_KEY"

# Get all regions
curl -X GET "https://ukraine-war-analytics.online/api/v1/regions" \
  -H "Authorization: Bearer YOUR_API_KEY"

# Get equipment losses (Russian tanks)
curl -X GET "https://ukraine-war-analytics.online/api/v1/equipment?country=russia&category=tanks" \
  -H "Authorization: Bearer YOUR_API_KEY"

# Get specific event details
curl -X GET "https://ukraine-war-analytics.online/api/v1/events/UKR2024-01-15-0001" \
  -H "Authorization: Bearer YOUR_API_KEY"

# Get locations in region
curl -X GET "https://ukraine-war-analytics.online/api/v1/locations?region=Donetsk%20Oblast&min_events=100" \
  -H "Authorization: Bearer YOUR_API_KEY"

Error Codes

CodeStatusDescription
200OKRequest successful
400Bad RequestInvalid parameters or malformed request
401UnauthorizedMissing or invalid API key
403ForbiddenAccess denied to this resource
404Not FoundRequested resource does not exist
429Too Many RequestsRate limit exceeded. Retry after cooldown.
500Server ErrorInternal server error. Please retry or contact support.

Error Response Format

{
  "error": {
    "code": 400,
    "message": "Invalid date format. Use YYYY-MM-DD.",
    "field": "start_date"
  }
}

Data Formats & Types

Date Formats

  • DateYYYY-MM-DD
  • TimestampISO 8601
  • Example2024-01-15T14:30:00Z

Event Types

  • Battles β€” Armed clashes
  • Shelling/artillery/missile attack
  • Explosions/Remote violence
  • Violence against civilians
  • Strategic developments

Equipment Categories

  • tanks β€” Main battle tanks
  • ifvs β€” Infantry fighting vehicles
  • apcs β€” Armored personnel carriers
  • artillery β€” Artillery systems
  • mlrs β€” Rocket artillery
  • aircraft β€” Fixed-wing aircraft
  • helicopters β€” Rotary-wing aircraft
  • drones β€” UAVs/UCAVs
  • air-defense β€” AA systems
  • naval β€” Ships and boats

Loss Status

  • destroyed β€” Completely destroyed
  • damaged β€” Damaged but potentially repairable
  • captured β€” Captured by opposing force
  • abandoned β€” Left behind/discarded

JSON Schema

Formal JSON Schema definitions for validating API responses and generating client code. Compatible with JSON Schema Draft-07.

Event Object Schema

{
  "$schema": "https://json-schema.org/draft-07/schema#",
  "$id": "https://ukraine-war-analytics.online/schemas/event.json",
  "title": "ConflictEvent",
  "type": "object",
  "required": ["event_id", "date", "event_type", "location", "fatalities"],
  "properties": {
    "event_id":     { "type": "string",  "description": "Unique event identifier (ACLED-based)" },
    "date":         { "type": "string",  "format": "date", "description": "ISO 8601 date of event" },
    "event_type":   { "type": "string",  "enum": ["Battles", "Explosions/Remote violence", "Violence against civilians", "Protests", "Strategic developments"] },
    "sub_event_type": { "type": "string", "description": "Sub-category of the event type" },
    "location": {
      "type": "object",
      "required": ["name", "lat", "lng", "admin1"],
      "properties": {
        "name":   { "type": "string",  "description": "Location name" },
        "lat":    { "type": "number",  "minimum": -90,  "maximum": 90  },
        "lng":    { "type": "number",  "minimum": -180, "maximum": 180 },
        "admin1": { "type": "string",  "description": "Oblast / region name" }
      }
    },
    "actors": {
      "type": "object",
      "properties": {
        "actor1": { "type": "string", "description": "Primary actor name" },
        "actor2": { "type": "string", "description": "Secondary actor name" }
      }
    },
    "fatalities": { "type": "integer", "minimum": 0, "description": "Estimated fatalities" },
    "notes":      { "type": "string",  "description": "Narrative description of the event" },
    "source":     { "type": "string",  "description": "Original data source (e.g. ACLED)" }
  }
}

Equipment Loss Object Schema

{
  "$schema": "https://json-schema.org/draft-07/schema#",
  "$id": "https://ukraine-war-analytics.online/schemas/equipment-loss.json",
  "title": "EquipmentLoss",
  "type": "object",
  "required": ["id", "system", "category", "side", "status", "date_confirmed"],
  "properties": {
    "id":             { "type": "string",  "description": "Unique loss record identifier" },
    "system":         { "type": "string",  "description": "Equipment system name (e.g. T-72B3)" },
    "category":       { "type": "string",  "enum": ["tanks", "armoured_vehicles", "artillery", "mlrs", "air_defence", "aircraft", "helicopters", "naval", "drones", "vehicles", "other"] },
    "side":           { "type": "string",  "enum": ["Russia", "Ukraine"] },
    "status":         { "type": "string",  "enum": ["destroyed", "damaged", "captured", "abandoned"] },
    "date_confirmed": { "type": "string",  "format": "date", "description": "Date loss was visually confirmed" },
    "evidence_url":   { "type": "string",  "format": "uri",  "description": "Link to photographic/video evidence" },
    "location": {
      "type": "object",
      "properties": {
        "name":   { "type": "string" },
        "lat":    { "type": "number" },
        "lng":    { "type": "number" },
        "oblast": { "type": "string" }
      }
    },
    "quantity": { "type": "integer", "minimum": 1, "default": 1 }
  }
}

Schema Usage

Use these schemas with AJV, Zod, or any JSON Schema validator to validate API responses at runtime.

Webhooks (Beta)

Subscribe to real-time updates when new events are recorded. Webhooks are available for Researcher and Enterprise tier users.

Available Events

  • event.created β€” New event recorded
  • equipment.updated β€” Equipment loss updated
  • statistics.daily β€” Daily summary

Webhook Payload

{
  "type": "event.created",
  "timestamp": "2024-01-15T14:30:00Z",
  "data": { ... }
}

SDKs & Libraries

🐍

Python SDK

pip install ukraine-war-analyticsDocumentation β†’
πŸ“¦

JavaScript SDK

npm install ukraine-war-analyticsDocumentation β†’
πŸ”·

R Package

Coming SoonIn development

Terms of Use & Attribution

Required Attribution

When using data from our API, please include attribution:

Data source: Ukraine War Analytics (ukraine-war-analytics.online)

Permitted Uses

  • βœ“ Academic research and publications
  • βœ“ Journalism and news reporting
  • βœ“ Non-commercial applications
  • βœ“ Data analysis and visualization

By using our API, you agree to our Terms of Service and Privacy Policy. Commercial use requires a separate license agreement.

πŸ“§ Contact Support

Questions about the API? Need help with integration? Reach out to our team.

❓ FAQ

Find answers to common questions about our data and platform.