Quote Request API

This section describes the API method to obtain the list of available requests for transportation and warehousing rates. Once the shipping request has been submitted, the request will be sent to our list of authorized forwarders where they may respond with a competitive offer.

Note: The sample requests contained in this document are for reference only. You will not be able to run the examples as is. Please construct your requests based on your authorization token and data requests with your own data values.

Generating the Request

As an example, the following request will return the list of current and available rate requests from third parties. This list contains the requests that are available for a freight forwarder to make a competitive offer.

				// Example Request
curl -v -X GET 'https://www.lclxchange.com/api/quote/request' -H "Content-Type: application/json" -H "Authorization: Bearer <access_token>"

On a successful authentication the resulting array will look something like:

				//Example Result
{
"raterequests": {
"0": {
"index": 4,
"commodityname": "Car Parts",
"requesttype": "Trucking",
"status": "Available",
"origin": "Penang",
"destination": "Hamburg",
"needdate": "2018-12-12 00:00:00",
"notes": "A customer has a need to ship 90cbm of Car Parts to Hamburg. The requested arrival date for the cargo is 12 Dec 2018",
"qty": 100,
"packaging": "Carton",
"measureUnit": "m",
"width": 1.5,
"height": 3,
"length": 0.2,
"massUnit": "kg",
"weight": 26580,
"hazardous": 0
},
"1": {
"index": 3,
"commodityname": "Wine",
"requesttype": "Shipping",
"status": "Available",
"origin": "New York",
"destination": "Hamburg",
"needdate": "2018-12-20 00:00:00",
"notes": "A customer has a need to ship 72cbm of Wine to Hamburg. The requested arrival date for the cargo is 20 Dec 2018",
"qty": 12,
"packaging": "Pallet",
"measureUnit": "m",
"width": 2,
"height": 3,
"length": 1,
"massUnit": "kg",
"weight": 100,
"hazardous": 0
}
}
}

As another example, the request specifying an index will return one request result.

				// Example Request
curl -v -X GET 'https://www.lclxchange.com/api/quote/request' -H "Content-Type: application/json" -H "Authorization: Bearer <access_token>" -d '{ "index" : "<index_value>" }'

On a successful authentication the result will look something like:

				//Example Result
{
"raterequests": {
"0": {
"index": 3,
"commodityname": "Wine",
"requesttype": "Shipping",
"status": "Available",
"origin": "New York",
"destination": "Hamburg",
"needdate": "2018-12-20 00:00:00",
"notes": "A customer has a need to ship 72cbm of Wine to Hamburg. The requested arrival date for the cargo is 20 Dec 2018",
"qty": 12,
"packaging": "Pallet",
"measureUnit": "m",
"width": 2,
"height": 3,
"length": 1,
"massUnit": "kg",
"weight": 100,
"hazardous": 0
}
}
}

Publishing a Request for a Rate

The request API allows the publishing of individual freight rate requests using details about the commodity/cargo and route. In order to accomplish this action, you will need to create a POST request. The following example shows how to publish a freight rate request.

Warning: By submitting a request for a quote, you may receive competitive offers to ship your commodity/cargo. You will not be able to determine who made the offer until you have agreed to the selected rate. At that point the selected forwarder will contact you to formalize the transaction. Use the freight offers API to determine which offer meets your needs.

				//Example Rate Publish
curl -v -X POST 'https://www.lclxchange.com/api/quote/request' -H "Content-Type: application/json" -H "Authorization: Bearer <access_token>" -d '{
"origin": "Hong Kong",
"destination": "Los Angeles",
"arrival": "2019-01-15 17:00:00",
"commodityname": "Brooms",
"requesttype": "Trucking",
"packaging": "pallet",
"refId": "ABCD1234",
"quantity": 2,
"length": 4,
"width": 3,
"height": 1,
"weight": 100,
"hazardous": 0
}'

On a successful authentication and validated arguments, the result will look something like:

				//Example Result
{
"raterequests": {
"0": {
"index": 3,
"commodityname": "Brooms",
"requesttype": "Trucking",
"status": "Available",
"origin": "Hong Kong",
"destination": "Los Angeles",
"needdate": "2019-01-12 00:00:00",
"notes": "A customer has a need to ship 24cbm of Brooms to Los Angeles. The requested arrival date for the commodity is 12 Jan 2019",
"qty": 2,
"packaging": "Pallet",
"measureUnit": "m",
"width": 4,
"height": 1,
"length": 3,
"massUnit": "kg",
"weight": 100,
"hazardous": 0
}
}
}

An error or invalid credentials will return:

				{
    "Unauthorized": "Access denied."
}
				

API REQUEST DETAILS

This section provides information about what is required to generate a rate request using the API. These fields populate the JSON request.

GET POST Component Description
index

The index of the target request

commodityname

The name of the commodity/cargo

requesttype

Type of request (use Shipping, Air Freight, Trucking or Warehousing)

origin

The commodity origin (port or city)

destination

The commodity destination (port or city)

arrival

Estimated Arrival Date (YYYY-MM-DD HH:mm:ss)

packaging

The commodity packaging type, use pallet, carton, or piece

refId

A reference Id for this commodity

quantity

The number (quantity) of commodity packaging types in this request

length

The length of the commodity packaging type in meters

width

The width of the commodity packaging type in meters

height

The height of the commodity packaging type in meters

weight

The weight for the commodity packaging per type in kilograms

hazardous

If the commodity is hazardous (use 0 = No or 1 = Yes)

notes

(Optional) Any notes or details a potential forwarder may need to know

offset

The page offset starting at 0

rowsperpage

The number of results to return per page (default 20), this value must be included with offset

secondsSinceUpdate

The number of seconds since last update. Default 1 hour (3600 seconds, max 432000 seconds)

The URL of the API Services

https://www.lclxchange.com/api/request

Query Parameters

None

HTTP Request Body

A JSON formatted GET or POST request.