Use the list() or batchList() methods on SPPClient to retrieve User objects.
Creating Users:
To add new users, you must use the `CreateUser` (XML API) or `createUser()` (SOAP API) command. Do not use the generic `Add` or `add()` command for `User` objects.
Permissions: You must be authenticated as an account administrator or have the "View, modify, and create new users" role permission to use the `CreateUser` command.
Required Properties for `CreateUser`:
`nickname`: The user's unique nickname.
`addr.email`: The user's email address.
`password`: Required, unless creating a generic user (`generic` set to 1).
`role_id`: The internal ID of the role associated with the user. Defaults to the default role if not set.
`Company` object: Must be specified as an argument, identifying the company the user is being added to.
`User` object: The user object itself must be specified as an argument.
Important Notes for Creation:
If `SAML` authentication is used, a password can be set when creating a new user if the Boolean custom field `saml_auth__c` is set to `true`.
The `CreateUser` command does not support foreign key lookup.
Limits are enforced to prevent creating or activating users if doing so would exceed the number of user licenses purchased for your account. If no user licenses of the appropriate type are available, the `CreateUser` command creates a new user record but sets it as inactive.
Updating Users:
You can use the update() method on SPPClient to update a User object.
Permissions: To modify a user record (other than the authenticated user's own record), the authenticated user must be an administrator or have the "View, modify, and create new users" or "View and modify users" role permission. All authenticated users can modify their own user record without these specific role permissions.
User settings (`flags`) can only be modified by an administrator.
If `SAML` authentication is enabled for a user, passwords cannot be modified when updating an existing user record.
When adding or modifying a user, you can also update:
Loaded cost information (using `update_cost: 1`).
Entity tag information (using `update_tag: 1`).
Work schedule information (using `update_workschedule: 1`).
Reading Users:
You can use the `Read` (XML API) or `read()` (SOAP API) command to retrieve User objects.
The `generic` attribute can be set to `1` when reading `User` objects to return only generic resources.
Deleting Users:
You can use the `Delete` (XML API) or `delete()` (SOAP API) command to delete a User object.
Permissions: Specific permissions apply for deleting user records.
Important: Business rules configured for your company's SuiteProjects Pro account are applied when an integration application interacts with your SuiteProjects Pro data through the REST API. However, they are not applied when interacting through the SOAP API or XML API, where developers must enforce business rules within their integration application if required.
Usage and Permissions
Listing Users:
list()
orbatchList()
methods onSPPClient
to retrieve User objects.Creating Users:
Updating Users:
update()
method onSPPClient
to update a User object.Reading Users:
Deleting Users:
Important: Business rules configured for your company's SuiteProjects Pro account are applied when an integration application interacts with your SuiteProjects Pro data through the REST API. However, they are not applied when interacting through the SOAP API or XML API, where developers must enforce business rules within their integration application if required.