GET api/Coupons/Get?BusinessId={BusinessId}&couponType={couponType}

Request Information

URI Parameters

NameDescriptionTypeAdditional information
BusinessId

integer

Required

couponType

integer

Default value is 1

Body Parameters

None.

Response Information

Resource Description

Collection of CouponViewModel
NameDescriptionTypeAdditional information
Coupons

Collection of CouponDetails

None.

Response Formats

application/json, text/json

Sample:
[
  {
    "Coupons": [
      {
        "CouponId": 1,
        "Text": "sample string 2",
        "IconId": 3,
        "IconUrl": "sample string 4"
      },
      {
        "CouponId": 1,
        "Text": "sample string 2",
        "IconId": 3,
        "IconUrl": "sample string 4"
      }
    ]
  },
  {
    "Coupons": [
      {
        "CouponId": 1,
        "Text": "sample string 2",
        "IconId": 3,
        "IconUrl": "sample string 4"
      },
      {
        "CouponId": 1,
        "Text": "sample string 2",
        "IconId": 3,
        "IconUrl": "sample string 4"
      }
    ]
  }
]

application/xml, text/xml

Sample:
<ArrayOfCouponViewModel xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/SpinToWin.Models.ViewModel">
  <CouponViewModel>
    <Coupons>
      <CouponDetails>
        <CouponId>1</CouponId>
        <IconId>3</IconId>
        <IconUrl>sample string 4</IconUrl>
        <Text>sample string 2</Text>
      </CouponDetails>
      <CouponDetails>
        <CouponId>1</CouponId>
        <IconId>3</IconId>
        <IconUrl>sample string 4</IconUrl>
        <Text>sample string 2</Text>
      </CouponDetails>
    </Coupons>
  </CouponViewModel>
  <CouponViewModel>
    <Coupons>
      <CouponDetails>
        <CouponId>1</CouponId>
        <IconId>3</IconId>
        <IconUrl>sample string 4</IconUrl>
        <Text>sample string 2</Text>
      </CouponDetails>
      <CouponDetails>
        <CouponId>1</CouponId>
        <IconId>3</IconId>
        <IconUrl>sample string 4</IconUrl>
        <Text>sample string 2</Text>
      </CouponDetails>
    </Coupons>
  </CouponViewModel>
</ArrayOfCouponViewModel>