Skip to content

Update zone

Start from the script setup block, then add the snippet code below.

# ... script setup ...
TWIN_ID = "your-twin-id"
ZONE_ID = "your-zone-id"
updated = api_patch(
f"/v1/twin/{TWIN_ID}/zones/{ZONE_ID}",
{"name": "Safety zone (updated)"},
)
print(json.dumps(updated, indent=2))