action exavault_add_user { label: "Create a user" description: "Adds a new user to the account. The user may be configured as an admin or standard user, and (if a standard user) may be assigned a restricted [home directory](/docs/account/04-users/00-introduction#setting-the-user-s-home-directory) and restricted [permissions](/docs/account/04-users/00-introduction#managing-user-roles-and-permissions). \n\n**Notes:**\n\n- You must be an [admin-level user](/docs/account/04-users/00-introduction#managing-user-roles-and-permissions) to use this." provider: exavault method: POST path: "/users" encoding: json input: { type: "object" properties: { email: { type: "string" format: "email" description: "Email address for the user" } "ev-access-token": { type: "string" } "ev-api-key": { type: "string" } expiration: { type: "string" description: "Optional timestamp when the user should expire, formatted in date-time." } homeResource: { type: "string" description: "Resource identifier for the user's home folder. See details on [how to specify resources](#section/Identifying-Resources) above.\n\nThe user will be locked to this directory and unable to move 'up' in the account. If the folder does not exist in the account, it will be created when the user is created. \n\nUsers with the `role` **admin** should have their homeResource set to '/'" } locked: { type: "boolean" description: "If true, the user will not be able to log in" } nickname: { type: "string" description: "An optional nickname (e.g. 'David from Sales')." } onboarding: { type: "boolean" description: "Set this to **true** to enable extra help popups in the web file manager for this user." } password: { type: "string" description: "Password for the user" } permissions: { type: "object" description: "An object containing name/value pairs for each permission. Any permission that is not passed will be set to `false` by default. Note that users will be unable to see any files in the account unless you include `list` permission.\nWhen creating a user with the `role` **admin**, you should set all of the permissions to `true`" properties: { changePassword: { type: "boolean" } delete: { type: "boolean" } deleteFormData: { type: "boolean" } download: { type: "boolean" } list: { type: "boolean" } modify: { type: "boolean" } notification: { type: "boolean" } share: { type: "boolean" } upload: { type: "boolean" } viewFormData: { type: "boolean" } } } role: { type: "string" description: "The type of user to create, either **user** or **admin**." enum: ["user", "admin"] } timeZone: { type: "string" description: "Time zone, used for accurate time display within the application. See this page for allowed values.\n" } username: { type: "string" description: "Username of the user to create. This should follow standard username conventions - spaces are not allowed, etc. We do allow email addresses as usernames.\n\n**Note** Usernames must be unique across all ExaVault accounts." } welcomeEmail: { type: "boolean" description: "If **true**, send this new user a welcome email upon creation. The content of the welcome email can be configured with the [PATCH /accounts](#operation/updateAccount) method." } } required: ["email", "ev-access-token", "ev-api-key", "homeResource", "password", "permissions", "role", "timeZone", "username"] additionalProperties: false } output: { type: "object" description: "Response object for users." properties: { data: { type: "object" description: "Object contains user properties." properties: { attributes: { type: "object" description: "Attributes of the user including expiration, home directory, and permissions. " required: ["accountName", "created", "homeResource", "modified", "nickname", "onboarding", "permissions", "role", "status", "timeZone", "username"] properties: { accessTimestamp: { type: "string" description: "Timestamp of most recent successful user login." } accountName: { type: "string" description: "Name of the account this user belongs to." } created: { type: "string" format: "date-time" description: "Timestamp of user creation." } email: { type: "string" description: "Email address of the user." } expiration: { type: "string" description: "Timestamp of user expiration." } firstLogin: { type: "boolean" description: "`true` if the user has logged into the system." } homePath: { type: "string" description: "Path to the user's home folder." } locked: { type: "boolean" description: "`true` if the user is locked and cannot log in." } modified: { type: "string" format: "date-time" description: "Timestamp of user modification." } nickname: { type: "string" description: "Nickname of the user." } onboarding: { type: "boolean" description: "Whether the onboarding help system is enabled for this user. `true` means that additional help popups are displayed in the web application for this user." } permissions: { type: "object" required: ["changePassword", "delete", "deleteFormData", "download", "list", "modify", "notification", "share", "upload", "viewFormData"] properties: { changePassword: { type: "boolean" description: "Change (own) password permission flag" } delete: { type: "boolean" description: "Delete permission flag" } deleteFormData: { type: "boolean" description: "Delete form data permission flag. If true, user can remove data that was submitted for a receive folder. This applies only to data submitted in the receive folder form, not the actual files uploaded." } download: { type: "boolean" description: "Download permission flag" } list: { type: "boolean" description: "View folder contents permission flag" } modify: { type: "boolean" description: "Modify permission flag" } notification: { type: "boolean" description: "Notifications permission flag" } share: { type: "boolean" description: "Sharing permission flag" } upload: { type: "boolean" description: "Upload permission flag" } viewFormData: { type: "boolean" description: "Access Form Data permission flag. If true, user can view submissions that have been stored for a receive folder. This includes any data submitted in the receive folder form." } } } role: { type: "string" description: "User's access level" enum: ["user", "admin", "master"] } status: { type: "integer" format: "int32" description: "Indicates user activity status. `0` means the user is locked and cannot log in. `1` means the user is active and can log in." enum: [0, 1] } timeZone: { type: "string" description: "User's timezone. See this page for allowed values." } username: { type: "string" description: "Username of the user." } } } id: { type: "integer" format: "int32" description: "ID of the user." } relationships: { type: "object" description: "Home resource and owner account relationship data for the user. " required: ["ownerAccount"] properties: { homeResource: { type: "object" properties: { data: { type: "object" properties: { id: { type: "integer" format: "int64" description: "ID of home directory resource." } type: { type: "string" description: "Type is resource." enum: ["resource"] } } } } } ownerAccount: { type: "object" properties: { data: { type: "object" properties: { id: { type: "integer" format: "int32" description: "ID of the account." } type: { type: "string" description: "Type is account." enum: ["account"] } } } } } } } type: { type: "string" description: "Type of object being returned. Always \"user\"" } } } included: { type: "array" items: { type: "object" } } responseStatus: { type: "integer" description: "Http code for the response." } } } }