POST api/Promotion

Request Information

URI Parameters

None.

Body Parameters

Order
NameDescriptionTypeAdditional information
AddReservationCosts

boolean

None.

OrderedTickets

Dictionary of globally unique identifier [key] and integer [value]

None.

DeliveryTypeRowGuid

globally unique identifier

None.

Promotions

Collection of Promotion

None.

ShowRowGuid

globally unique identifier

None.

TotalWithDiscount

decimal number

None.

Request Formats

application/json, text/json

Sample:
{
  "AddReservationCosts": true,
  "OrderedTickets": {
    "2e5af455-c6de-4900-ac68-4fa2ac4bc461": 2,
    "b4663b98-bf7d-4c40-88e8-fd2558a8b6f0": 4
  },
  "DeliveryTypeRowGuid": "fa47a1d6-31e8-4d8f-a68d-f4349b4b6e66",
  "Promotions": [
    {
      "RowGuid": "41159921-80fc-4549-ac6a-39094250fdf6",
      "Name": "sample string 2",
      "CouponCode": "sample string 3",
      "DiscountOnTotalOrderPrice": 4.0
    },
    {
      "RowGuid": "41159921-80fc-4549-ac6a-39094250fdf6",
      "Name": "sample string 2",
      "CouponCode": "sample string 3",
      "DiscountOnTotalOrderPrice": 4.0
    }
  ],
  "ShowRowGuid": "706bec95-d488-4a91-ab21-1ccc6ddf19a8",
  "TotalWithDiscount": 4.0
}

application/xml, text/xml

Sample:
<Order xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/RoodFluweel.Api.Models">
  <AddReservationCosts>true</AddReservationCosts>
  <DeliveryTypeRowGuid>fa47a1d6-31e8-4d8f-a68d-f4349b4b6e66</DeliveryTypeRowGuid>
  <OrderedTickets xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
    <d2p1:KeyValueOfguidint>
      <d2p1:Key>2e5af455-c6de-4900-ac68-4fa2ac4bc461</d2p1:Key>
      <d2p1:Value>2</d2p1:Value>
    </d2p1:KeyValueOfguidint>
    <d2p1:KeyValueOfguidint>
      <d2p1:Key>b4663b98-bf7d-4c40-88e8-fd2558a8b6f0</d2p1:Key>
      <d2p1:Value>4</d2p1:Value>
    </d2p1:KeyValueOfguidint>
  </OrderedTickets>
  <Promotions>
    <Promotion>
      <CouponCode>sample string 3</CouponCode>
      <DiscountOnTotalOrderPrice>4</DiscountOnTotalOrderPrice>
      <Name>sample string 2</Name>
      <RowGuid>41159921-80fc-4549-ac6a-39094250fdf6</RowGuid>
    </Promotion>
    <Promotion>
      <CouponCode>sample string 3</CouponCode>
      <DiscountOnTotalOrderPrice>4</DiscountOnTotalOrderPrice>
      <Name>sample string 2</Name>
      <RowGuid>41159921-80fc-4549-ac6a-39094250fdf6</RowGuid>
    </Promotion>
  </Promotions>
  <ShowRowGuid>706bec95-d488-4a91-ab21-1ccc6ddf19a8</ShowRowGuid>
  <TotalWithDiscount>4</TotalWithDiscount>
</Order>

application/x-www-form-urlencoded

Sample:

Sample not available.

Response Information

Resource Description

PromotionValidationResult
NameDescriptionTypeAdditional information
Validated

Collection of Promotion

None.

Failed

Collection of Promotion

None.

Response Formats

application/json, text/json

Sample:
{
  "Validated": [
    {
      "RowGuid": "d0ca4232-763d-4f09-900e-7935a7b67644",
      "Name": "sample string 2",
      "CouponCode": "sample string 3",
      "DiscountOnTotalOrderPrice": 4.0
    },
    {
      "RowGuid": "d0ca4232-763d-4f09-900e-7935a7b67644",
      "Name": "sample string 2",
      "CouponCode": "sample string 3",
      "DiscountOnTotalOrderPrice": 4.0
    }
  ],
  "Failed": [
    {
      "RowGuid": "d0ca4232-763d-4f09-900e-7935a7b67644",
      "Name": "sample string 2",
      "CouponCode": "sample string 3",
      "DiscountOnTotalOrderPrice": 4.0
    },
    {
      "RowGuid": "d0ca4232-763d-4f09-900e-7935a7b67644",
      "Name": "sample string 2",
      "CouponCode": "sample string 3",
      "DiscountOnTotalOrderPrice": 4.0
    }
  ]
}

application/xml, text/xml

Sample:
<PromotionValidationResult xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/RoodFluweel.Api.Models">
  <Failed>
    <Promotion>
      <CouponCode>sample string 3</CouponCode>
      <DiscountOnTotalOrderPrice>4</DiscountOnTotalOrderPrice>
      <Name>sample string 2</Name>
      <RowGuid>d0ca4232-763d-4f09-900e-7935a7b67644</RowGuid>
    </Promotion>
    <Promotion>
      <CouponCode>sample string 3</CouponCode>
      <DiscountOnTotalOrderPrice>4</DiscountOnTotalOrderPrice>
      <Name>sample string 2</Name>
      <RowGuid>d0ca4232-763d-4f09-900e-7935a7b67644</RowGuid>
    </Promotion>
  </Failed>
  <Validated>
    <Promotion>
      <CouponCode>sample string 3</CouponCode>
      <DiscountOnTotalOrderPrice>4</DiscountOnTotalOrderPrice>
      <Name>sample string 2</Name>
      <RowGuid>d0ca4232-763d-4f09-900e-7935a7b67644</RowGuid>
    </Promotion>
    <Promotion>
      <CouponCode>sample string 3</CouponCode>
      <DiscountOnTotalOrderPrice>4</DiscountOnTotalOrderPrice>
      <Name>sample string 2</Name>
      <RowGuid>d0ca4232-763d-4f09-900e-7935a7b67644</RowGuid>
    </Promotion>
  </Validated>
</PromotionValidationResult>