Users, API keys, providers and mappings
Weik.io 2026.2Give people and pipelines access to your Weik.io installation with the weikio CLI. Video
Watch: Projects, environments and access, 3:59
The video creates a project and an environment and grants a person access to them.
This part of the video couldn't be loaded.
On this page
- Commands on this page
- weikio get users
- weikio user create
- weikio user reset-password
- weikio user reset-totp
- weikio describe user
- weikio user set
- weikio user disable
- weikio user enable
- weikio delete user
- weikio apikey create
- weikio get apikeys
- weikio describe apikey
- weikio apikey revoke
- weikio get providers
- weikio provider set
- weikio describe provider
- weikio delete provider
- weikio get mappings
- weikio mapping add
- weikio delete mapping
- Exit codes
- See also
People sign in to the admin UI with a password or through an identity provider, which can be Microsoft Entra ID or any OpenID Connect provider. The CLI and pipelines use API keys. An Only these key can use only the grants you give it when you create it. You write each grant as project/role@environments. You can give only what the key’s owner has. An All my access key can do everything its owner can. When the owner gets a new project or role later, the key gets it too.
A claim mapping turns a provider’s group or role claims into grants at every sign-in. weikio apply doesn’t accept providers and mappings as documents, so you manage them with the commands on this page.
Commands on this page#
| Command | What it does |
|---|---|
weikio get users |
List users. |
weikio user create |
Create a user and print their set-password link once, when the installation has a public base URL. |
weikio user reset- |
Issue a one-time set-password link. |
weikio user reset-totp |
Reset a user’s authenticator app. If the user is a platform admin or a break-glass account, they set up a new one at their next sign-in. |
weikio describe user |
Show one user with their memberships and API keys. The output ends with the claims of their last sign-in. |
weikio user set |
Change a user’s settings, such as their display name. |
weikio user disable |
Disable a user and their API keys. |
weikio user enable |
Enable a disabled or locked user. |
weikio delete user |
Delete a user with their memberships and API keys. |
weikio apikey create |
Create an API key and print it once. |
weikio get apikeys |
List API keys. |
weikio describe apikey |
Show an API key with its grants. |
weikio apikey revoke |
Revoke an API key. |
weikio get providers |
List the identity providers. |
weikio provider set |
Create an identity provider, or change an existing one. |
weikio describe provider |
Show an identity provider. |
weikio delete provider |
Delete an identity provider and its claim mappings. |
weikio get mappings |
List claim mappings with their IDs. |
weikio mapping add |
Create a claim mapping. Without -- and --apis, a grant covers all of the project’s integrations and APIs. |
weikio delete mapping |
Delete a claim mapping by its ID. |
The tables below leave out the flags every command accepts, such as --env and --project, which the CLI reference lists.
weikio get users#
List users.
The PLATFORM ADMIN column shows yes for a platform administrator set on their account and mapped for one made by a claim mapping. It shows no for everyone else. A claim mapping can also make a person a platform administrator. They keep the platform administrator setting for 30 days after their last sign-in through the provider, unless you change the number of days with weikio provider set --roles-count-for.
weikio get users [--disabled] [--platform-admin] [--break-glass]| Argument or flag | What it does |
|---|---|
-- |
Shows only disabled users. |
-- |
Shows only the users set as platform administrators on their account. |
-- |
Shows only break-glass accounts. |
Who can run it: a platform administrator.
API: GET /api/v1/users.
weikio user create#
Create a user and print their set-password link once, when the installation has a public base URL. The link expires in 72 hours. Users who sign in through an identity provider are created at their first sign-in and need no command.
weikio user create <email> --display-name S [--platform-admin]| Argument or flag | What it does |
|---|---|
<email> |
Sets the user’s e-mail address. |
-- |
Sets the user’s display name, up to 200 characters. |
-- |
Makes the user a platform admin. |
-- |
Stores a reason for the change with the audit record. |
Who can run it: a platform administrator.
API: POST /api/v1/users, POST /api/v1/users/{id}/password-reset.
weikio create user does the same.
$ weikio user create ci@example.com --display-name "Finance CI"Target: https://hub.example
user ci@example.com created (id 01j8..., local account, password reset required)
Link valid until 2026-09-19 10:12 UTC
Set-password link (shown once): https://hub.example/login/set-password#token=****************$ weikio member add finance ci@example.com --role deployer --env devtestTarget: https://hub.example, project finance (argument), user ci@example.com
member finance/ci@example.com created (role deployer, environments devtest, revision 4110)weikio user reset-password#
Issue a one-time set-password link.
weikio user reset-password <id|email>| Argument or flag | What it does |
|---|---|
<user> |
Identifies the user, by ID or e-mail. |
-- |
Stores a reason for the change with the audit record. |
Who can run it: a platform administrator.
API: POST /api/v1/users/{id}/password-reset.
weikio user reset-totp#
Reset a user’s authenticator app. If the user is a platform admin or a break-glass account, they set up a new one at their next sign-in.
weikio user reset-totp <id|email>| Argument or flag | What it does |
|---|---|
<user> |
Identifies the user, by ID or e-mail. |
-- |
Stores a reason for the change with the audit record. |
Who can run it: a platform administrator.
API: DELETE /api/v1/users/{id}/totp.
weikio describe user#
Show one user with their memberships and API keys.
When a claim mapping makes a user a platform administrator, describe user prints Platform admin: no above Mapped platform admin: yes.
The output ends with the SIGN-IN CLAIMS table from the user’s last sign-in through an identity provider. Each row shows a value the provider sent and the ID of the mapping it matched. The MAPPED column of the memberships shows the grants those mappings gave. Claim mappings explains how a provider’s claims become grants.
weikio describe user <id|email>| Argument or flag | What it does |
|---|---|
<user> |
Identifies the user, by ID or e-mail. |
Who can run it: any API key for your own user, and a platform administrator for other users.
API:
GET /api/v1/users/{id}GET /api/v1/users/_emails?email=GET /api/v1/projectsGET /api/v1/projects/{project}/membersGET /api/v1/api-keys?user=GET /api/v1/users/{id}/claims
$ weikio describe user admin@localUser: admin@local
ID: 01m7mzdgt7fabgdtby4xr2p07a
Kind: local
Platform admin: yes
Disabled: no
Last login: never
MEMBERSHIPS
platform admin
PROJECT ROLE MAPPED ENVIRONMENTS INTEGRATIONS APIS
finance viewer - devtest all all
API KEYS
NAME ID EXPIRES LAST USED
init 01m7mzdgte2nkywz5yd5cjcmd4 never 2026-11-18 16:38 UTC
SIGN-IN CLAIMS
noneweikio user set#
Change a user’s settings, such as their display name.
weikio user set <id|email> [--display-name S] [--platform-admin=bool] [--break-glass=bool]| Argument or flag | What it does |
|---|---|
<user> |
Identifies the user, by ID or e-mail. |
-- |
Sets the user’s display name, up to 200 characters. |
-- |
Sets whether the user is a platform admin. |
-- |
Sets whether this is a break-glass account. |
-- |
Stores a reason for the change with the audit record. |
Who can run it: a platform administrator.
API: PUT /api/v1/users/{id}.
weikio user disable#
Disable a user and their API keys. Their keys stop working from the next request.
weikio user disable <id|email>| Argument or flag | What it does |
|---|---|
<user> |
Identifies the user, by ID or e-mail. |
-- |
Stores a reason for the change with the audit record. |
Who can run it: a platform administrator.
API: PATCH /api/v1/users/{id}.
weikio user enable#
Enable a disabled or locked user.
weikio user enable <user> [flags]| Argument or flag | What it does |
|---|---|
<user> |
Identifies the user, by ID or e-mail. |
-- |
Stores a reason for the change with the audit record. |
Who can run it: a platform administrator.
API: PATCH /api/v1/users/{id}.
weikio delete user#
Delete a user with their memberships and API keys.
weikio delete user <id|email> [-y]| Argument or flag | What it does |
|---|---|
<user> |
Identifies the user, by ID or e-mail. |
-y, --yes |
Skips the confirmation. |
-- |
Stores a reason for the change with the audit record. |
Who can run it: a platform administrator.
API: DELETE /api/v1/users/{id}.
weikio apikey create#
Create an API key and print it once, as the last line, in the form wk_<keyId>_<secret>. Give it to a pipeline as WEIKIO_API_KEY.
weikio apikey create --name S [--user <id|email>] [--expires 365d|never] [--grant P/R[@E,...]] ... [--integrations a,b] [--apis x,y] [--platform-admin] [--all-access]| Argument or flag | What it does |
|---|---|
--name <name> |
Sets the key’s name, up to 200 characters. |
--user <user> |
Sets the user who owns the key, by ID or e-mail. The default is you. |
-- |
Sets when the key stops working, as a duration such as 90d or as a date. The default is 90d, or 30d with --. Give never for a key that never expires. |
-- |
Adds one grant each time you give it, written as project/. |
-- |
Limits the grant to these integrations, comma separated. |
--apis <apis> |
Limits the grant to these APIs, comma separated. |
-- |
Makes the key a platform admin. |
-- |
Makes an All my access key, which can do everything its owner can. You can’t combine it with -- and its limits or with --. |
-- |
Stores a reason for the change with the audit record. |
Who can run it: any API key for a key of your own, and a platform administrator for --user and --platform-admin.
API: POST /api/v1/api-keys.
weikio create apikey does the same.
$ weikio apikey create --name laptop-anna --expires 90d --grant finance/deployer@devtestTarget: https://hub.example, user anna@example.com (caller)
api-key laptop-anna created (id 01k7xq3m8d9h2vqz4n6p5r7t2w, expires 2026-12-15, grants finance/deployer@devtest)
API key (shown once): wk_01k7xq3m8d9h2vqz4n6p5r7t2w_****************************$ weikio apikey create --name finance-ci-devtest --user ci@example.com --expires 365d --grant finance/deployer@devtestTarget: https://hub.example, user ci@example.com (--user)
api-key finance-ci-devtest created (id 01k7xq4b2c5f8g1j3k6m9n0p4s, expires 2027-09-16, grants finance/deployer@devtest)
API key (shown once): wk_01k7xq4b2c5f8g1j3k6m9n0p4s_****************************$ weikio apikey create --name finance-ci-prod --user ci@example.com --grant finance/deployer@devtest,productionTarget: https://hub.example, user ci@example.com (--user)
error: The grant goes beyond what 'ci@example.com' was given directly: 'ci@example.com' has the role 'deployer' in project 'finance' only in environment 'devtest'. Ask for less, or have a project administrator grant it with:
weikio member add finance ci@example.com --role deployer --env devtest,production$ weikio apikey create --name laptop-docs --all-accessTarget: https://hub.example, user admin@local (caller)
api-key laptop-docs created (id 01m7qrbn0rtjt36b07e8d01eh4, expires 2027-02-16, grants all the owner's access)
API key (shown once): wk_...$ weikio apikey create --name laptop-docs-2 --all-access --grant sandbox/viewer@devtesterror: --all-access and --grant can't be used together. One kind of key holds all its owner's access, and the other holds only what you give it.weikio get apikeys#
List API keys.
weikio get apikeys [--user <id|email>] [--expired]| Argument or flag | What it does |
|---|---|
--user <user> |
Shows only this user’s keys, by ID or e-mail. |
-- |
Shows only expired keys. |
Who can run it: any API key for your own keys, and a platform administrator for other people’s keys.
API: GET /api/v1/api-keys?user=.
$ weikio get apikeys --user ci@example.comNAME ID OWNER EXPIRES LAST USED GRANTS
finance-ci-devtest 01k7xq4b2c5f8g1j3k6m9n0p4s ci@example.com 2027-09-16 never finance/deployer@devtestweikio describe apikey#
Show an API key with its grants.
weikio describe apikey <keyId>| Argument or flag | What it does |
|---|---|
<key- |
Identifies the API key by its ID. |
Who can run it: any API key for your own keys, and a platform administrator for other people’s keys.
API: GET /api/v1/api-keys/{keyId}.
weikio apikey revoke#
Revoke an API key.
weikio apikey revoke <keyId> [-y]| Argument or flag | What it does |
|---|---|
<key- |
Identifies the API key by its ID. |
-y, --yes |
Skips the confirmation. |
-- |
Stores a reason for the change with the audit record. |
Who can run it: any API key for your own keys, and a platform administrator for other people’s keys.
API: DELETE /api/v1/api-keys/{keyId}.
weikio delete apikey does the same.
weikio get providers#
List the identity providers.
weikio get providersWho can run it: a platform administrator.
API: GET /api/v1/providers.
weikio provider set#
Create an identity provider, or change an existing one. A change keeps every value you don’t give. Keep the client secret in a project secret and refer to it with --client-secret-ref.
weikio provider set <name> --kind entra --tenant TENANT|--kind oidc --authority URL --client-id ID --client-secret-ref P.NAME [--scope S ...] [--claim-path C] [--allowed-tenant T ...] [--display-name TEXT] [--roles-count-for D]| Argument or flag | What it does |
|---|---|
<name> |
Sets the provider’s name, which is the last part of its redirect URI. |
--kind <kind> |
Sets the kind of provider, entra or oidc. |
-- |
Sets the tenant ID for kind entra. Give organizations or common together with --. |
-- |
Sets the provider’s issuer URL for kind oidc. |
-- |
Sets the client ID registered at the provider. |
-- |
Refers to the project secret that has the client secret, as project.name. |
-- |
Adds one scope to request each time you give it. |
-- |
Sets the claim that this provider’s mappings use, such as groups or roles. |
-- |
Allows a tenant ID when -- is organizations or common. Repeat it for each tenant. |
-- |
Sets the name on the sign-in button. The default is the provider’s name. |
-- |
Sets how long a person’s API keys keep the provider’s roles after their last sign-in through it. The default is 30d. With 0, their keys never get them. |
-- |
Stores a reason for the change with the audit record. |
Who can run it: a platform administrator.
API:
GET /api/v1/providers/{name}PUT /api/v1/providers/{name}GET /api/v1/settings/install
weikio describe provider#
Show an identity provider and how long a person’s API keys keep its roles.
weikio describe provider <name>| Argument or flag | What it does |
|---|---|
<name> |
Identifies the identity provider. |
Who can run it: a platform administrator.
API:
GET /api/v1/providers/{name}GET /api/v1/settings/installGET /api/v1/projects/{project}/secrets
weikio delete provider#
Delete an identity provider and its claim mappings.
weikio delete provider <name> [-y]| Argument or flag | What it does |
|---|---|
<name> |
Identifies the identity provider. |
-y, --yes |
Skips the confirmation. |
-- |
Stores a reason for the change with the audit record. |
Who can run it: a platform administrator.
API: DELETE /api/v1/providers/{name}.
weikio get mappings#
List claim mappings with their IDs.
weikio get mappings [--provider NAME]| Argument or flag | What it does |
|---|---|
-- |
Shows only the mappings of this provider. |
Who can run it: a platform administrator.
API: GET /api/v1/mappings?provider=.
weikio mapping add#
Create a claim mapping. Without --integrations and --apis, a grant covers all of the project’s integrations and APIs.
weikio mapping add <provider> <claim> <value> [--grant P/R[@E,...]] ... [--integrations N,...] [--apis A,...] [--platform-admin]| Argument or flag | What it does |
|---|---|
<provider> |
Identifies the identity provider. |
<claim> |
Sets the claim, such as groups. |
<value> |
Sets the claim value to match. |
-- |
Adds one grant each time you give it, written as project/. |
-- |
Limits the grant to these integrations, comma separated. Use it with one --. |
--apis <apis> |
Limits the grant to these APIs, comma separated. Use it with one --. |
-- |
Makes matching users platform admins. |
-- |
Stores a reason for the change with the audit record. |
Who can run it: a platform administrator.
API: POST /api/v1/mappings.
weikio delete mapping#
Delete a claim mapping by its ID.
weikio delete mapping <id> [-y]| Argument or flag | What it does |
|---|---|
<id> |
Identifies the mapping by its ID, which weikio get mappings lists. |
-y, --yes |
Skips the confirmation. |
-- |
Stores a reason for the change with the audit record. |
Who can run it: a platform administrator.
API: GET /api/v1/mappings/{uid}, DELETE /api/v1/mappings/{uid}.
Exit codes#
The codes match the exit code table in the CLI reference.
| Code | Meaning |
|---|---|
| 0 | The command succeeded. |
| 1 | The command stopped without making the change. |
| 2 | The command has a usage error. |
| 3 | Your key is missing, expired or revoked, or its access doesn’t cover the command. |
| 4 | What you named doesn’t exist. |
| 5 | The change conflicts with another change. |
| 6 | Weik.io couldn’t be reached or wasn’t ready, or it was rate limiting your calls or out of storage. Run the command again later. |
| 8 | A document isn’t valid. |