POST api/discount/updatediscount

Request Information

URI Parameters

None.

Body Parameters

Discount
NameDescriptionTypeAdditional information
DiscountId

integer

None.

DiscountTitle

string

None.

FromDate

date

None.

ToDate

date

None.

IsFixed

byte

None.

DiscountValue

decimal number

None.

ApplyTo

string

None.

ApplicableTo

string

None.

ApplicableDate

string

None.

DiscountResorts

Collection of DiscountResort

None.

DiscountMembershipTypeMasters

Collection of DiscountMembershipTypeMaster

None.

CreatedDate

date

None.

ModifiedDate

date

None.

CreatedBy

integer

None.

ModifiedBy

integer

None.

IsActive

boolean

None.

IsDeleted

boolean

None.

Request Formats

application/json, text/json

Sample:
{
  "DiscountId": 1,
  "DiscountTitle": "sample string 2",
  "FromDate": "2025-06-24T13:52:49.6864693+00:00",
  "ToDate": "2025-06-24T13:52:49.6864693+00:00",
  "IsFixed": 64,
  "DiscountValue": 1.0,
  "ApplyTo": "sample string 6",
  "ApplicableTo": "sample string 7",
  "ApplicableDate": "sample string 8",
  "DiscountResorts": [
    {
      "DiscountResortId": 1,
      "DiscountId": 2,
      "ResortId": 3,
      "IsChecked": true,
      "ResortName": "sample string 5",
      "CreatedDate": "2025-06-24T13:52:49.6864693+00:00",
      "ModifiedDate": "2025-06-24T13:52:49.6864693+00:00",
      "CreatedBy": 1,
      "ModifiedBy": 1,
      "IsActive": true,
      "IsDeleted": true
    },
    {
      "DiscountResortId": 1,
      "DiscountId": 2,
      "ResortId": 3,
      "IsChecked": true,
      "ResortName": "sample string 5",
      "CreatedDate": "2025-06-24T13:52:49.6864693+00:00",
      "ModifiedDate": "2025-06-24T13:52:49.6864693+00:00",
      "CreatedBy": 1,
      "ModifiedBy": 1,
      "IsActive": true,
      "IsDeleted": true
    }
  ],
  "DiscountMembershipTypeMasters": [
    {
      "DiscountMembershipTypeMasterId": 1,
      "DiscountId": 2,
      "MembershipTypeMasterId": 3,
      "IsChecked": true,
      "MembershipType": "sample string 5",
      "CreatedDate": "2025-06-24T13:52:49.6864693+00:00",
      "ModifiedDate": "2025-06-24T13:52:49.6864693+00:00",
      "CreatedBy": 1,
      "ModifiedBy": 1,
      "IsActive": true,
      "IsDeleted": true
    },
    {
      "DiscountMembershipTypeMasterId": 1,
      "DiscountId": 2,
      "MembershipTypeMasterId": 3,
      "IsChecked": true,
      "MembershipType": "sample string 5",
      "CreatedDate": "2025-06-24T13:52:49.6864693+00:00",
      "ModifiedDate": "2025-06-24T13:52:49.6864693+00:00",
      "CreatedBy": 1,
      "ModifiedBy": 1,
      "IsActive": true,
      "IsDeleted": true
    }
  ],
  "CreatedDate": "2025-06-24T13:52:49.6864693+00:00",
  "ModifiedDate": "2025-06-24T13:52:49.6864693+00:00",
  "CreatedBy": 1,
  "ModifiedBy": 1,
  "IsActive": true,
  "IsDeleted": true
}

text/html

Sample:
{"DiscountId":1,"DiscountTitle":"sample string 2","FromDate":"2025-06-24T13:52:49.6864693+00:00","ToDate":"2025-06-24T13:52:49.6864693+00:00","IsFixed":64,"DiscountValue":1.0,"ApplyTo":"sample string 6","ApplicableTo":"sample string 7","ApplicableDate":"sample string 8","DiscountResorts":[{"DiscountResortId":1,"DiscountId":2,"ResortId":3,"IsChecked":true,"ResortName":"sample string 5","CreatedDate":"2025-06-24T13:52:49.6864693+00:00","ModifiedDate":"2025-06-24T13:52:49.6864693+00:00","CreatedBy":1,"ModifiedBy":1,"IsActive":true,"IsDeleted":true},{"DiscountResortId":1,"DiscountId":2,"ResortId":3,"IsChecked":true,"ResortName":"sample string 5","CreatedDate":"2025-06-24T13:52:49.6864693+00:00","ModifiedDate":"2025-06-24T13:52:49.6864693+00:00","CreatedBy":1,"ModifiedBy":1,"IsActive":true,"IsDeleted":true}],"DiscountMembershipTypeMasters":[{"DiscountMembershipTypeMasterId":1,"DiscountId":2,"MembershipTypeMasterId":3,"IsChecked":true,"MembershipType":"sample string 5","CreatedDate":"2025-06-24T13:52:49.6864693+00:00","ModifiedDate":"2025-06-24T13:52:49.6864693+00:00","CreatedBy":1,"ModifiedBy":1,"IsActive":true,"IsDeleted":true},{"DiscountMembershipTypeMasterId":1,"DiscountId":2,"MembershipTypeMasterId":3,"IsChecked":true,"MembershipType":"sample string 5","CreatedDate":"2025-06-24T13:52:49.6864693+00:00","ModifiedDate":"2025-06-24T13:52:49.6864693+00:00","CreatedBy":1,"ModifiedBy":1,"IsActive":true,"IsDeleted":true}],"CreatedDate":"2025-06-24T13:52:49.6864693+00:00","ModifiedDate":"2025-06-24T13:52:49.6864693+00:00","CreatedBy":1,"ModifiedBy":1,"IsActive":true,"IsDeleted":true}

