Put() [ServicePreferenceManager]

Add or Update

Description

Adds or updates a service preference

Package Details

Interface

IServicePreferenceManager

Syntax

await servicePreferenceManager.Put(ServicePreference servicePreferebce);

Returns

Task<ServicePreference>

API

POST
/api/v1/service-preferences

Parameters

Parameter

Description

Parameter Type

Parameter

Description

Parameter Type

ServicePreference

Service preference object

request body

Sample request body

{ "Key": "string", "ServiceId": 0, "EnglishDescription": "string", "FrenchDescription": "string", "SettingType": "BOOL", //Values can only BOOL, TEXT, INT, DYNAMIC "Value": "True" }

Returns

200 OK - Service Preference

Example

var servicePreference = new ServicePreference { ServiceId = 11, Key = "Test", EnglishDescription = "en-description", FrenchDescription = "fr-description", SettingType = "TEXT", //Values can only BOOL, TEXT, INT, DYNAMIC Value = "test" }; var servicePreference = await _servicePreferenceManager.Put(servicePreference);