GetLastMileRate
Returns last-mile freight rate estimates for a given origin, destination, service level, and freight details.
All responses are HTTP 200. Check the status field for Success or Error.
Function Overview
- Purpose: Get last-mile freight rate quotes based on origin/destination, service level, line items, and accessorials.
- REST Endpoint:
POST /api/public/v1/rating/GetLastMileRate - SOAP Operation:
GetLastMileRate(LastMileRateRequest) - Authentication: Required -- Bearer token in HTTP Authorization header
REST Interface
Headers
Authorization: Bearer <token>
Content-Type: application/json
Request Body
{
"originZipCode": "75201",
"destinationZipCode": "78701",
"rateDate": "2026-05-08T00:00:00Z",
"serviceLevel": "OHS",
"totalWeight": 500,
"lineItems": [
{
"class": 100,
"weight": 500,
"description": "General Freight",
"pieces": 1,
"length": 48,
"width": 40,
"height": 40
}
],
"accessorials": [
{
"accessorialType": "Liftgate",
"locationType": 1
}
]
}
Request Fields
| Field | Type | Required | Description |
|---|---|---|---|
| originZipCode | string | Yes | Origin ZIP code |
| destinationZipCode | string | Yes | Destination ZIP code |
| rateDate | datetime | No | Date for the rate quote. Defaults to today if omitted or zero. |
| serviceLevel | string | Yes | Service level code (e.g. "OHS") or full name (e.g. "Outside Home - Signature"). See table below. |
| totalWeight | int | No | Total shipment weight in pounds |
| lineItems | array | Yes | At least one line item required. See line item fields below. |
| accessorials | array | No | Optional accessorial charges. See accessorial fields below. |
Line Item Fields
| Field | Type | Description |
|---|---|---|
| class | int | Freight class (e.g. 100, 150, 200) |
| weight | int | Weight in pounds |
| description | string | Item description |
| pieces | int | Number of pieces |
| length | int | Length in inches |
| width | int | Width in inches |
| height | int | Height in inches |
Accessorial Fields
| Field | Type | Description |
|---|---|---|
| accessorialType | string | Accessorial type name (e.g. "Liftgate", "Inside Delivery") |
| locationType | int | 0 = Pickup, 1 = Delivery |
Service Levels
| Code | Full Name |
|---|---|
| OHS | Outside Home - Signature |
| OHN | Outside Home No Signature |
| IHT | In-Home Threshold |
| ROC | Room of Choice |
| ROP | Room of Choice - Remove |
| WGL | White Glove Light Assembly/Disassembly |
| WGC | White Glove Complex Assembly |
Either the code or the full name is accepted.
Response -- Success
{
"status": "Success",
"errors": [],
"rates": [
{
"carrierName": "Test Carrier",
"carrierReference": "TSTC",
"transitDays": 3,
"mileage": 500,
"serviceLevel": "Outside Home - Signature",
"grossCharges": 200.00,
"discount": 10.00,
"netCharges": 220.00,
"fuelSurcharge": 30.00,
"accessorialCharges": 0.00,
"totalCharges": 250.00,
"errorText": "",
"lineItemRates": [
{
"class": 100,
"billedClass": 100,
"weight": 500,
"description": "General Freight",
"pieces": 1,
"ratePer100": 40.00,
"totalLineItemCharge": 200.00
}
],
"accessorials": [
{
"name": "Liftgate",
"location": "Delivery",
"charge": 75.00
}
]
}
]
}
Response -- Error
{
"status": "Error",
"errors": ["OriginZipCode is required.", "At least one LineItem is required."],
"rates": []
}
Response Fields
| Field | Description |
|---|---|
| status | "Success" or "Error" |
| errors | Error messages when status is "Error" |
| rates | Array of rate results. May contain multiple carrier quotes. |
| rates[].carrierName | Carrier display name |
| rates[].carrierReference | Carrier reference code |
| rates[].transitDays | Estimated transit days |
| rates[].mileage | Distance in miles |
| rates[].serviceLevel | Service level on the quote |
| rates[].grossCharges | Pre-discount charges |
| rates[].discount | Discount amount |
| rates[].netCharges | Net charges after discount |
| rates[].fuelSurcharge | Fuel surcharge |
| rates[].accessorialCharges | Total accessorial charges |
| rates[].totalCharges | Total charges (net + fuel + accessorials) |
| rates[].errorText | Carrier-specific error text (empty on clean quote) |
| rates[].lineItemRates | Per-line-item rate breakdown |
| rates[].accessorials | Per-accessorial charge breakdown |
SOAP Interface
WSDL
/soap/public/v1/rating?singlewsdl
Authentication
SOAP uses the same HTTP Authorization: Bearer <token> header as REST. No SOAP security header element.
SOAP Request
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:rat="http://dmwebservices.com/rating/public/v1">
<soapenv:Body>
<rat:GetLastMileRate>
<rat:request>
<rat:OriginZipCode>75201</rat:OriginZipCode>
<rat:DestinationZipCode>78701</rat:DestinationZipCode>
<rat:RateDate>2026-05-08T00:00:00Z</rat:RateDate>
<rat:ServiceLevel>OHS</rat:ServiceLevel>
<rat:TotalWeight>500</rat:TotalWeight>
<rat:LineItems>
<rat:RateLineItem>
<rat:Class>100</rat:Class>
<rat:Weight>500</rat:Weight>
<rat:Description>General Freight</rat:Description>
<rat:Pieces>1</rat:Pieces>
<rat:Length>48</rat:Length>
<rat:Width>40</rat:Width>
<rat:Height>40</rat:Height>
</rat:RateLineItem>
</rat:LineItems>
<rat:Accessorials>
<con:Accessorial xmlns:con="http://dmwebservices.easyfreight.com/contracts/v1">
<con:AccessorialType>Liftgate</con:AccessorialType>
<con:LocationType>1</con:LocationType>
</con:Accessorial>
</rat:Accessorials>
</rat:request>
</rat:GetLastMileRate>
</soapenv:Body>
</soapenv:Envelope>