<< Click to Display Table of Contents >> Navigation: API > users > add |
Description
Adds a user to the organization's account.
Syntax
https://api.cameyo.com/users/add?clientId=...&clientSecret=...&user=newuser@company.com
Required parameters
•user: username (email) of the user to be created.
Optional parameters
•pwd: password for the newly-created user. If parameter is omitted, a random password is generated instead and is returned in the reply's message field.
•group: user group id to add user into. If user group has an expiration counter, the user's expiration starts from the moment this API is called. If this parameter is omitted, user is added to the default group (which never has an expiration date).
•existing: when set to "reset" and the user already exists, its expiration timer is reset and the function returns success.
•sendmail: when "true", an email will be sent to the new user, according to the Invitation Email section of the portal's company settings page.
•expire: when set, specifies the number of days after which the account gets expired. Not recommended: it is preferred to use the user group's expiration property rather than setting this parameter individually for users.
•powertags: PowerTags for the new user. If the group parameter is set to "(new)", these PowerTags are bound to the newly-created user group instead.
•POST data can be passed along with this call for the powertags field.
Return
200: success.
400: invalid parameters.
403: authentication failed or insufficient permissions.
409: an item with this id already exists.
412: insufficient licenses.
Response examples:
{"success":true,"code":200,"message":null}
{"success":true,"code":200,"message":"Qc4NMDZ4aNmDeUX"}
{"success":false,"code":409,"message":"User already exists"}