application/xml, text/xml

Sample:
<Discount xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/SRG.Core">
  <CreatedBy>1</CreatedBy>
  <CreatedDate>2025-06-24T13:52:49.6864693+00:00</CreatedDate>
  <IsActive>true</IsActive>
  <IsDeleted>true</IsDeleted>
  <ModifiedBy>1</ModifiedBy>
  <ModifiedDate>2025-06-24T13:52:49.6864693+00:00</ModifiedDate>
  <ApplicableDate>sample string 8</ApplicableDate>
  <ApplicableTo>sample string 7</ApplicableTo>
  <ApplyTo>sample string 6</ApplyTo>
  <DiscountId>1</DiscountId>
  <DiscountMembershipTypeMasters>
    <DiscountMembershipTypeMaster>
      <CreatedBy>1</CreatedBy>
      <CreatedDate>2025-06-24T13:52:49.6864693+00:00</CreatedDate>
      <IsActive>true</IsActive>
      <IsDeleted>true</IsDeleted>
      <ModifiedBy>1</ModifiedBy>
      <ModifiedDate>2025-06-24T13:52:49.6864693+00:00</ModifiedDate>
      <DiscountId>2</DiscountId>
      <DiscountMembershipTypeMasterId>1</DiscountMembershipTypeMasterId>
      <IsChecked>true</IsChecked>
      <MembershipType>sample string 5</MembershipType>
      <MembershipTypeMasterId>3</MembershipTypeMasterId>
    </DiscountMembershipTypeMaster>
    <DiscountMembershipTypeMaster>
      <CreatedBy>1</CreatedBy>
      <CreatedDate>2025-06-24T13:52:49.6864693+00:00</CreatedDate>
      <IsActive>true</IsActive>
      <IsDeleted>true</IsDeleted>
      <ModifiedBy>1</ModifiedBy>
      <ModifiedDate>2025-06-24T13:52:49.6864693+00:00</ModifiedDate>
      <DiscountId>2</DiscountId>
      <DiscountMembershipTypeMasterId>1</DiscountMembershipTypeMasterId>
      <IsChecked>true</IsChecked>
      <MembershipType>sample string 5</MembershipType>
      <MembershipTypeMasterId>3</MembershipTypeMasterId>
    </DiscountMembershipTypeMaster>
  </DiscountMembershipTypeMasters>
  <DiscountResorts>
    <DiscountResort>
      <CreatedBy>1</CreatedBy>
      <CreatedDate>2025-06-24T13:52:49.6864693+00:00</CreatedDate>
      <IsActive>true</IsActive>
      <IsDeleted>true</IsDeleted>
      <ModifiedBy>1</ModifiedBy>
      <ModifiedDate>2025-06-24T13:52:49.6864693+00:00</ModifiedDate>
      <DiscountId>2</DiscountId>
      <DiscountResortId>1</DiscountResortId>
      <IsChecked>true</IsChecked>
      <ResortId>3</ResortId>
      <ResortName>sample string 5</ResortName>
    </DiscountResort>
    <DiscountResort>
      <CreatedBy>1</CreatedBy>
      <CreatedDate>2025-06-24T13:52:49.6864693+00:00</CreatedDate>
      <IsActive>true</IsActive>
      <IsDeleted>true</IsDeleted>
      <ModifiedBy>1</ModifiedBy>
      <ModifiedDate>2025-06-24T13:52:49.6864693+00:00</ModifiedDate>
      <DiscountId>2</DiscountId>
      <DiscountResortId>1</DiscountResortId>
      <IsChecked>true</IsChecked>
      <ResortId>3</ResortId>
      <ResortName>sample string 5</ResortName>
    </DiscountResort>
  </DiscountResorts>
  <DiscountTitle>sample string 2</DiscountTitle>
  <DiscountValue>1</DiscountValue>
  <FromDate>2025-06-24T13:52:49.6864693+00:00</FromDate>
  <IsFixed>64</IsFixed>
  <ToDate>2025-06-24T13:52:49.6864693+00:00</ToDate>
</Discount>

application/x-www-form-urlencoded

Sample:

Failed to generate the sample for media type 'application/x-www-form-urlencoded'. Cannot use formatter 'JQueryMvcFormUrlEncodedFormatter' to write type 'Discount'.

Response Information

Resource Description

IHttpActionResult

None.

Response Formats

application/json, text/json, text/html, application/xml, text/xml

Sample:

Sample not available.