listPromotionTemplates
get
/ccadmin/v1/promotionTemplates
List Promotion Templates. Get a list of promotions promotion templates. The list of results will be paginated based on query parameters.
Request
Supported Media Types
- application/json
Query Parameters
- limit
-
Type:
integer
The number of promotion templates to return from this request.- offset
Type:integer
The starting index/offset to be returned from this request.- totalResults
Type:integer
The total number of promotion templates.- type
Type:string
One of three types of promotion templates to return: item, order, shipping.Response
Supported Media Types- application/json
200 ResponseFollowing model is returned when operation succeeds.BodyRoot Schema : listPromotionTemplates_response- items
-
Type:
array
itemsAdditional Properties Allowed:The promotion templates returned by the listing. - limit
-
Type:
integer
The number of promotion templates intended to be returned in the response. - links
-
Type:
object
linksAdditional Properties Allowed:The links referring to this response, and any applicable next or previous parts of the response. This is based on the total results, limit, and offset. - offset
-
Type:
integer
The starting index/offset within the complete list of of promotion templates. - total
-
Type:
integer
The total number of promotion templates. DEPRECATED. - totalResults
-
Type:
integer
The total number of promotion templates.
Nested Schema : itemsNested Schema : linksType:object
The links referring to this response, and any applicable next or previous parts of the response. This is based on the total results, limit, and offset.Nested Schema : itemsType:object
- displayName
-
Type:
string
The localized display name of the promotion template. - id
-
Type:
string
The promotion template ID. - name
-
Type:
string
The system name of the promotion template. - type
-
Type:
string
The system type of the promotion template.
Example application/json
{ "total":7, "totalResults":7, "offset":0, "limit":3, "links":[ { "rel":"self", "href":"/ccadminui/v1/promotionTemplates?limit=3" }, { "rel":"next", "href":"/ccadminui/v1/promotionTemplates?limit=3&offset=3" } ], "items":[ { "displayName":"Get Item Discount", "name":"getItemDiscount", "id":"item.getItemDiscount", "type":"item" }, { "displayName":"Buy One Get One", "name":"bogo", "id":"item.bogo", "type":"item" }, { "displayName":"Gift with Item Purchase", "name":"getGiftWithPurchase", "id":"item.getGiftWithPurchase", "type":"item" } ] }
Default ResponseThe 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| |------------------|------------------| |10002|The value {0} for parameter {1} is invalid.| |21019|Internal Error.|BodyRoot Schema : errorModelType: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 : errorsNested Schema : itemsType: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:
{ "total": 7, "totalResults": 7, "offset": 0, "limit": 3, "links": [ { "rel": "self", "href": "/ccadminui/v1/promotionTemplates?limit=3" }, { "rel": "next", "href": "/ccadminui/v1/promotionTemplates?limit=3&offset=3" } ], "items": [ { "displayName": "Get Item Discount", "name": "getItemDiscount", "id": "item.getItemDiscount", "type": "item" }, { "displayName": "Buy One Get One", "name": "bogo", "id": "item.bogo", "type": "item" }, { "displayName": "Gift with Item Purchase", "name": "getGiftWithPurchase", "id": "item.getGiftWithPurchase", "type": "item" } ] }