Ir al contenido

Reemplazar, vincular o restablecer la propiedad de un agente

PATCH/api/public/v1/agents/{agent_id}/ownership

Exactly ONE directive per body: owner_person_id · owner_provider_id + owner_external_id · owner_local_email (+ optional owner_local_display_name / owner_local_title / owner_local_org_path — sent applies, omitted leaves alone, sent blank clears) · owner_kind: "service" + service_label + one accountable ref · function · external_agent_id + external_agent_provider · reset: "owner" | "function". Writes unconditionally (a human outranks any in-flight resolution), audits agent.owner.overridden / agent.owner.reset, and for the link and both resets enqueues an immediate background re-resolution — the response is the cleared / linked state, never the re-resolved one. 400 zero or several directives or an off-enum function · 404 unknown agent / person / provider · 422 a directive missing a co-key, or a typed address that matches people in more than one directory (OWNER_EMAIL_AMBIGUOUS).

Ventana de terminal
curl --fail-with-body -X PATCH 'https://app.openlatch.ai/api/public/v1/agents/<agent_id>/ownership' \
-H "Authorization: Bearer $OPENLATCH_API_KEY" \
-H 'Content-Type: application/json' \
-d '{"owner_local_display_name":"Dana Whitfield","owner_local_email":"dana.whitfield@example.com"}'
Rol en la organizaciónEste punto de conexión
ownerPermitido
adminPermitido
editorPermitido
viewerNo permitido

Una clave tiene el rol que su propietario ocupa en la organización. Consulte Autenticación.

Ámbito de la clave de API: agents:write

ParámetroTipoDescripción
agent_idstringObligatorio.
ParámetroTipoDescripción
Idempotency-Keystring or nullOptional. Makes the request safe to retry: the same key and the same request, within 24 hours, returns the stored response with Idempotent-Replayed: true and runs once.
CampoTipoDescripción
external_agent_idstring or null
external_agent_providerstring or null
functionstring or null
owner_external_idstring or null
owner_kindstring or null
owner_local_display_namestring or null
owner_local_emailstring (email) or null
owner_local_org_pathstring or null
owner_local_titlestring or null
owner_person_idstring or null
owner_provider_idstring or null
resetstring or null
service_accountable_org_unit_idstring or null
service_accountable_person_idstring or null
service_labelstring or null
CampoTipoDescripción
capture_capableboolean
functionstring or null
function_confidencenumber or null
function_sourcestring or null
ownerobject or null
owner.display_namestring or null
owner.emailstring or null
owner.org_unitobject or null
owner.person_idstringObligatorio.
owner.privilegeobject or null
owner.statusstringObligatorio.
owner.titlestring or null
owner_kindstring or null
owner_resolved_atstring (date-time) or null
owner_sourcestring or null
providerobject or null
provider.display_namestringObligatorio.
provider.idstringObligatorio.
provider.kindstringObligatorio.
provider.last_synced_atstring (date-time) or null
provider.staleboolean
serviceobject or null
service.accountable_org_unitobject or null
service.accountable_personobject or null
service.labelstring or null
signalsarray of object
signals[].kindstringObligatorio.
signals[].outcomestringObligatorio.
signals[].valuestring or null
unattributed_reasonstring or null
unattributed_sincestring (date-time) or null
{
"capture_capable": true,
"function": "string",
"function_confidence": 0.25,
"function_source": "string",
"owner": {
"display_name": "release-bot",
"email": "ada@example.com",
"org_unit": {
"id": "3f6c1a2e-8b4d-4c1f-9a7e-0d5b2c8e4f10",
"name": "release-bot",
"path": "Engineering / Platform"
},
"person_id": "3f6c1a2e-8b4d-4c1f-9a7e-0d5b2c8e4f10",
"privilege": {
"capabilities": {},
"evaluated_at": "2026-01-15T14:32:05Z",
"grant_count": 0,
"grant_counts": {},
"tier": "string"
},
"status": "string",
"title": "string"
},
"owner_kind": "string",
"owner_resolved_at": "2026-01-15T14:32:05Z",
"owner_source": "string",
"provider": {
"display_name": "release-bot",
"id": "3f6c1a2e-8b4d-4c1f-9a7e-0d5b2c8e4f10",
"kind": "string",
"last_synced_at": "2026-01-15T14:32:05Z",
"stale": false
},
"service": {
"accountable_org_unit": {
"id": "3f6c1a2e-8b4d-4c1f-9a7e-0d5b2c8e4f10",
"name": "release-bot",
"path": "Engineering / Platform"
},
"accountable_person": {
"display_name": "release-bot",
"email": "ada@example.com",
"org_unit": {},
"person_id": "3f6c1a2e-8b4d-4c1f-9a7e-0d5b2c8e4f10",
"privilege": {},
"status": "string",
"title": "string"
},
"label": "string"
},
"signals": [
{
"kind": "string",
"outcome": "string",
"value": "string"
}
],
"unattributed_reason": "Never push to main without a review.",
"unattributed_since": "2026-01-15T14:32:05Z"
}