Skip to content
Docs

Management — Employee Management

Navigate to: Dashboard → Employee Management

What it shows: All employees (API consumers) in your organization. Each employee has a unique API key, belongs to a team, and has individual budget limits.

Step-by-step: Add an employee

  1. Click Employee Management in the sidebar.
  2. Click Add Employee.
  3. Enter Name and Email.
  4. Select a Team (optional — defaults to organization default team).
  5. Set Monthly Budget and Daily Budget in USD.
  6. Click Save — AgentWatch generates a unique API key automatically.
  7. Copy the API key and share it with the employee. It is only shown once in full.

Step-by-step: Import employees via CSV

  1. Click Import CSV.
  2. Download the template CSV (columns: name, email, team, monthly_budget, daily_budget).
  3. Fill the template and upload it.
  4. Review the preview table — rows with errors are highlighted.
  5. Click Confirm Import.

Step-by-step: Suspend an employee

  1. Find the employee in the list and click their row.
  2. Toggle Suspended on.
  3. Click Save — the employee’s API key is immediately rejected at the gateway.

Step-by-step: Rotate an API key

  1. Open the employee record.
  2. Click Regenerate Key.
  3. Confirm — the old key is invalidated immediately.
  4. Copy and distribute the new key.

Budget columns:

Column Meaning
Daily Budget Max spend per calendar day (UTC). Resets at midnight.
Monthly Budget Max spend per calendar month. Resets on the 1st.
Last Active Timestamp of the most recent API request
Status Active / Suspended / Over Budget

How to test:

  1. Add an employee with a $0.01 daily budget.
  2. Use the generated API key to call POST /v1/chat/completions.
  3. After the budget is exceeded, subsequent calls should return {"error": "budget_exceeded"}.
  4. Increase the daily budget and retry — calls should succeed immediately.

API endpoints:

Method Path Purpose
GET /admin/tenants/enhanced List all employees
POST /admin/tenants/enhanced Create employee
PUT /admin/tenants/:id Update info, budget, suspension
DELETE /admin/tenants/:id Remove employee
POST /admin/tenants/:id/renew-key Rotate API key
POST /admin/tenants/import-csv Bulk import