getCustomSiteSettings
get
/ccadmin/v1/sitesettings/{id}
Get Custom Site Settings. Get site settings by ID.
Request
Supported Media Types
- application/json
Path Parameters
- id
-
Type:
string
Required:true
The ID of the site setting.
Response
Supported Media Types
- application/json
200 Response
Following model is returned when operation succeeds.
Body
Root Schema : getCustomSiteSettings_response
Nested Schema : config
Nested Schema : data
Type:
object
Dynamic Object containing the instance data for this site settings, see sample response
- __config_name__
-
Type:
string
The value of this will be config name of a config property in the config array - value
-
Type:
string
the value stored against this configuration property
Nested Schema : items
Type:
object
- defaultValue
-
Type:
string
The default value of the configuration item - helpText
-
Type:
string
The help text to be display against the configuration item - label
-
Type:
string
The label to be display for the configuration item - maxLength
-
Type:
integer
The maximum length of the configuration item - minLength
-
Type:
integer
The minimum length of the configuration item - name
-
Type:
string
The name the configuration item - options
-
Type:
array
optionsAdditional Properties Allowed:Array of options for an option type - regexText
-
Type:
string
Repository ID - repositoryId
-
Type:
string
Repository ID - required
-
Type:
string
If the configuration item is required or not - type
-
Type:
string
The type of the configuration value e.g string, option
Nested Schema : options
Nested Schema : items
Type:
object
- label
-
Type:
string
The text to be displayed on the option - repositoryId
-
Type:
string
Repository ID - value
-
Type:
integer
The option value
Example application/json
{
"data":{
"password":"Password02",
"coupon":"SHIP101",
"minSpend":"101",
"bannerSize":"m",
"enabled":true
},
"config":{
"displayName":"Some Settings!",
"values":[
{
"helpText":"Enable the cart message.",
"defaultValue":"true",
"minLength":0,
"name":"enabled",
"repositoryId":"100005",
"options":[
],
"regexText":null,
"label":"Enable",
"type":"checkbox",
"maxLength":1000,
"required":false
},
{
"helpText":"Define the coupon name.",
"defaultValue":"SHIP100",
"minLength":6,
"name":"coupon",
"repositoryId":"100006",
"options":[
],
"regexText":null,
"label":"Coupon",
"type":"text",
"maxLength":10,
"required":true
},
{
"helpText":"Define the minimum spend for the coupon.",
"defaultValue":"100",
"minLength":0,
"name":"minSpend",
"repositoryId":"100007",
"options":[
],
"regexText":null,
"label":"Minimum Spend",
"type":"text",
"maxLength":1000,
"required":true
},
{
"helpText":"Set the value for API key.",
"defaultValue":null,
"minLength":0,
"name":"password",
"repositoryId":"100008",
"options":[
],
"regexText":null,
"label":"API Key",
"type":"password",
"maxLength":1000,
"required":true
},
{
"helpText":"The size of the banner.",
"defaultValue":"s",
"minLength":0,
"name":"bannerSize",
"repositoryId":"100009",
"options":[
{
"repositoryId":"100006",
"label":"Small",
"value":"s"
},
{
"repositoryId":"100007",
"label":"Medium",
"value":"m"
},
{
"repositoryId":"100008",
"label":"Large",
"value":"l"
}
],
"regexText":null,
"label":"Banner Size",
"type":"option",
"maxLength":1000,
"required":true
}
],
"repositoryId":"settingsdemo",
"description":"Here are some settings.",
"id":"settingsdemo"
}
}
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|
|------------------|------------------|
|33061|Could not get site settings for the id|
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 Response Payload returned by endpoint:
{ "data": { "password": "Password02", "coupon": "SHIP101", "minSpend": "101", "bannerSize": "m", "enabled": true }, "config": { "displayName": "Some Settings!", "values": [ { "helpText": "Enable the cart message.", "defaultValue": "true", "minLength": 0, "name": "enabled", "repositoryId": "100005", "options": [], "regexText": null, "label": "Enable", "type": "checkbox", "maxLength": 1000, "required": false }, { "helpText": "Define the coupon name.", "defaultValue": "SHIP100", "minLength": 6, "name": "coupon", "repositoryId": "100006", "options": [], "regexText": null, "label": "Coupon", "type": "text", "maxLength": 10, "required": true }, { "helpText": "Define the minimum spend for the coupon.", "defaultValue": "100", "minLength": 0, "name": "minSpend", "repositoryId": "100007", "options": [], "regexText": null, "label": "Minimum Spend", "type": "text", "maxLength": 1000, "required": true }, { "helpText": "Set the value for API key.", "defaultValue": null, "minLength": 0, "name": "password", "repositoryId": "100008", "options": [], "regexText": null, "label": "API Key", "type": "password", "maxLength": 1000, "required": true }, { "helpText": "The size of the banner.", "defaultValue": "s", "minLength": 0, "name": "bannerSize", "repositoryId": "100009", "options": [ { "repositoryId": "100006", "label": "Small", "value": "s" }, { "repositoryId": "100007", "label": "Medium", "value": "m" }, { "repositoryId": "100008", "label": "Large", "value": "l" } ], "regexText": null, "label": "Banner Size", "type": "option", "maxLength": 1000, "required": true } ], "repositoryId": "settingsdemo", "description": "Here are some settings.", "id": "settingsdemo" } }