Controller: Users

API Controller /nodeworx/users
Required Permissions ["NODEWORXUSER"]
Action Description
activate Activates a NodeWorx user.
add Add a new nodeworx user.
deactivate Deactivates (but does not delete) a NodeWorx user.
delete Delete a nodeworx user.
edit Edit a user.
isReseller Check if the current user is a reseller or not.
list List NodeWorx users. DEPRECATED in version 4.8.0-393
listDeletable List deletable NodeWorx users.
listEditable List editable NodeWorx users.
listMasterUser Get details of the master user.
listUsers List NodeWorx users.
listWorkingUser Get details of the working user.

Action: activate (Added in version 4.8.0-393)

Activates a NodeWorx user.

Input Parameters

Name Type Notes Required?
user struct (string)
Example Values
second@interworx.com
Yes

Action: add

Add a new nodeworx user.

Input Parameters

Name Type Notes Required?
nickname string No*
email string No*
language string
Example Values
cs, en-us, fr, de, hu, it, pl, pt, sk, es, sv, tr
Example Default Value
en-us
No*
theme string
Example Values
blue_steel, calliope, coolfreshness, interstate, interworx, nexcess, vanillaice
Example Default Value
interworx
No*
menu_style string
Example Values
big, small
Example Default Value
small
No*
encrypted string
Description
"y" if the password is ALREADY encrypted, "n" if the password is not yet encrypted. Default: n
Example Values
y, n
Example Default Value
n
No*
password string Yes
confirm_password string
Help Entry
Confirm the password field by providing it again. Must match the password provided.
Yes
perms struct (string)
Example Values
NODEWORXUSER, LANGUAGES, THEMES, SWACCOUNTS, SHELLUSERS, PACKAGES, LOGIN, BRESTORE, IMPORT, RESELLER, APACHE, EMAIL, FTP, MYSQL, DNS, SSH, APIKEY, CRON, IPS, FIREWALL, UPDATES, GRAPHS, NFS, CLUSTERING, SETTINGS, IWORXLOGS, PHPMYADMIN, PLUGINS, SSL, REMOTEASSIST
No
* indicates that it's actually required, but probably already has a valid default value

Action: deactivate (Added in version 4.8.0-393)

Deactivates (but does not delete) a NodeWorx user.

Input Parameters

Name Type Notes Required?
user struct (string)
Example Values
second@interworx.com
Yes

Action: delete

Delete a nodeworx user.

Input Parameters

Name Type Notes Required?
user struct (string)
Example Values
second@interworx.com
Yes

Action: edit

Edit a user.

Input Parameters

Name Type Notes Required?
user string
Example Values
apidocs@interworx.com, second@interworx.com
Yes
nickname string
Example Default Value
Server Admin
No*
email string
Example Default Value
apidocs@interworx.com
No*
language string
Example Values
cs, en-us, fr, de, hu, it, pl, pt, sk, es, sv, tr
Example Default Value
en-us
No*
theme string
Example Values
blue_steel, calliope, coolfreshness, interstate, interworx, nexcess, vanillaice
Example Default Value
interworx
No*
menu_style string
Example Values
big, small
Example Default Value
small
No*
encrypted string
Description
"y" if the password is ALREADY encrypted, "n" if the password is not yet encrypted. Default: n
Example Values
y, n
Example Default Value
n
No*
password string No
confirm_password string
Help Entry
Confirm the password field by providing it again. Must match the password provided.
No
* indicates that it's actually required, but probably already has a valid default value

Action: isReseller

Check if the current user is a reseller or not.

Example Output

array (
  'status' => 0,
  'payload' => false,
)

Action: list (Added in version 4.6.0-323)

This action has been deprecated as of version 4.8.0-393.

MESSAGE: 2011-01-24 use listUsersAction

List NodeWorx users.

Example Output

array (
  'status' => 0,
  'payload' => 
  array (
    0 => 
    array (
      0 => 'nodeworx_user@example.com',
      1 => 'Server Admin (nodeworx_user@example.com)',
    ),
    1 => 
    array (
      0 => 'second@interworx.com',
      1 => 'NW Secondary User (second@interworx.com)',
    ),
  ),
)

Action: listDeletable (Added in version 4.6.0-323)

List deletable NodeWorx users.

Example Output

