updateSiteProperties

put

/ccagent/v1/profiles/{id}/siteProperties

Update site properties for specific customer. Example: Update recieve email property with yes or no for specic site

Request

Supported Media Types
  • application/json
Path Parameters
id
Type: string
Required: true
The customer profile id.
Body Parameter
Root Schema : updateSiteProperties_request
Nested Schema : siteProperties
Type: array
The site related properties
Nested Schema : items
Type: object
Nested Schema : properties
Type: object
The site related properties to be updated for the profile
Nested Schema : site
Type: object
The site data

Response

Supported Media Types
  • application/json
200 Response
Following model is returned when operation succeeds.
Body
Root Schema : updateSiteProperties_response
Nested Schema : items
Type: array
The list of site related properties for the profile
Nested Schema : items
Type: object
Nested Schema : properties
Type: object
The site related properties for the profile
Nested Schema : site
Type: object
The site data
Example application/json

{
    "totalResults":1,
    "endingIndex":250,
    "offset":0,
    "totalResultsParam":true,
    "count":1,
    "limit":250,
    "links":[
        {
            "rel":"self",
            "href":"http://localhost:9080/ccagentui/v1/profiles/se-570031/siteProperties"
        }
    ],
    "sort":null,
    "items":[
        {
            "site":{
                "id":"SiteA"
            },
            "properties":{
                "receiveEmail":"yes"
            }
        }
    ],
    "listingRequest":{
        "endingIndex":250,
        "correctedView":null,
        "queryOptions":{
            "precachedPropertyNames":null,
            "doNotCacheQuery":false,
            "sortDirectives":null,
            "endingIndex":250,
            "ignoreDuplicates":false,
            "nthIndex":1,
            "uncachedItems":false,
            "uncachedItemsSet":false,
            "startingIndex":0
        },
        "rqlString":null,
        "QErrorCodeMap":null,
        "QPropertyAliasMap":null,
        "sort":null,
        "startingIndex":0,
        "QIgnoreCase":true,
        "QString":null,
        "filterProperties":[
            "displayName",
            "id"
        ],
        "includeRqlInQueryGeneration":true,
        "rqlStatement":null,
        "expanded":false,
        "scimParser":null,
        "useSCIMForQ":true,
        "limit":250,
        "siteId":null,
        "after":null,
        "calculateTotalAvailable":true
    },
    "startingIndex":0,
    "totalNumberOfItems":1
}
Default Response
The error response. The following are the internal error codes thrown by this API when the request processing fails in Oracle Commerce Cloud: |Error Code|Description| |------------------|------------------| |200012|please provide valid input| |23010|City not specified in shipping address| |23011|Address line 1 not specified in shipping address| |22000|The profile id passes is null or empty.| |23012|No last name specified in shipping address| |22001|Internal error while getting the profile.| |23013|No first name specified in shipping address| |22002|No profile found with the given id.| |23015|Phone number not specified in shipping address| |23005|Invalid phone number in shipping address| |23007|No country specified in shipping address| |23008|Postal code not specified in shipping address| |22024|{0}({1}) must be a String|
Body
Root Schema : errorModel
Type: object
Nested Schema : errors
Type: array
An optional list of errors if multiple errors were encountered
Nested Schema : items
Type: object

Examples

Sample Request:

{"siteProperties": [{
  "site": {"id": "SiteA"},
  "properties": {"receiveEmail": "yes"}
}]}

Sample Response Payload returned by endpoint:

{
  "totalResults": 1,
  "endingIndex": 250,
  "offset": 0,
  "totalResultsParam": true,
  "count": 1,
  "limit": 250,
  "links": [{
    "rel": "self",
    "href": "http://localhost:9080/ccagentui/v1/profiles/se-570031/siteProperties"
  }],
  "sort": null,
  "items": [{
    "site": {"id": "SiteA"},
    "properties": {"receiveEmail": "yes"}
  }],
  "listingRequest": {
    "endingIndex": 250,
    "correctedView": null,
    "queryOptions": {
      "precachedPropertyNames": null,
      "doNotCacheQuery": false,
      "sortDirectives": null,
      "endingIndex": 250,
      "ignoreDuplicates": false,
      "nthIndex": 1,
      "uncachedItems": false,
      "uncachedItemsSet": false,
      "startingIndex": 0
    },
    "rqlString": null,
    "QErrorCodeMap": null,
    "QPropertyAliasMap": null,
    "sort": null,
    "startingIndex": 0,
    "QIgnoreCase": true,
    "QString": null,
    "filterProperties": [
      "displayName",
      "id"
    ],
    "includeRqlInQueryGeneration": true,
    "rqlStatement": null,
    "expanded": false,
    "scimParser": null,
    "useSCIMForQ": true,
    "limit": 250,
    "siteId": null,
    "after": null,
    "calculateTotalAvailable": true
  },
  "startingIndex": 0,
  "totalNumberOfItems": 1
}