updateSite

put

/ccadmin/v1/sites/{id}

Update Site. Update a site based on ID and request parameters. Note that only a subset of properties can vary by site. **Requires the x-ccasset-language header so translated content can be set for a specific language.**

Request

Supported Media Types
  • application/json
Path Parameters
id
Type: string
Required: true
The ID of the site.
Header Parameters
X-CCAsset-Language
Type: string
Required: true
The asset language of the request
Body Parameter
Root Schema : updateSite_request
Nested Schema : properties
Type: object
Object with updatable properties.
Nested Schema : additionalLocaleIds
Type: array
Additional locale IDs.
Nested Schema : additionalProductionURLs
Type: array
The additional production URLs.
Nested Schema : defaultCatalog
Type: object
The default catalog.
Nested Schema : defaultPriceListGroup
Type: object
Default priceListGroup to be associated with site.
Nested Schema : loyaltyPrograms
Type: array
List of loyalty programs associated with site.
Nested Schema : priceListGroupList
Type: array
List of priceListGroups to be associated with site.
Nested Schema : shipFromAddress
Type: object
The ship from address used for tax calculations.
Nested Schema : siteTypes
Type: array
List of site types supported by this site
Nested Schema : items
Type: object
Nested Schema : items
Type: object

Response

Supported Media Types
  • application/json
200 Response
Following model is returned when operation succeeds.
Body
Root Schema : updateSite_response
Nested Schema : additionalLocaleIds
Type: array
Additional Country ids.
Nested Schema : additionalProductionURLs
Type: array
A list of additional production URLs (without schema). Currently, only plain hostnames are supported.
Nested Schema : allowedOriginMethods
Type: object
Map of hostname (key) and the allowed http methods (values) for that host.
Nested Schema : defaultCatalog
Type: object
The default catalog id.
Nested Schema : defaultPriceListGroup
Type: object
The default PLG for the site.
Nested Schema : loyaltyPrograms
Type: array
List of loyalty programs associated with site.
Nested Schema : priceListGroupList
Type: array
List of Price List Groups associated with the site including default Price List Group
Nested Schema : shipFromAddress
Type: object
The ship from address used for tax calculations.
Nested Schema : siteTypes
Type: array
List of site types supported by this site
Nested Schema : items
Type: object
Nested Schema : items
Type: object
Example application/json

{
    "priceListGroupList":[
        {
            "repositoryId":"defaultPriceGroup",
            "id":"defaultPriceGroup"
        },
        {
            "repositoryId":"EURO",
            "id":"EURO"
        }
    ],
    "favicon":null,
    "timezone":"europe_london",
    "noimage":null,
    "secondaryCurrency":"USD",
    "defaultBillingCountryId":"US",
    "defaultShippingCountryId":"US",
    "siteTypes":[
        "b2bCommerce"
    ],
    "timeToLive":5000,
    "defaultLocaleId":"1",
    "shipFromAddress":{
        "country":"US",
        "city":"Cambridge",
        "postalCode":"02142",
        "addressLine1":"1 Main Street",
        "addressLine2":"Foo",
        "addressLine3":"Bar",
        "region":"MA"
    },
    "loyaltyPrograms":[
        {
            "programName":"Movie rewards",
            "repositoryId":"siteUS_LP0001",
            "associationDate":"2017-07-05T14:15:37.000Z",
            "programId":"LP0001"
        }
    ],
    "name":"CloudLake US Site",
    "repositoryId":"siteUS",
    "id":"siteUS",
    "additionalLocaleIds":[
        "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| |------------------|------------------| |100092|{0} is an invalid value for {1}.| |30001|A site id is required to update a site| |30004|Given Site id does not exist| |30015|Invalid Site Base URL ''{0}'' specified.| |30003|Update site failed| |30014|Could not update site. Allowed site types are {0}| |25015|set Property RepositoryItem Internal Error| |25014|convert Input Property Type Internal Error| |100092|The value ''{0}'' for parameter ''{1}'' is not among the {2,number,integer} valid options. Showing the first {3,number,integer} valid options: {4}
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:

{"properties": {
  "priceListGroupList": [
    {"id": "EURO"},
    {"id": "defaultPriceGroup"}
  ],
  "name": "CloudLake US Site test",
  "siteTypes": ["b2bCommerce"]
}}

Sample Response Payload returned by endpoint:

{
  "priceListGroupList": [
    {
      "repositoryId": "defaultPriceGroup",
      "id": "defaultPriceGroup"
    },
    {
      "repositoryId": "EURO",
      "id": "EURO"
    }
  ],
  "favicon": null,
  "timezone": "europe_london",
  "noimage": null,
  "secondaryCurrency": "USD",
  "defaultBillingCountryId": "US",
  "defaultShippingCountryId": "US",
  "siteTypes": ["b2bCommerce"],
  "timeToLive": 5000,
  "defaultLocaleId": "1",
  "shipFromAddress": {
    "country": "US",
    "city": "Cambridge",
    "postalCode": "02142",
    "addressLine1": "1 Main Street",
    "addressLine2": "Foo",
    "addressLine3": "Bar",
    "region": "MA"
  },
  "loyaltyPrograms": [{
    "programName": "Movie rewards",
    "repositoryId": "siteUS_LP0001",
    "associationDate": "2017-07-05T14:15:37.000Z",
    "programId": "LP0001"
  }],
  "name": "CloudLake US Site",
  "repositoryId": "siteUS",
  "id": "siteUS",
  "additionalLocaleIds": ["1"]
}