updateProfileContextList
put
/ccadmin/v1/profileContextLists/{id}
Update Profile Context List. Update a profileContextList item. Note that when a profileContextList is updated, the JSON should contain a representation of all profileContexts. If the JSON array from the profileContexts property contains a single element, for example, then all other profileContexts will be deleted. Note that the "propertyName" property is all that is needed to identify an existing profileContext, so providing other properties that are unchanged is optional.
Request
Supported Media Types
- application/json
Path Parameters
- id
-
Type:
string
Required:true
The ID of the profileContextList to be updated.
Body Parameter
Root Schema : updateProfileContextList_request
{
"profileContexts":[
{
"priceListGroupList":[
{
"id":"defaultPriceGroup"
}
],
"propertyName":"active",
"defaultPriceListGroup":{
"id":"defaultPriceGroup"
}
}
],
"id":"defaultProfileContextList"
}
- id
-
Type:
string
The ID of the profileContextList item to be updated. (read-only) - profileContexts
-
Type:
array
profileContextsAdditional Properties Allowed:The ordered list of profileContexts.
Nested Schema : profileContexts
Nested Schema : items
Type:
object
- defaultPriceListGroup
-
Type:
object
defaultPriceListGroupAdditional Properties Allowed:The default priceListGroup for the profileContext. Properties other than "id" may be visible, but are not editable via this endpoint. - priceListGroupList
-
Type:
array
priceListGroupListAdditional Properties Allowed:The list of available priceListGroups for the profileContext. Properties other than "id" may be visible, but cannot be updated by this endpoint. - propertyName
-
Type:
string
Required:true
The name of the profile boolean property that, when true on the current profile, will cause the profileContext to be active. A given property name can only appear once in the profileContexts list.
Nested Schema : defaultPriceListGroup
Type:
object
The default priceListGroup for the profileContext. Properties other than "id" may be visible, but are not editable via this endpoint.
- id
-
Type:
string
Required:true
The ID of the default priceListGroup. Note that updating this ID merely updates a reference to an existing priceListGroup, and does not modify the priceListGroup itself.
Nested Schema : priceListGroupList
Nested Schema : items
Type:
object
- id
-
Type:
string
The ID of the priceListGroup. Note that updating the ID property just updates a reference to an existing priceListGroup, and does not modify the priceListGroup itself.
Response
Supported Media Types
- application/json
200 Response
Following model is returned when operation succeeds.
Body
Root Schema : updateProfileContextList_response
- id
-
Type:
string
The ID of the profileContextList item. - profileContexts
-
Type:
array
profileContextsAdditional Properties Allowed:The ordered list of profileContexts. If present, this list much contain a representation of every profileContext to be retained. For existing profileContexts, only the "propertyName" property need be provided.
Nested Schema : profileContexts
Nested Schema : items
Type:
object
- defaultPriceListGroup
-
Type:
object
defaultPriceListGroupAdditional Properties Allowed:The default priceListGroup for the profile contexts - priceListGroupList
-
Type:
array
priceListGroupListAdditional Properties Allowed:The array of available priceListGroups. This list should contain the defaultPriceListGroup, as well. - propertyName
-
Type:
string
The name of the profile boolean property that, when true on the current profile, will cause the profileContext to (potentially) be active.
Nested Schema : defaultPriceListGroup
Type:
object
The default priceListGroup for the profile contexts
- id
-
Type:
string
The ID of the default price list group. Note that updating this ID merely updates a reference to an existing priceListGroup, and does not modify the priceListGroup itself.
Nested Schema : priceListGroupList
Nested Schema : items
Type:
object
- id
-
Type:
string
The ID of the priceListGroup.
Example application/json
{
"profileContexts":[
{
"priceListGroupList":[
{
"id":"defaultPriceGroup"
}
],
"propertyName":"active",
"defaultPriceListGroup":{
"id":"defaultPriceGroup"
}
}
],
"links":[
{
"rel":"self",
"href":"http://localhost:9080/ccadmin/v1/profileContextLists/defaultProfileContextList"
}
],
"id":"defaultProfileContextList"
}
Default Response
The error response
Body
Root Schema : errorModel
Type:
object
- devMessage
-
Type:
string
An optional non-localized message containing technical information for developers - errorCode
-
Type:
string
The numerical code identifying the error - errors
-
Type:
array
errorsAdditional Properties Allowed:An optional list of errors if multiple errors were encountered - message
-
Type:
string
The localized message describing the error - moreInfo
-
Type:
string
An optional non-localized message with more information - o:errorPath
-
Type:
string
An optional machine readable description of where the error occurred - status
-
Type:
string
The HTTP status code - type
-
Type:
string
The URI to the HTTP state code definition
Nested Schema : errors
Nested Schema : items
Type:
object
- devMessage
-
Type:
string
An optional non-localized message containing technical information for developers - errorCode
-
Type:
string
The numerical code identifying the error - message
-
Type:
string
The localized message describing the error - moreInfo
-
Type:
string
An optional non-localized message with more information - o:errorPath
-
Type:
string
An optional machine readable description of where the error occurred - status
-
Type:
string
The HTTP status code
Examples
Sample Request:
{ "profileContexts": [{ "priceListGroupList": [{"id": "defaultPriceGroup"}], "propertyName": "active", "defaultPriceListGroup": {"id": "defaultPriceGroup"} }], "id": "defaultProfileContextList" }
Sample Response Payload returned by endpoint:
{ "profileContexts": [{ "priceListGroupList": [{"id": "defaultPriceGroup"}], "propertyName": "active", "defaultPriceListGroup": {"id": "defaultPriceGroup"} }], "links": [{ "rel": "self", "href": "http://localhost:9080/ccadmin/v1/profileContextLists/defaultProfileContextList" }], "id": "defaultProfileContextList" }