Users: Retrieving, Creating, Updating, and Deleting Users via the API

In this article, you can read about retrieving, creating, updating, and deleting users via the API.

Get Users

GET

Retrieves a list of all users. The result can be limited by department or corporation using the optional
departmentId or corporationId parameters.

https://api.recman.io/v2/get/?key={{api_key}}&scope=user&
fields=firstName,lastName,email,title,admin&
departmentId={{departmentId}}
FieldTypeRequiredDescription
keystringRequiredYour API key
scopestringRequiredMust be set to user
fieldsstringRequiredAt least 1 required, comma-separated values
departmentIdintegerOptionalSearch criteria. Limits results to users connected to this department
corporationIdintegerOptionalSearch criteria. Limits results to users connected to this corporation

User fields

FieldTypeDescription
userIdintegerRequired on operation: update, delete
firstNamestringFirst name
lastNamestringLast name
mobilePhoneobjectBest practice example: "mobilePhone": 
{"prefix": "+47", "number": "57877545"}
officePhoneobjectBest practice example: "officePhone": 
{"prefix": "+47", "number": "57877545"}
emailstringEmail
titlestringTitle. Example: "General Manager"
facebookstringFacebook
linkedinstringLinkedIn
twitterstringTwitter
departmentIdstringDepartment ID this user is connected to
corporationIdstringCorporation ID this user is connected to
adminstring
boolean
 Whether the user is a superadmin. 
0 = not superadmin, 1 = is superadmin
createdstringDate of creation
updatedstringDate of last update
profilePicturestringProfile picture link
userTagListstringTags applied to this user
genderstringValid values: female, male

Insert User

POST

Creates a new user. The operation must be set to insert and the scope to user. It is required to specify the corporationId, departmentId, email, firstName, and 
lastName fields when inserting a user.

https://api.recman.io/v2/post/
FieldTypeRequiredDescription
corporationIdintegerRequiredCorporation ID this user is connected to
departmentIdintegerRequiredDepartment ID this user is connected to
emailstringRequiredEmail
firstNamestringRequiredFirst name
lastNamestringRequiredLast name
titlestringOptionalExample: "General Manager"
genderstringOptionalAllowed values: female, male
mobilePhoneobjectOptionalBest practice example: "mobilePhone": 
{"prefix": "+47", "number": "57877545"}
officePhoneobjectOptionalBest practice example: "officePhone": 
{"prefix": "+47", "number": "57877545"}
facebookstringOptionalFacebook
linkedinstringOptionalLinkedIn
twitterstringOptionalX (Twitter)

Update User

POST

Updates an existing user. The operation must be set to update and the scope to user. It is required to specify the userId field when updating a user.

https://api.recman.io/v2/post/
FieldTypeRequiredDescription
userIdintegerRequiredID of the user to update
departmentIdintegerOptionalDepartment ID this user is connected to
emailstringOptionalEmail
firstNamestringOptionalFirst name
lastNamestringOptionalLast name
titlestringOptionalExample: "General Manager"
genderstringOptionalAllowed values: female, male
mobilePhoneobjectOptionalBest practice example: "mobilePhone": 
{"prefix": "+47", "number": "57877545"}
officePhoneobjectOptionalBest practice example: "officePhone": 
{"prefix": "+47", "number": "57877545"}
facebookstringOptionalFacebook
linkedinstringOptionalLinkedIn
twitterstringOptionalX (Twitter)

Delete User

POST

Deletes a user. The operation must be set to delete and the scope to user. It is required to specify the userId field when deleting a user.

https://api.recman.io/v2/post/
FieldTypeRequiredDescription
userIdintegerRequiredID of the user to delete
Was this article helpful?
0 out of 0 found this helpful