Skip to content

createAppLevelUserPreferences ​

Create a new APP-Level user preference for an authenticated users.

Supported keys for V1 are: APP-FAV - Favourite APP-ORD - Connection Order APP-SHS - Search History

Request ​

http
POST /rest/user/preferences/app

Headers ​

HeaderRequiredDescription
x-nextinteract-authtokenYesAuth token returned from loginUser

Parameters ​

ParameterTypeRequiredDescription
keyString(7)YesKey for the app-level user preference. See keys above.
valuesArray of Strings (max length 100)YesThe values to be set for the given app-level user preference. At least one required.

SAMPLE REQUEST:

json
{
    "key" : "APV-ORD",
    "values" : [
        "1,2,3,4"
    ]
}

Response ​

200 OK ​

Returns the newly created user preferences with valueIds that can be used for updates/deletes.

RESPONSE:

json
{
    "uPrefId": 29,
    "type": "APP",
    "key": "APP-FAV",
    "values": [
        {
            "uPrefValueId": 31,
            "value": "1",
            "lastModified": 1567662973000
        },
        {
            "uPrefValueId": 29,
            "value": "2",
            "lastModified": 1567662973000
        },
        {
            "uPrefValueId": 30,
            "value": "3",
            "lastModified": 1567662973000
        },
        {
            "uPrefValueId": 32,
            "value": "4",
            "lastModified": 1567662973000
        }
    ]
}

Errors ​

ExceptionDescription
WSInvalidParameterExceptionSee Error Definitions
WSInvalidAuthTokenExceptionSee Error Definitions
WSCacheServiceExceptionSee Error Definitions
WSUserPreferenceServiceExceptionSee Error Definitions
WSBrochureNotFoundExceptionSee Error Definitions
WSInsufficientPrivilegesExceptionSee Error Definitions
WSAuthorisationServiceExceptionSee Error Definitions
WSAlreadyExistsExceptionSee Error Definitions