> ## Documentation Index
> Fetch the complete documentation index at: https://docs.occtoo.com/llms.txt
> Use this file to discover all available pages before exploring further.

# removeUserFromTenant

> Removes a user from the current tenant. If it was their only tenant, their Occtoo account is deleted too. Succeeds when the user isn't in the tenant.



**mutation** `removeUserFromTenant(input: RemoveUserFromTenantInput!): RemoveUserFromTenantPayload!`

## Arguments

**`input`**: `RemoveUserFromTenantInput!` (required)

## Returns

`RemoveUserFromTenantPayload!`

**`empty`**: `Empty`

---

**`errors`**: `[RemoveUserFromTenantError!]`

## Examples

```graphql Mutation
mutation RemoveUserFromTenant($input: RemoveUserFromTenantInput!) {
  removeUserFromTenant(input: $input) {
    empty {
      value
    }
    errors {
      __typename
      ... on GraphQlError {
        code
        details {
          __typename
        }
        message
      }
    }
  }
}
```

```json Variables
{
  "input": {
    "id": "id"
  }
}
```

```json Response
{
  "data": {
    "removeUserFromTenant": {
      "empty": {
        "value": 1
      },
      "errors": [
        {
          "__typename": "GraphQlError",
          "code": "string",
          "details": [
            {
              "__typename": "KeyValuePairOfStringAndString"
            }
          ],
          "message": "string"
        }
      ]
    }
  }
}
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.