Shipping Tools & Developer Guide

Quote


Get a parcel delivery quote

Obtain a parcel delivery quote from a collection address to a delivery address, optionally filtered by carrier, service or type.

Endpoint

POST
https://api.interparcel.com/quote

Request Headers

NameTypeRequiredExampleDescription
AcceptStringtrueapplication/jsonRequest the content in the correct format
Content-TypeStringtrueapplication/jsonEnsure the content sent is in the correct format
X-Interparcel-AuthStringtrueYOUR_API_KEYYour API Key provided by Interparcel
X-Interparcel-API-VersionStringtrue3The latest API version

Request Body

  • collection
    • city
    • state
    • postcode
    • country
  • delivery
    • city
    • state
    • postcode
    • country
  • filter
  • parcels
    • weight
    • length
    • width
    • height

Example Request - Minimum

This is the minimum data required to get a quote

{
	"collection": {
		"city": "Crawley",
		"postcode": "RH10 9RD",
		"country": "UK"
	},
	"delivery": {
		"city": "Cergy",
		"postcode": "75001",
		"country": "France"
	},
	"parcels": [
		{
			"weight": 2,
			"length": 5,
			"width": 10,
			"height": 12
		}
	]
}

Example Request - All Filters

All filters have been populated. You wouldn't normally use them all at the same time.

{
	"collection": {
		"city": "Crawley",
		"state": "West Sussex",
		"postcode": "RH10 9RD",
		"country": "UK"
	},
	"delivery": {
		"city": "Brighton",
		"state": "Sussex",
		"postcode": "RH10 9RD",
		"country": "UK"
	},
	"filter": {
		"serviceLevel": [
			"express",
			"timed"
		],
		"carriers": [
			"DX",
			"Parcelforce"
		],
		"services": [
			"DX Express",
			"Parcelforce"
		],
		"pickupType": [
			"collection",
			"dropoff"
		]		
	},
	"parcels": [
		{
			"weight": 2,
			"length": 5,
			"width": 10,
			"height": 12
		},
		{
			"weight": 3,
			"length": 4,
			"width": 16,
			"height": 7
		}
	]
}

Example Responses

Success
{
    "status": 0,
    "services": [
        {
            "id": "DXEXP",
            "carrier": "DX",
            "name": "Express",
            "service": "DX Express",
            "serviceLevel": "express",
            "price": 17.99,
            "currency": "GBP",
            "taxable": true,
            "includedCover": 20,
            "maxCover": 1000,
            "printerNeeded": false,
            "restrictions": {
                "maximumWeight": 20,
                "maximumLength": 95
            },
            "pickupType": "collection",
            "delivery": {
                "daysFrom": 0,
                "daysTo": 0
            }
        }
    ]
}
Success - No services found
{
    "status": 0,
    "services": []
}
Error - Invalid Collection Country
{
    "status": 1,
    "errorMessage": "Invalid collection country",
    "errorCode": "100001"
}

Definitions

Body

NameTypeRequiredDescription
collectionAddress ObjecttrueCollection address
deliveryAddress ObjecttrueDelivery address
filterFilter ObjectfalseFilter the quote results
parcelsParcels Array of ObjectstrueParcel details

Address

NameTypeRequiredDescription
cityStringtrueTown / City
stateStringconditionalState
postcodeStringtruePostcode
countryStringtrueCountry

Filter

NameTypeRequiredDescription
serviceLevelArrayfalseOne or more Service Levels
carriersArrayfalseOne or more carriers
servicesArrayfalseOne ore more service codes
pickupTypeArrayfalseOne or more Pickup Types

Parcels

NameTypeRequiredDescription
weightDecimaltrueParcel weight in kg
lengthIntegertrueParcel length in cm
widthIntegertrueParcel width in cm
heightIntegertrueParcel height in cm

Service Levels

standard, express, timed, sameday, pallet

Pickup Types

collection, dropoff