array (
  'status' => 0,
  'payload' => 
  array (
    0 => 
    array (
      0 => 'second@interworx.com',
      1 => 'NW Secondary User (second@interworx.com)',
    ),
  ),
)

Action: listEditable (Added in version 4.6.0-323)

List editable NodeWorx users.

Example Output

array (
  'status' => 0,
  'payload' => 
  array (
    0 => 
    array (
      0 => 'nodeworx_user@example.com',
      1 => 'Server Admin (nodeworx_user@example.com)',
    ),
    1 => 
    array (
      0 => 'second@interworx.com',
      1 => 'NW Secondary User (second@interworx.com)',
    ),
  ),
)

Action: listMasterUser

Get details of the master user.

Example Output

array (
  'status' => 0,
  'payload' => 
  array (
    'userid' => 1,
    'nickname' => 'Server Admin',
    'email' => 'nodeworx_user@example.com',
    'ismaster' => true,
    'status' => 'active',
    'language' => 'en-us',
    'theme' => 'interworx',
    'menu_style' => 'small',
    'perms' => 
    array (
      0 => 'NODEWORXUSER',
      1 => 'LANGUAGES',
      2 => 'THEMES',
      3 => 'SWACCOUNTS',
      4 => 'SHELLUSERS',
      5 => 'PACKAGES',
      6 => 'LOGIN',
      7 => 'BRESTORE',
      8 => 'IMPORT',
      9 => 'EMAIL',
      10 => 'RESELLER',
      11 => 'APACHE',
      12 => 'FTP',
      13 => 'MYSQL',
      14 => 'DNS',
      15 => 'SSH',
      16 => 'APIKEY',
      17 => 'CRON',
      18 => 'IPS',
      19 => 'FIREWALL',
      20 => 'UPDATES',
      21 => 'GRAPHS',
      22 => 'NFS',
      23 => 'CLUSTERING',
      24 => 'SETTINGS',
      25 => 'IWORXLOGS',
      26 => 'PHPMYADMIN',
      27 => 'PLUGINS',
      28 => 'SSL',
      29 => 'REMOTEASSIST',
    ),
  ),
)

Action: listUsers (Added in version 4.8.0-393)

List NodeWorx users.

Example Output

array (
  'status' => 0,
  'payload' => 
  array (
    0 => 
    array (
      'global_uid' => 'nw1',
      'email' => 'nodeworx_user@example.com',
      'nickname' => 'Server Admin',
      'language' => 'en-us',
      'user_status' => 'active',
      'type' => 'master',
    ),
    1 => 
    array (
      'global_uid' => 'nw37',
      'email' => 'second@interworx.com',
      'nickname' => 'NW Secondary User',
      'language' => 'en-us',
      'user_status' => 'active',
      'type' => 'slave',
    ),
  ),
)

Action: listWorkingUser

Get details of the working user.

Example Output

array (
  'status' => 0,
  'payload' => 
  array (
    'userid' => 1,
    'nickname' => 'Server Admin',
    'email' => 'nodeworx_user@example.com',
    'ismaster' => true,
    'status' => 'active',
    'language' => 'en-us',
    'theme' => 'interworx',
    'menu_style' => 'small',
    'perms' => 
    array (
      0 => 'NODEWORXUSER',
      1 => 'LANGUAGES',
      2 => 'THEMES',
      3 => 'SWACCOUNTS',
      4 => 'SHELLUSERS',
      5 => 'PACKAGES',
      6 => 'LOGIN',
      7 => 'BRESTORE',
      8 => 'IMPORT',
      9 => 'EMAIL',
      10 => 'RESELLER',
      11 => 'APACHE',
      12 => 'FTP',
      13 => 'MYSQL',
      14 => 'DNS',
      15 => 'SSH',
      16 => 'APIKEY',
      17 => 'CRON',
      18 => 'IPS',
      19 => 'FIREWALL',
      20 => 'UPDATES',
      21 => 'GRAPHS',
      22 => 'NFS',
      23 => 'CLUSTERING',
      24 => 'SETTINGS',
      25 => 'IWORXLOGS',
      26 => 'PHPMYADMIN',
      27 => 'PLUGINS',
      28 => 'SSL',
      29 => 'REMOTEASSIST',
    ),
  ),
)