Lo que se aplica a este agente
GET/api/public/v1/agents/{agent_id}/zone
The assigned zone, how it was assigned, the layer stack top-down, and every effective policy with the layer that authored it and whether that layer is the agent's own (authored_here / inherited). Resolved by app/zones/resolution.py — the one implementation every zone surface shares.
curl --fail-with-body -X GET 'https://app.openlatch.ai/api/public/v1/agents/<agent_id>/zone' \ -H "Authorization: Bearer $OPENLATCH_API_KEY"import jsonimport osimport urllib.request
request = urllib.request.Request( 'https://app.openlatch.ai/api/public/v1/agents/<agent_id>/zone', method='GET', headers={ 'Authorization': 'Bearer ' + os.environ['OPENLATCH_API_KEY'], },)with urllib.request.urlopen(request) as response: text = response.read().decode() print(json.dumps(json.loads(text), indent=2) if text else response.status)#!/usr/bin/env bashset -euo pipefail
curl -sS --fail-with-body -X GET 'https://app.openlatch.ai/api/public/v1/agents/<agent_id>/zone' \ -H "Authorization: Bearer $OPENLATCH_API_KEY" | jq .$headers = @{ Authorization = "Bearer $env:OPENLATCH_API_KEY"}Invoke-RestMethod -Method GET -Uri 'https://app.openlatch.ai/api/public/v1/agents/<agent_id>/zone' -Headers $headers | ConvertTo-Json -Depth 20Autorización
Sección titulada «Autorización»| Rol en la organización | Este punto de conexión |
|---|---|
owner | Permitido |
admin | Permitido |
editor | Permitido |
viewer | Permitido |
Una clave tiene el rol que su propietario ocupa en la organización. Consulte Autenticación.
Ámbito de la clave de API: zones:read
Parámetros de ruta
Sección titulada «Parámetros de ruta»| Parámetro | Tipo | Descripción |
|---|---|---|
agent_id | string | Obligatorio. |
Respuesta
Sección titulada «Respuesta»- 200 OK — la llamada se completó correctamente.
- 401 Unauthorized —
UNAUTHORIZED - 402 Payment Required —
license_expired - 403 Forbidden —
FEATURE_DISABLED,FORBIDDEN,INSUFFICIENT_SCOPE - 404 Not Found —
NOT_FOUND - 422 Unprocessable Content —
INVALID_ID,VALIDATION_ERROR - 429 Too Many Requests —
TOO_MANY_REQUESTS - 500 Internal Server Error —
INTERNAL_SERVER_ERROR,tenant_isolation_violation - 503 Service Unavailable —
ENGINE_UNAVAILABLE,FEATURE_STATE_UNAVAILABLE,SERVICE_UNAVAILABLE
Campos de la respuesta
Sección titulada «Campos de la respuesta»| Campo | Tipo | Descripción |
|---|---|---|
assigned_zone | string or null | Obligatorio. |
assignment_source | string | Obligatorio. |
capabilities | object or null | |
capabilities.ask | boolean | Obligatorio. Can show its own prompt to the developer. |
capabilities.enforces | string | Obligatorio. all, or shell_only: which tools its refusals actually reach. |
capabilities.notice | boolean | Obligatorio. Can show a non-blocking message. |
capabilities.observes_execution | boolean | Obligatorio. Emits a post-execution event, so an answer can be inferred. |
client | object | Obligatorio. What the install last told us about itself. |
client.bundle_revision | string or null | |
client.omitted_kinds | array of string | Obligatorio. |
client.version | string or null | |
compatibility | object | Obligatorio. Per-family compatibility posture for one install, keyed by contract family. |
compatibility.families | object | Obligatorio. |
control_level | string | Obligatorio. |
effective | array of object | Obligatorio. |
effective[].dimensions | array of string | Obligatorio. |
effective[].display_title | string | The AIP's name: its title, else its generated_title, else its statement. |
effective[].enforced_on_this_install | boolean | Obligatorio. |
effective[].mode | string | Obligatorio. |
effective[].optimize | array of object | |
effective[].optimize_preview | array of object | |
effective[].origin_layer_id | string | Obligatorio. |
effective[].origin_layer_label | string | Obligatorio. |
effective[].policy_id | string | Obligatorio. |
effective[].public_id | string | Obligatorio. |
effective[].standing | string | Obligatorio. |
effective[].statement | string | Obligatorio. |
kpis | object | Obligatorio. |
kpis.anomalies_14d | integer | |
kpis.authored_here | integer | Obligatorio. |
kpis.enforcing_n | integer | Obligatorio. |
kpis.enforcing_of | integer | Obligatorio. |
kpis.inherited | integer | Obligatorio. |
kpis.policies_in_force | integer | Obligatorio. |
layers | array of object | Obligatorio. |
layers[].depth | integer | Obligatorio. |
layers[].label | string | Obligatorio. |
layers[].unit_id | string | Obligatorio. |
stale | boolean | Obligatorio. |
Ejemplo de respuesta
Sección titulada «Ejemplo de respuesta»{ "assigned_zone": "string", "assignment_source": "string", "capabilities": { "ask": false, "enforces": "string", "notice": false, "observes_execution": false }, "client": { "bundle_revision": "string", "omitted_kinds": [ "string" ], "version": "string" }, "compatibility": { "families": {} }, "control_level": "string", "effective": [ { "dimensions": [ "string" ], "display_title": "", "enforced_on_this_install": false, "mode": "string", "optimize": [ { "atom_id": "3f6c1a2e-8b4d-4c1f-9a7e-0d5b2c8e4f10", "directive": { "lever": "effort_clamp", "params": {} } } ], "optimize_preview": [ {} ], "origin_layer_id": "3f6c1a2e-8b4d-4c1f-9a7e-0d5b2c8e4f10", "origin_layer_label": "string", "policy_id": "3f6c1a2e-8b4d-4c1f-9a7e-0d5b2c8e4f10", "public_id": "3f6c1a2e-8b4d-4c1f-9a7e-0d5b2c8e4f10", "standing": "string", "statement": "string" } ], "kpis": { "anomalies_14d": 0, "authored_here": 3, "enforcing_n": 3, "enforcing_of": 3, "inherited": 3, "policies_in_force": 3 }, "layers": [ { "depth": 3, "label": "string", "unit_id": "3f6c1a2e-8b4d-4c1f-9a7e-0d5b2c8e4f10" } ], "stale": false}