---
title: "Remove User From Tenant"
method: DELETE
path: "/api/v1/tenants/users"
tags: ["tenants"]
---

# Remove User From Tenant

`DELETE /api/v1/tenants/users`

## Request

- Base URL: `https://api.aws.cognee.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://api.aws.cognee.ai/api/v1/tenants/users`
- Auth: API key in header `X-Api-Key`

Remove a user from a tenant.

The owner or an admin can remove members; only the owner can remove an admin.
Nobody can remove the owner.

## Request Parameters
- **tenant_id** (UUID): The UUID of the tenant
- **user_id** (UUID): The UUID of the user to remove

The removed member is emailed, for the same reason the added one is
(COG-6177): losing access silently is as confusing as gaining it silently.

The member's access is revoked on the tenant pod BEFORE the membership is
dropped here, so a removal is never recorded while their keys still work.

## Error Codes
- **403 Forbidden**: Caller is neither the owner nor an admin, is an admin removing
  an admin, or is trying to remove the owner
- **404 Not Found**: User-tenant association doesn't exist
- **503 Service Unavailable**: The workspace could not be reached to revoke access
  (or, for an admin, to confirm they are one); nothing was removed — retry once it
  is running (a suspended workspace must be restored first)
- **500 Internal Server Error**: Error removing user from tenant

## Query parameters

- `tenant_id` string, uuid, required
- `user_id` string, uuid, required

## Response `200`

Successful Response

- unknown

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/cognee/apis/cognee-api.md) - [All operations](https://skmtc.dev/cognee/apis/cognee-api/llms.txt) - [OpenAPI document](https://skmtc.dev/cognee/apis/cognee-api/revisions/a7b6c6cb8212?raw)
