POST api/cheque/RuleForCheque
Получение информации о правилах на покупки и правилах на события, которые сработали в чек, по идентификатору чека
Request Information
URI Parameters
None.
Body Parameters
RuleForChequeRequestName | Description | Type | Additional information |
---|---|---|---|
ChequeId |
Тип действия |
integer |
None. |
Operator |
Идентификатор оператора программы лояльности |
integer |
None. |
Token |
Токен пользователя, который инициирует данный запрос |
integer |
None. |
SiteCode |
Уникальный код виджета по продаже подарочных сертификатов, который инициирует запрос |
string |
None. |
Request Formats
application/json, text/json
Sample:
{ "ChequeId": 1, "Operator": 1, "Token": 1, "SiteCode": "sample string 1" }
application/xml, text/xml
Sample:
<RuleForChequeRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/LCManagerPartner.Implementation.Request.ChequeRequest"> <Operator xmlns="http://schemas.datacontract.org/2004/07/LCManagerPartner.Implementation.Abstractions">1</Operator> <SiteCode xmlns="http://schemas.datacontract.org/2004/07/LCManagerPartner.Implementation.Abstractions">sample string 1</SiteCode> <Token xmlns="http://schemas.datacontract.org/2004/07/LCManagerPartner.Implementation.Abstractions">1</Token> <ChequeId>1</ChequeId> </RuleForChequeRequest>
application/x-www-form-urlencoded
Sample:
Sample not available.
Response Information
Resource Description
RuleForChequeResponseName | Description | Type | Additional information |
---|---|---|---|
ChequeRules |
Массив правил на покупки |
Collection of RuleForChequeChequeRuleRow |
None. |
EventRules |
Массив правил на события |
Collection of RuleForChequeEventRuleRow |
None. |
ErrorCode |
Код ошибки |
integer |
None. |
Message |
Сообщение об ошибке |
string |
None. |
Response Formats
application/json, text/json
Sample:
{ "ChequeRules": [ { "Id": 1, "ChequeId": 1, "Item": 1, "ItemName": "sample string 1", "Bonus": 1.0, "ChequeRule": 1, "ChequeRuleName": "sample string 2", "ChequeRuleTypeName": "sample string 3" }, { "Id": 1, "ChequeId": 1, "Item": 1, "ItemName": "sample string 1", "Bonus": 1.0, "ChequeRule": 1, "ChequeRuleName": "sample string 2", "ChequeRuleTypeName": "sample string 3" } ], "EventRules": [ { "Id": 1, "ChequeId": 1, "EventRule": 1, "EventRuleName": "sample string 1", "EventRuleTypeName": "sample string 2", "Bonus": 1.0 }, { "Id": 1, "ChequeId": 1, "EventRule": 1, "EventRuleName": "sample string 1", "EventRuleTypeName": "sample string 2", "Bonus": 1.0 } ], "ErrorCode": 1, "Message": "sample string 2" }
application/xml, text/xml
Sample:
<RuleForChequeResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/LCManagerPartner.Implementation.Response.ChequeResponse"> <ErrorCode xmlns="http://schemas.datacontract.org/2004/07/LCManagerPartner.Implementation.Abstractions">1</ErrorCode> <Message xmlns="http://schemas.datacontract.org/2004/07/LCManagerPartner.Implementation.Abstractions">sample string 2</Message> <ChequeRules> <RuleForChequeResponse.RuleForChequeChequeRuleRow> <Bonus>1</Bonus> <ChequeId>1</ChequeId> <ChequeRule>1</ChequeRule> <ChequeRuleName>sample string 2</ChequeRuleName> <ChequeRuleTypeName>sample string 3</ChequeRuleTypeName> <Id>1</Id> <Item>1</Item> <ItemName>sample string 1</ItemName> </RuleForChequeResponse.RuleForChequeChequeRuleRow> <RuleForChequeResponse.RuleForChequeChequeRuleRow> <Bonus>1</Bonus> <ChequeId>1</ChequeId> <ChequeRule>1</ChequeRule> <ChequeRuleName>sample string 2</ChequeRuleName> <ChequeRuleTypeName>sample string 3</ChequeRuleTypeName> <Id>1</Id> <Item>1</Item> <ItemName>sample string 1</ItemName> </RuleForChequeResponse.RuleForChequeChequeRuleRow> </ChequeRules> <EventRules> <RuleForChequeResponse.RuleForChequeEventRuleRow> <Bonus>1</Bonus> <ChequeId>1</ChequeId> <EventRule>1</EventRule> <EventRuleName>sample string 1</EventRuleName> <EventRuleTypeName>sample string 2</EventRuleTypeName> <Id>1</Id> </RuleForChequeResponse.RuleForChequeEventRuleRow> <RuleForChequeResponse.RuleForChequeEventRuleRow> <Bonus>1</Bonus> <ChequeId>1</ChequeId> <EventRule>1</EventRule> <EventRuleName>sample string 1</EventRuleName> <EventRuleTypeName>sample string 2</EventRuleTypeName> <Id>1</Id> </RuleForChequeResponse.RuleForChequeEventRuleRow> </EventRules> </RuleForChequeResponse>