POST Booking/PostCalculateExtraCharges
Looks for extra charges for specified location, customer(s) and product(s) then returns the new product(s) that could be added to a booking.
Request Information
URI Parameters
Body Parameters
The customer/products object used to calculate extra charges.
ClsCalculateExtraCharges| Name | Description | Type | Additional Information |
|---|---|---|---|
| LocationId |
The ID of the location where the booking will be created. |
string |
Required Max length: 6 |
| BookDetails |
Where the user can add details to calculate extra charges. |
Collection of ClsBookDetails |
List cannot be empty |
Request Formats
application/json, text/json
Sample:
{
"LocationId": "sample string 1",
"BookDetails": [
{
"CustomerId": "sample string 1",
"ProductDetails": [
{
"DepartmentId": "sample string 1",
"ProductId": "sample string 2",
"UnitPrice": 3.1,
"Quantity": 4.1
},
{
"DepartmentId": "sample string 1",
"ProductId": "sample string 2",
"UnitPrice": 3.1,
"Quantity": 4.1
}
]
},
{
"CustomerId": "sample string 1",
"ProductDetails": [
{
"DepartmentId": "sample string 1",
"ProductId": "sample string 2",
"UnitPrice": 3.1,
"Quantity": 4.1
},
{
"DepartmentId": "sample string 1",
"ProductId": "sample string 2",
"UnitPrice": 3.1,
"Quantity": 4.1
}
]
}
]
}
application/xml, text/xml
Sample:
<CalculateExtraCharges xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/SSI.AR">
<BookDetails>
<ClsBookAPI.ClsCalculateExtraCharges.ClsBookDetails>
<CustomerId>sample string 1</CustomerId>
<ProductDetails>
<ClsBookAPI.ClsCalculateExtraCharges.ClsProductDetails>
<DepartmentId>sample string 1</DepartmentId>
<ProductId>sample string 2</ProductId>
<Quantity>4.1</Quantity>
<UnitPrice>3.1</UnitPrice>
</ClsBookAPI.ClsCalculateExtraCharges.ClsProductDetails>
<ClsBookAPI.ClsCalculateExtraCharges.ClsProductDetails>
<DepartmentId>sample string 1</DepartmentId>
<ProductId>sample string 2</ProductId>
<Quantity>4.1</Quantity>
<UnitPrice>3.1</UnitPrice>
</ClsBookAPI.ClsCalculateExtraCharges.ClsProductDetails>
</ProductDetails>
</ClsBookAPI.ClsCalculateExtraCharges.ClsBookDetails>
<ClsBookAPI.ClsCalculateExtraCharges.ClsBookDetails>
<CustomerId>sample string 1</CustomerId>
<ProductDetails>
<ClsBookAPI.ClsCalculateExtraCharges.ClsProductDetails>
<DepartmentId>sample string 1</DepartmentId>
<ProductId>sample string 2</ProductId>
<Quantity>4.1</Quantity>
<UnitPrice>3.1</UnitPrice>
</ClsBookAPI.ClsCalculateExtraCharges.ClsProductDetails>
<ClsBookAPI.ClsCalculateExtraCharges.ClsProductDetails>
<DepartmentId>sample string 1</DepartmentId>
<ProductId>sample string 2</ProductId>
<Quantity>4.1</Quantity>
<UnitPrice>3.1</UnitPrice>
</ClsBookAPI.ClsCalculateExtraCharges.ClsProductDetails>
</ProductDetails>
</ClsBookAPI.ClsCalculateExtraCharges.ClsBookDetails>
</BookDetails>
<LocationId>sample string 1</LocationId>
</CalculateExtraCharges>
application/x-www-form-urlencoded
Sample:
Response Information
Resource Description
Looks for extra charges for specified location, customer(s) and product(s) then returns the new product(s) that could be added to a booking.
AgvCalculateExtraCharges| Name | Description | Type | Additional Information |
|---|---|---|---|
| Status |
Status of the API call. |
string | |
| Message |
Message of the API call. |
string | |
| ErrorList |
List of error messages of the API call. |
Collection of string | |
| NewBookDetails |
JSON dictionary of BookRecords. |
Collection of ClsNewBookDetails |
Response Formats
application/json, text/json
Sample:
{
"Status": "sample string 1",
"Message": "sample string 2",
"ErrorList": [
"sample string 1",
"sample string 2"
],
"NewBookDetails": [
{
"CustomerId": "sample string 1",
"ProductDetails": [
{
"ExtraChargeId": "sample string 1",
"DepartmentId": "sample string 2",
"ProductId": "sample string 3",
"UnitPrice": 4.1,
"Quantity": 5.1
},
{
"ExtraChargeId": "sample string 1",
"DepartmentId": "sample string 2",
"ProductId": "sample string 3",
"UnitPrice": 4.1,
"Quantity": 5.1
}
]
},
{
"CustomerId": "sample string 1",
"ProductDetails": [
{
"ExtraChargeId": "sample string 1",
"DepartmentId": "sample string 2",
"ProductId": "sample string 3",
"UnitPrice": 4.1,
"Quantity": 5.1
},
{
"ExtraChargeId": "sample string 1",
"DepartmentId": "sample string 2",
"ProductId": "sample string 3",
"UnitPrice": 4.1,
"Quantity": 5.1
}
]
}
]
}
application/xml, text/xml
Sample:
<AgvCalculateExtraCharges xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/AgvWebAPICSharp.Models.Booking">
<ErrorList xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
<d2p1:string>sample string 1</d2p1:string>
<d2p1:string>sample string 2</d2p1:string>
</ErrorList>
<Message>sample string 2</Message>
<NewBookDetails xmlns:d2p1="http://schemas.datacontract.org/2004/07/SSI.AR">
<d2p1:ClsBookAPI.ClsCalculateExtraCharges.ClsNewBookDetails>
<d2p1:CustomerId>sample string 1</d2p1:CustomerId>
<d2p1:ProductDetails>
<d2p1:ClsBookAPI.ClsCalculateExtraCharges.ClsNewProductDetails>
<d2p1:DepartmentId>sample string 2</d2p1:DepartmentId>
<d2p1:ProductId>sample string 3</d2p1:ProductId>
<d2p1:Quantity>5.1</d2p1:Quantity>
<d2p1:UnitPrice>4.1</d2p1:UnitPrice>
<d2p1:ExtraChargeId>sample string 1</d2p1:ExtraChargeId>
</d2p1:ClsBookAPI.ClsCalculateExtraCharges.ClsNewProductDetails>
<d2p1:ClsBookAPI.ClsCalculateExtraCharges.ClsNewProductDetails>
<d2p1:DepartmentId>sample string 2</d2p1:DepartmentId>
<d2p1:ProductId>sample string 3</d2p1:ProductId>
<d2p1:Quantity>5.1</d2p1:Quantity>
<d2p1:UnitPrice>4.1</d2p1:UnitPrice>
<d2p1:ExtraChargeId>sample string 1</d2p1:ExtraChargeId>
</d2p1:ClsBookAPI.ClsCalculateExtraCharges.ClsNewProductDetails>
</d2p1:ProductDetails>
</d2p1:ClsBookAPI.ClsCalculateExtraCharges.ClsNewBookDetails>
<d2p1:ClsBookAPI.ClsCalculateExtraCharges.ClsNewBookDetails>
<d2p1:CustomerId>sample string 1</d2p1:CustomerId>
<d2p1:ProductDetails>
<d2p1:ClsBookAPI.ClsCalculateExtraCharges.ClsNewProductDetails>
<d2p1:DepartmentId>sample string 2</d2p1:DepartmentId>
<d2p1:ProductId>sample string 3</d2p1:ProductId>
<d2p1:Quantity>5.1</d2p1:Quantity>
<d2p1:UnitPrice>4.1</d2p1:UnitPrice>
<d2p1:ExtraChargeId>sample string 1</d2p1:ExtraChargeId>
</d2p1:ClsBookAPI.ClsCalculateExtraCharges.ClsNewProductDetails>
<d2p1:ClsBookAPI.ClsCalculateExtraCharges.ClsNewProductDetails>
<d2p1:DepartmentId>sample string 2</d2p1:DepartmentId>
<d2p1:ProductId>sample string 3</d2p1:ProductId>
<d2p1:Quantity>5.1</d2p1:Quantity>
<d2p1:UnitPrice>4.1</d2p1:UnitPrice>
<d2p1:ExtraChargeId>sample string 1</d2p1:ExtraChargeId>
</d2p1:ClsBookAPI.ClsCalculateExtraCharges.ClsNewProductDetails>
</d2p1:ProductDetails>
</d2p1:ClsBookAPI.ClsCalculateExtraCharges.ClsNewBookDetails>
</NewBookDetails>
<Status>sample string 1</Status>
</AgvCalculateExtraCharges>