Skip to main content

Version: 21.05 (EOL)

POST Update Current User Preferences

Updates/Replaces the portal preferences for the user currently logged in to the portal.

Request

HTTP request

POST https://<JM_SERVER>/workspaces/secure/api/v1/current-user/preferences-update

Request body

The POST request must contain a JSON structure describing the current user preferences update details.

To support multiple parameters this API uses HTTP Content Type: application/json.

The set of query JSON attributes is listed below. All attributes are optional except where otherwise indicated.

AttributeDescription
paramsMap
Required. Specify parameters to pass into the update. Must contain only the map "prefs".

Within the params map attribute, "prefs" are required for updating the current user portal preferences.

Response

If successful, this operation returns a response with a HTTP 200 OK status code.

Error messages

Error keyErrorHTTP status code
currentUserNotFoundUnable to resolve user from request400 Bad Request
internalErrorPlease see Error Log ID {number}500 Internal Server Error
paramsNotSetParameters not specified400 Bad Request
prefsNotSetNew preferences not specified400 Bad Request
unableToResolvePortalUnable to resolve portal from request400 Bad Request

Error responses

HTTP status codeDescription
400 Bad RequestBad request or request parameter. Check error message for details.
404 Not FoundEnsure the URL endpoint is entered correctly.
500 Internal Server ErrorException occurred in current user preference update. Contact administrator.

Example

Ensure you specify Content-Type: application/json.

Example request
POST /workspaces/secure/api/v1/current-user/preferences-update HTTP/1.1
Host: https://transact.workspaces.com
Content-Type: application/json

{
"params": {
"prefs": {
"lastPage": "Help Desk",
"defaultGroup": "CCA Reviewers",
"defaultStartDate": "-30d"
}
}
}