POST api/users/createUser
Create a new user.
Request Information
URI Parameters
None.
Body Parameters
An add user request.
AddUserRequestName | Description | Type | Additional information |
---|---|---|---|
Username |
Username. |
string |
None. |
Firstname |
Firstname. |
string |
None. |
Lastname |
Lastname. |
string |
None. |
Password |
Password, default is your organisation's default password |
string |
None. |
Email address. |
string |
None. |
|
DateOfBirth |
Date of birth. |
SimpleDateTime |
None. |
AutoEnrolCourses |
Auto-enrol courses to the user. |
boolean |
None. |
Request Formats
application/json, text/json
Sample:
{ "Username": "sample string 1", "Firstname": "sample string 2", "Lastname": "sample string 3", "Password": "sample string 4", "Email": "sample string 5", "DateOfBirth": { "Year": 1, "Month": 2, "Day": 3, "Hour": 4, "Minute": 5, "Second": 6, "Millisecond": 7 }, "AutoEnrolCourses": true }
application/xml, text/xml
Sample:
<AddUserRequest xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <Username>sample string 1</Username> <Firstname>sample string 2</Firstname> <Lastname>sample string 3</Lastname> <Password>sample string 4</Password> <Email>sample string 5</Email> <DateOfBirth> <Year>1</Year> <Month>2</Month> <Day>3</Day> <Hour>4</Hour> <Minute>5</Minute> <Second>6</Second> <Millisecond>7</Millisecond> </DateOfBirth> <AutoEnrolCourses>true</AutoEnrolCourses> </AddUserRequest>
application/x-www-form-urlencoded
Sample:
Sample not available.
Response Information
Resource Description
UserName | Description | Type | Additional information |
---|---|---|---|
UserId |
User Id. |
integer |
None. |
OrgId |
Orginisation Id. |
integer |
None. |
Username |
Username. |
string |
None. |
Firstname |
Firstname. |
string |
None. |
Lastname |
Lastname. |
string |
None. |
IsArchived |
If user archived or active. |
boolean |
None. |
Email address. |
string |
None. |
|
DateOfBirth |
Date of birth. |
date |
None. |
ProfilePhotoUrl |
Profile photo temporary url. |
string |
None. |
DateCreated |
Date user was created on. |
date |
None. |
LastActivity |
Last user activity. |
date |
None. |
IsStaff |
If user is a staff member. |
boolean |
None. |
AdvancedID |
ASSO ID. |
string |
None. |
Response Formats
application/json, text/json
Sample:
{ "UserId": 1, "OrgId": 2, "Username": "sample string 3", "Firstname": "sample string 4", "Lastname": "sample string 5", "IsArchived": true, "Email": "sample string 7", "DateOfBirth": "2025-02-23T04:31:22.944257+00:00", "ProfilePhotoUrl": "sample string 9", "DateCreated": "2025-02-23T04:31:22.944257+00:00", "LastActivity": "2025-02-23T04:31:22.944257+00:00", "IsStaff": true, "AdvancedID": "sample string 13" }
application/xml, text/xml
Sample:
<User xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <UserId>1</UserId> <OrgId>2</OrgId> <Username>sample string 3</Username> <Firstname>sample string 4</Firstname> <Lastname>sample string 5</Lastname> <IsArchived>true</IsArchived> <Email>sample string 7</Email> <DateOfBirth>2025-02-23T04:31:22.944257+00:00</DateOfBirth> <ProfilePhotoUrl>sample string 9</ProfilePhotoUrl> <DateCreated>2025-02-23T04:31:22.944257+00:00</DateCreated> <LastActivity>2025-02-23T04:31:22.944257+00:00</LastActivity> <IsStaff>true</IsStaff> <AdvancedID>sample string 13</AdvancedID> </User>