Skip to main content

Users Management

Adding a user

The wmill user add command is used to add a new user to the remote server.

wmill user add <email:string> [password:string] [--superadmin] [--company <company:string>] [--name <name:string>]

Arguments

ArgumentDescription
emailThe email address of the user to be added.
passwordThe password of the user to be added. Optional

Options

OptionParametersDescription
--superadminSpecify to make the new user superadmin.
--companycompanySpecify to set the company of the new user.
--namenameSpecify to set the company of the new user.

Examples

  1. Create a new user with the email "[email protected]" and automatically generate a password:
wmill user add [email protected]
  1. Create a new user with the email "[email protected]" and specify a password:
wmill user add [email protected] mypassword123
  1. Create a new superadmin user with the email "[email protected]", a specified password, and additional information:
wmill user add [email protected] mypassword123 --superadmin --company "Acme Inc." --name "John Doe"

Removing a user

The wmill user remove command is used to remove a user from the remote server.

wmill user remove <email:string>

Arguments

ArgumentDescription
emailThe email address of the user to be removed.

Examples

  1. Remove the user with the email "[email protected]"
wmill user remove [email protected]

Creating a token

The wmill user create-token command allows you to create an authentication token for a user. This token can be used for subsequent authenticated requests to the API server.

wmill user create-token [--email <email:string> --password <password:string>]

There are two ways to create a token:

  • Option 1: Specify email and password for authentication: Use the --email option to specify the email address of the user. Use the --password option to specify the password of the user. The command will exchange the provided credentials for a token with the API server and display the generated token.

  • Option 2: Already logged in: If you are already logged in, you can run the command without providing email and password. The command will use your existing authentication credentials to create a token and display it.

The command will display the generated token, which can be used for subsequent authenticated requests. Note that the token is not stored locally.