Overrides
Overrides provide a way to temporarily force resources on or off, taking precedence over any active schedules.
Overview
Overrides are useful for situations like production incidents, maintenance windows, or demo environments where you need to keep resources running regardless of their schedule.
Override Priority
Active overrides always take precedence over schedules. A
force_on override will prevent the scheduler from stopping a resource, and a force_off override will prevent it from being started — until the override expires or is manually deleted.Override Actions
| Action | Behavior |
|---|---|
force_on | Keeps the resource running. Scheduler skip-stop actions are ignored. |
force_off | Keeps the resource stopped. Scheduler skip-start actions are ignored. |
Create Override
POST
/overridesCreate an override for a specific resource.
Requestbash
curl -X POST https://zopnight.com/api/overrides \
-H "Authorization: Bearer <token>" \
-H "Content-Type: application/json" \
-d '{
"resourceUID": "i-0abc123def456",
"action": "force_on",
"reason": "Production incident - keep running for investigation",
"expiresAt": "2025-01-20T18:00:00Z"
}'Responsejson
{
"data": {
"id": "ovr_abc123",
"resourceUID": "i-0abc123def456",
"action": "force_on",
"reason": "Production incident - keep running for investigation",
"createdBy": "user@company.com",
"expiresAt": "2025-01-20T18:00:00Z",
"createdAt": "2025-01-20T10:00:00Z"
}
}Create Group Override
POST
/resource-groups/{groupID}/overridesCreate an override for all resources in a group.
Requestbash
curl -X POST https://zopnight.com/api/resource-groups/grp_abc123/overrides \
-H "Authorization: Bearer <token>" \
-H "Content-Type: application/json" \
-d '{
"action": "force_on",
"reason": "Demo environment for client presentation",
"expiresAt": "2025-01-22T20:00:00Z"
}'List Overrides
GET
/overridesList all active overrides for your organization.
List Group Overrides
GET
/resource-groups/{groupID}/overridesList overrides for a specific resource group.
Get Override
GET
/overrides/{overrideID}Get details of a specific override.
Delete Override
DELETE
/overrides/{overrideID}Cancel an override. The resource will resume following its schedule.
Examplebash
curl -X DELETE https://zopnight.com/api/overrides/ovr_abc123 \
-H "Authorization: Bearer <token>"Override Object
| Field | Type | Description |
|---|---|---|
id | string | Unique override ID |
resourceUID | string | Cloud resource UID (for resource overrides) |
groupID | string? | Resource group ID (for group overrides) |
action | string | force_on or force_off |
reason | string | Human-readable reason for the override |
createdBy | string | Email of the creator |
expiresAt | string | ISO 8601 expiry timestamp |
createdAt | string | ISO 8601 creation timestamp |