PUT api/v7/TaxRules

Add or Update an existing tax rule.

Tables Impacted

TaxRule, TaxRuleDetail

Request Information

URI Parameters

None.

Body Parameters

the tax rule information

TaxRuleDto
NameDescriptionTypeRequired?Additional information
taxRuleCode *

tax Rule code

string

Yes

String length: between 1 and 16, inclusive

startDate *

start date

date

Yes

None.

endDate

end date

date

No

None.

isTaxHoliday

indicate if it is tax holiday

boolean

No

None.

thresholdMethod

threasholdmethod

integer

No

None.

thresholdAmount

thresholdAmount

decimal number

No

None.

returnTaxDays

return tax days.

integer

No

None.

customerAuditDate

Audit information

date

No

None.

Request Formats

application/json, text/json

Sample:
{
  "taxRuleCode": "1",
  "startDate": "2010-01-01T12:00:00",
  "isTaxHoliday": true,
  "thresholdMethod": 1,
  "thresholdAmount": 1000.0,
  "returnTaxDays": 30,
  "customerAuditDate": "2018-01-01T00:00:00"
}

application/xml, text/xml

Sample:
<TaxRuleDto xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
  <taxRuleCode>1</taxRuleCode>
  <startDate>2010-01-01T12:00:00</startDate>
  <endDate xsi:nil="true" />
  <isTaxHoliday>true</isTaxHoliday>
  <thresholdMethod>1</thresholdMethod>
  <thresholdAmount>1000.0</thresholdAmount>
  <returnTaxDays>30</returnTaxDays>
  <customerAuditDate>2018-01-01T00:00:00</customerAuditDate>
</TaxRuleDto>

Response Information

Resource Description

Returns a HTTPResponse Message stating the success/failure of API Action

HttpResponseMessage
NameDescriptionType
Version

Version
Content

HttpContent
StatusCode

HttpStatusCode
ReasonPhrase

string
Headers

Collection of Object
RequestMessage

HttpRequestMessage
IsSuccessStatusCode

boolean

Response Formats

application/json, text/json

Sample:
{
  "message": "Record successfully saved.",
  "propertyName": "Success"
}

application/xml, text/xml

Sample:
<ApiValidationMessage xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
  <message>Record successfully saved.</message>
  <propertyName>Success</propertyName>
</ApiValidationMessage>