Aller au contenu

Update point of interest

Commencez par le bloc configuration du script, puis ajoutez le code de l’extrait ci-dessous.

# ... script setup ...
TWIN_ID = "your-twin-id"
POI_ID = "your-poi-id"
updated = api_patch(
f"/v1/twin/{TWIN_ID}/pois/{POI_ID}",
{"name": "Inspection point (updated)", "color": {"r": 1.0, "g": 1.0, "b": 0.0, "a": 1.0}},
)
print(json.dumps(updated, indent=2))