Loading page...Загружаем страницу...正在加载页面...
AtlasRepo

My AI Agents Share a Server. Here’s How I Keep Them Out of Each Other’s Way

Description and use

Multiple AI agents on a single server conflicted due to shared credentials. By creating a separate tenant and unique API key per agent, isolation is achieved, keys can be rotated without downtime, and individual agents can be disabled without affecting others.

Problem

Multiple AI agents sharing a single server caused deployment conflicts and lack of isolation, making it hard to stop or manage individual agents without affecting others.

Outcome

Agents operate in isolated tenant spaces, preventing cross‑agent interference. Key rotation is seamless, and misbehaving agents can be stopped instantly without affecting others.

Workflow

  • Create a tenant per agent using the bootstrap token via POST /v1/tenants/register
  • Store the returned tenant_id and first API key for admin use
  • Create a second, agent‑specific API key with an optional expiry via POST /v1/auth/keys
  • Configure the agent to use its dedicated key
  • Rotate keys by creating a new key, letting the agent use it, then revoking the old key via DELETE /v1/auth/keys/{id}
  • To stop an agent, revoke its key or suspend the tenant via DELETE /v1/tenant and reactivate with the admin token if needed

Evidence

Creating a tenant is one request with the bootstrap token in a header: curl -s -X POST "$AH_URL/v1/tenants/register" -H "X-Bootstrap-Token: $AH_BOOTSTRAP_TOKEN" -H "Content-Type: application/json" -d '{"name":"blog-agent", "email":"[email protected]"}' # {"tenant_id":"3f9a...","api_key":"8c41....d07e..."}

Source

  • Record date: 2026-10-23T15:11:32.561Z