Returning a List of Eligible Products in a Promotion
You use this Siebel REST API to check which products are eligible from a list of products before adding or replacing a component that belongs to a promotion aggregate rule, in an already existing promotion instance, in a quote, or in an order.
The following request returns a list of products that belong to a promotion aggregate rule, while checking eligibility on the list of products:
-
URI: http://ServerName:port/siebel/v1.0/service/ISS Promotion Management Service/GetEligibleComponents
-
HTTP Method: POST
-
Content-Type: application/json
-
Authorization: Basic
-
Request body:
{ "body": { "Rule Id": "88-1VTT1C", "EligibilityMode": "1", "Context": { "IntObjectFormat": "Siebel Hierarchical", "MessageId": "88-21EYX", "IntObjectName": "PDS Catalog Context", "MessageType": "Integration Object", "ListOfPDS Catalog Context": { "Context": { "ListOfExternal Context": { "External Context": { "Account Id": "88-1VTT1D" } } } } } } }
For a description of the request message associated with this API, see the following table.
| Name | Description |
|---|---|
|
Rule Id |
Required. Promotion rule ID for which we need to get all the list of products that can be associated. An option to obtain the Rule Id is to use GetPromotionDetails REST API. The Integration Id of the Promotion Items for Import section is the Rule Id. |
|
Eligibility Mode |
Optional. Valid values are 0, 1, or 2.
|
|
External Context |
Optional. Specifies the context for running the eligibility procedure, for example passing standard eligibility criteria, such as Account Id, Account Type, and so on. |
Here are the response details for a successful request:
-
HTTP Code: 200
-
Content-Type: application/json
-
Response body:
{ "SiebelMessage": { "PARSEIONAME": "ISS Promotion Related Product Data", "IntObjectFormat": "Siebel Hierarchical", "MessageId": "", "Integration Object": "ISS Promotion Related Product Data", "MessageType": "Integration Object", "ISS Promotion Related Product Data": [ { "Name": "HLine2Prod1", "Id": "88-1VTSZV", "Pre Pick": "Y", "Eligibility Reason": "This product is not sold to: [Account] = HAccLine2", "Class Id": "", "Description": "", "Product Line Id": "88-1VTSZU", "Eligibility Status": "N" }, { "Name": "HLine2Prod2", "Id": "88-1VTT0H", "Pre Pick": "Y", "Eligibility Reason": "", "Class Id": "", "Description": "", "Product Line Id": "88-1VTSZU", "Eligibility Status": "Y" } ] } }