Create a user

Create a new user in a realm.

Note: The requesting user must be an administrator.


Usage examples

#!/usr/bin/env python

import wyzepal

# The user for this wyzepalrc file must be an organization administrator
client = wyzepal.Client(config_file="~/wyzepalrc-admin")

# Create a user
request = {
    'email': '',
    'password': 'temp',
    'full_name': 'New User',
    'short_name': 'newbie'
result = client.create_user(request)

More examples and documentation can be found here.

const wyzepal = require('wyzepal-js');

// The user for this wyzepalrc file must be an organization administrator.
const config = {
    wyzepalrc: 'wyzepalrc-admin',

wyzepal(config).then((client) => {
    // Create a user
    const params = {
        email: '',
        password: 'temp',
        full_name: 'New User',
        short_name: 'newbie'

curl -X POST \
    -d "" \
    -d "full_name=New User" \
    -d "short_name=newbie" \
    -d "password=temp"


Argument Example Required Description
email "" Yes

The email address of the new user.

password "abdec@7982" Yes

The password of the new user.

full_name "John Smith" Yes

The full name of the new user.

short_name "jsmith" Yes

The short name of the new user.


Example response

A typical successful JSON response may look like:

    "msg": "",
    "result": "success"

A typical JSON response for when another user with the same email address already exists in the realm:

    "msg": "Email '' already in use",
    "result": "error"