ReferenceStructures
UserInfoResponse
The user identity object returned by GET /api/v1/auth/me.
UserInfoResponse is returned by GET /api/v1/auth/me. It describes the hzel account associated with the token that made the request and how that request was authenticated.
Fields
| Field | Type | Description |
|---|---|---|
user_id | string (UUID) | Unique user identifier, formatted as a UUID string. |
email | string | Email address associated with the account. |
role | string | Account role. One of "admin" or "user". |
auth_method | string | How this specific request was authenticated. One of "session", "oidc", "pat", "oauth". |
auth_method values
| Value | Meaning |
|---|---|
"session" | Authenticated via a browser session cookie (e.g. username/password login). |
"oidc" | Authenticated via an OIDC provider (e.g. Google, GitHub). |
"pat" | Authenticated via a Personal Access Token (hzel_…). |
"oauth" | Authenticated via an OAuth application access token issued by the OAuth flow. |
Example
{
"user_id": "d290f1ee-6c54-4b01-90e6-d701748f0851",
"email": "alice@example.com",
"role": "user",
"auth_method": "pat"
}UserPermissions
Returned by GET /api/v1/programs/permissions/me. Reports the effective container-creation permission for the current user across all programs they belong to.
| Field | Type | Description |
|---|---|---|
can_create_containers | boolean | true if the user is an admin, or is an accepted member of at least one program that grants container creation access. |
{
"can_create_containers": true
}