Aller au contenu

Who would arrive if this unit's Autonomy Zone were enabled

GET/api/public/v1/org-units/{unit_id}/zone/preview

Agents with no manual assignment whose placement sits at or under the unit and whose current zone is above it — the agents for which the new zone would become the deepest — each with the placement link that brings it (owner · accountable_person · accountable_unit) and whether that link was set by hand. auto_arrivals is the total; agents lists the first 500 by display name. 409 ZONE_EXISTS when the unit already carries a zone.

Fenêtre de terminal
curl --fail-with-body -X GET 'https://app.openlatch.ai/api/public/v1/org-units/<unit_id>/zone/preview' \
-H "Authorization: Bearer $OPENLATCH_API_KEY"
Rôle dans l’organisationCe point de terminaison
ownerAutorisé
adminAutorisé
editorNon autorisé
viewerNon autorisé

Une clé porte le rôle que son propriétaire détient dans l’organisation. Voir Authentification.

Portée de clé d’API : zones:read

ParamètreTypeDescription
unit_idstring (uuid)Obligatoire.
ChampTypeDescription
agentsarray of objectObligatoire.
agents[].agent_idstringObligatoire.
agents[].current_zoneobjectObligatoire.
agents[].current_zone.idstringObligatoire.
agents[].current_zone.labelstringObligatoire.
agents[].reasonobjectObligatoire.
agents[].reason.kindstring — one of owner, accountable_person, accountable_unitObligatoire.
agents[].reason.personobject or null
agents[].reason.sourcestring — one of directory, manualObligatoire.
agents[].reason.unitstringObligatoire.
auto_arrivalsintegerObligatoire.
{
"agents": [
{
"agent_id": "agt_01jbwa2k1vfrn9y42xhgxhmzj2",
"current_zone": {
"id": "3f6c1a2e-8b4d-4c1f-9a7e-0d5b2c8e4f10",
"label": "string"
},
"reason": {
"kind": "owner",
"person": "string",
"source": "directory",
"unit": "string"
}
}
],
"auto_arrivals": 3
}