CREATE or UPDATE Users with Rest API

note_awesome

LIMITATION

You can create or update only 1 user in a Rest call.

All the following examples assume that the base URL for the REST API is: http://<WebApp URL>/restapi

Supported Operations for User Management

For the Task of ...

Use the following REST call (URL)

To create new User records

CALL Type: POST

URL:

http://<WebApp URL>/restapi/component/user

JSON Payload (example):

In the payload, include all the fields and values which need to be updated, for example:

{

"username": "demo",

"fullname": "Demo User",

"emailaddress": "demo@<company>.com",

"userdescription": "Demo User",

"password": "Demo123",

"activeaccountflag": true,

"temporarydisabledflag": false,

"domains": null,

"logintype": "Manual",

"timezone": null,

"dashboard": "Home (Simple)",

"locality": null,

"roles": [

"System Role - ALL USERS",

"User Role - Action - General"

],

"forceuserpasswordreset": false

}

 

 

NOTE: Timed Access fields can also be included in the payload to create users for a restricted period, the payload can include the following fields as example:

{

"accessstartdate": "2026-02-23",

"accessstarttime": "09:00:00",

"accessenddate": "2026-02-23",

"accessendtime": "17:00:00"

}

 

To update existing User

CALL Type: PATCH

URL:

http://<WebApp URL>/restapi/component/user('UniqueID_of_User')

JSON Payload (example):

In the payload, include all the fields and values which need to be updated, for example:

{

"username": "demo",

"fullname": "Demo User",

"emailaddress": "demo@<company>.com",

"userdescription": "Demo User",

"password": "Demo123",

"activeaccountflag": true,

"temporarydisabledflag": false,

"domains": null,

"logintype": "Manual",

"timezone": null,

"dashboard": "Home (Simple)",

"locality": null,

"roles": [

"System Role - ALL USERS",

"User Role - Action - General"

],

"forceuserpasswordreset": false

}

 

NOTES:

If the number of Roles in the payload

  • is 1:
    the update will be append the new role to the existing list of roles
  • is more than 1:
    the existing list of roles will be replaced with the new list of roles

 

To clear the roles, use the following in the payload:

{

"roles":[]
}

 

Timed Access fields can also be included in the payload to create users for a restricted period, the payload can include the following fields as example:

{

"accessstartdate": "2026-02-23",

"accessstarttime": "09:00:00",

"accessenddate": "2026-02-23",

"accessendtime": "17:00:00"

}

 

See Also

Rest API

Rest API - Introduction

Add Components to Rest API

Generate an API Key for a User

GET (Read) Operations

PATCH (Write) Operations

POST (Create) Operations

CREATE DBFiles/Files with Rest API

Related Questionnaire with Rest API