GET api/Orders/customer/{userId}/CalculateTotalOnGivenQuantity/{pid}?quantity={quantity}&isReorder={isReorder}&taxRate={taxRate}
Calculate tax, subtotal, total on given quantity
Request Information
URI Parameters
| Name | Description | Type | Additional information |
|---|---|---|---|
| pid |
Product ID. |
integer |
Required |
| quantity |
Quantity |
integer |
Required |
| isReorder |
isReorder |
boolean |
Default value is False |
| taxRate |
Tax rate |
decimal number |
None. |
| userId | string |
None. |
Body Parameters
None.
Response Information
Resource Description
CalculateResultViewModel| Name | Description | Type | Additional information |
|---|---|---|---|
| UnitPrice | decimal number |
None. |
|
| ToolingCharges | decimal number |
None. |
|
| ProductionCharge | decimal number |
None. |
|
| SalesTax | decimal number |
None. |
|
| Subtotal | decimal number |
None. |
|
| Total | decimal number |
None. |
|
| TaxRate | decimal number |
None. |
|
| TaxRatePercentage | string |
None. |
Response Formats
application/json, text/json
Sample:
{
"unitPrice": 1.0,
"toolingCharges": 1.0,
"productionCharge": 2.0,
"salesTax": 1.0,
"subtotal": 3.0,
"total": 4.0,
"taxRate": 1.1,
"taxRatePercentage": "sample string 5"
}