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": {
    "8b1b9ac8-64ed-45b3-8c32-1509d675d1b9": 2,
    "7e8433b7-ac2b-4f95-a196-db6a5abaea56": 4
  },
  "DeliveryTypeRowGuid": "e31febf0-fd81-49e0-8d3d-a7f031c3c279",
  "Promotions": [
    {
      "RowGuid": "86ca2a20-3bb6-454c-8c6c-58541e735ad3",
      "Name": "sample string 2",
      "CouponCode": "sample string 3",
      "DiscountOnTotalOrderPrice": 4.0
    },
    {
      "RowGuid": "86ca2a20-3bb6-454c-8c6c-58541e735ad3",
      "Name": "sample string 2",
      "CouponCode": "sample string 3",
      "DiscountOnTotalOrderPrice": 4.0
    }
  ],
  "ShowRowGuid": "3a89bb46-c45f-4ce2-b265-03222d509b6f",
  "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>e31febf0-fd81-49e0-8d3d-a7f031c3c279</DeliveryTypeRowGuid>
  <OrderedTickets xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
    <d2p1:KeyValueOfguidint>
      <d2p1:Key>8b1b9ac8-64ed-45b3-8c32-1509d675d1b9</d2p1:Key>
      <d2p1:Value>2</d2p1:Value>
    </d2p1:KeyValueOfguidint>
    <d2p1:KeyValueOfguidint>
      <d2p1:Key>7e8433b7-ac2b-4f95-a196-db6a5abaea56</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>86ca2a20-3bb6-454c-8c6c-58541e735ad3</RowGuid>
    </Promotion>
    <Promotion>
      <CouponCode>sample string 3</CouponCode>
      <DiscountOnTotalOrderPrice>4</DiscountOnTotalOrderPrice>
      <Name>sample string 2</Name>
      <RowGuid>86ca2a20-3bb6-454c-8c6c-58541e735ad3</RowGuid>
    </Promotion>
  </Promotions>
  <ShowRowGuid>3a89bb46-c45f-4ce2-b265-03222d509b6f</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": "ec7620d9-02b9-42db-86b2-76886683ac29",
      "Name": "sample string 2",
      "CouponCode": "sample string 3",
      "DiscountOnTotalOrderPrice": 4.0
    },
    {
      "RowGuid": "ec7620d9-02b9-42db-86b2-76886683ac29",
      "Name": "sample string 2",
      "CouponCode": "sample string 3",
      "DiscountOnTotalOrderPrice": 4.0
    }
  ],
  "Failed": [
    {
      "RowGuid": "ec7620d9-02b9-42db-86b2-76886683ac29",
      "Name": "sample string 2",
      "CouponCode": "sample string 3",
      "DiscountOnTotalOrderPrice": 4.0
    },
    {
      "RowGuid": "ec7620d9-02b9-42db-86b2-76886683ac29",
      "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>ec7620d9-02b9-42db-86b2-76886683ac29</RowGuid>
    </Promotion>
    <Promotion>
      <CouponCode>sample string 3</CouponCode>
      <DiscountOnTotalOrderPrice>4</DiscountOnTotalOrderPrice>
      <Name>sample string 2</Name>
      <RowGuid>ec7620d9-02b9-42db-86b2-76886683ac29</RowGuid>
    </Promotion>
  </Failed>
  <Validated>
    <Promotion>
      <CouponCode>sample string 3</CouponCode>
      <DiscountOnTotalOrderPrice>4</DiscountOnTotalOrderPrice>
      <Name>sample string 2</Name>
      <RowGuid>ec7620d9-02b9-42db-86b2-76886683ac29</RowGuid>
    </Promotion>
    <Promotion>
      <CouponCode>sample string 3</CouponCode>
      <DiscountOnTotalOrderPrice>4</DiscountOnTotalOrderPrice>
      <Name>sample string 2</Name>
      <RowGuid>ec7620d9-02b9-42db-86b2-76886683ac29</RowGuid>
    </Promotion>
  </Validated>
</PromotionValidationResult>