## Get User Claims

`admin.users.get_claims(struser_id)  -> UserClaims`

**get** `/api/v1/admin/users/{user_id}/claims`

Get a user's resolved custom claims.

Claims that have not been explicitly set fall back to their system default. Returns 404 if the user does not exist.

Global admin only.

### Parameters

- `user_id: str`

### Returns

- `class UserClaims: …`

  A user's fully resolved custom claims after applying system defaults.

  - `claims: CustomClaims`

    The user's resolved custom claims.

    - `allow_org_deletion: Optional[bool]`

      Whether the user is allowed to delete organizations.

    - `allowed_org_creation: Optional[bool]`

      Whether the user is allowed to create organizations.

    - `api_datasource_access: Optional[bool]`

      Whether the user is allowed to access API data sources.

    - `maximum_org_creation: Optional[int]`

      Cap on how many organizations this user may create. None means unlimited. Only enforced when allowed_org_creation is True.

  - `user_id: str`

    The user ID the claims belong to.

### Example

```python
import os
from llama_cloud_admin import LlamaCloudAdmin

client = LlamaCloudAdmin(
    api_key=os.environ.get("LLAMA_CLOUD_API_KEY"),  # This is the default and can be omitted
)
user_claims = client.admin.users.get_claims(
    "user_id",
)
print(user_claims.user_id)
```

#### Response

```json
{
  "claims": {
    "allow_org_deletion": true,
    "allowed_org_creation": true,
    "api_datasource_access": true,
    "maximum_org_creation": 0
  },
  "user_id": "user_id"
}
```
