Wiki Navigation

API Reference
CRUD Operations

Events API

Manage dynamic events for your server. Control helicopter crashes, police car spawns, contaminated zones, and other special events that spawn throughout the map.

Authentication required: All endpoints require a valid Bearer token. See Authentication for details.

GET

List Events

Retrieve a paginated list of events for a specific instance.

Endpoint

GET /api/instance/{instance_sid}/event

Parameters

instance_sid
string required

The SID of the instance (URL parameter)

page integer

Page number for pagination. Defaults to 1.

like string

Filter events by name using partial match.

Response

{
  "current_page": 1,
  "data": [
    {
      "sid": "abc123",
      "name": "StaticHeliCrash",
      "nominal": 3,
      "min": 1,
      "max": 5,
      "lifetime": 1800,
      "restock": 0,
      "saferadius": 500,
      "distancemin": 50,
      "distancemax": 100,
      "cleanupradius": 200,
      "active": 1
    }
  ],
  "per_page": 30,
  "total": 25
}
GET

Get Event

Retrieve details of a specific event.

Endpoint

GET /api/instance/{instance_sid}/event/{event_sid}

URL Parameters

instance_sid required

The SID of the instance

event_sid required

The SID of the event

POST

Create Event

Create a new event for an instance.

Endpoint

POST /api/instance/{instance_sid}/event

Request Body

name
string required

Event name identifier

nominal integer

Target number of active events

min integer

Minimum active events

max integer

Maximum active events

lifetime integer

Event duration in seconds

restock integer

Restock interval in seconds

saferadius integer

Safe zone radius around event

distancemin integer

Minimum spawn distance

distancemax integer

Maximum spawn distance

cleanupradius integer

Cleanup zone radius

active boolean

Whether event is enabled

PATCH

Update Event

PATCH /api/instance/{instance_sid}/event/{event_sid}

Update an existing event. Include only fields to change.

DELETE

Delete Event

DELETE /api/instance/{instance_sid}/event/{event_sid}

Permanently delete an event from the instance.