Skip to content

Quote Shipment

This guide allows you to check shipping rates using the DrEnvío API. It includes information about the available environments, the list of compatible carriers, request parameters, response structure, and more.

Environments

DrEnvio API supports two environments: Production and Sandbox.

Production Environment The production environment is where real shipments are processed. To use the production API, send your requests to the following URL:

Ventana de terminal
https://prod.api-drenvio.com/v2/shipments/rate

Sandbox Environment The sandbox environment is used for testing purposes. It provides simulated data to help you develop and test your integration before moving to production. To use the sandbox API, send your requests to the following URL:

Ventana de terminal
https://sandbox.api-drenvio.com/v2/shipments/rate

Available Carriers

The carriers available for quoting depend on two factors: the origin country (MX or CO) and the shipment type (National or International). Make sure to only include carriers valid for your combination — invalid carriers will be ignored or return an error.

Note: In the sandbox environment, the only available carriers for quoting are JTExpress and Quiken.


Mexico (MX) — National Shipments

Use these carriers when origin.country = "MX" and type = "National":

[
"noventa9Minutos", "aExpress", "ampm", "carssa", "coordinadora",
"dhl", "estafeta", "fedex", "ivoy", "mensajerosUrbanos",
"paquetexpress", "quiken", "redpack", "scm", "sendex",
"tracusa", "uber", "ups", "vencedor", "jtexpress",
"entrega", "borzo", "tresguerras", "treggo", "pickit",
"test", "imile", "afimex", "ptx"
]

Mexico (MX) — International Shipments

Use these carriers when origin.country = "MX" and type = "International":

["dhl", "fedex", "ups", "estafeta"]

Colombia (CO) — National Shipments

Use these carriers when origin.country = "CO" and type = "National":

[
"fedex", "interrapidisimo", "redServi", "serviEntrega",
"mensajerosUrbanos", "noventa9Minutos", "dhl", "coordinadora",
"moova", "deprisa", "picap", "tcc", "envia"
]

Colombia (CO) — International Shipments

Use these carriers when origin.country = "CO" and type = "International":

["dhl", "fedex"]

Carrier Coverage Summary

OriginShipment TypeSupported Carriers
MXNationalnoventa9Minutos, aExpress, ampm, carssa, coordinadora, dhl, estafeta, fedex, ivoy, mensajerosUrbanos, paquetexpress, quiken, redpack, scm, sendex, tracusa, uber, ups, vencedor, jtexpress, entrega, borzo, tresguerras, treggo, pickit, test, imile, afimex, ptx
MXInternationaldhl, fedex, ups, estafeta
CONationalfedex, interrapidisimo, redServi, serviEntrega, mensajerosUrbanos, noventa9Minutos, dhl, coordinadora, moova, deprisa, picap, tcc, envia
COInternationaldhl, fedex

API request

To get a quote for a shipment, send a POST request to the API with the following JSON body:

{
"type": "National",
"origin": {
"country": "MX",
"postal_code": "64000"
},
"destination": {
"country": "MX",
"postal_code": "64380"
},
"packages": [
{
"weight": 1,
"height": 10,
"width": 10,
"length": 10,
"volumetric": 0.2,
"type": "box",
"main_weight": 1
}
],
"carriers": ["fedex", "estafeta", "ampm", "dhl"],
"insurance": 0
}

Fields description

FieldDescriptionTypeRequired
typeType of shipmentEnum: National, Internationaltrue
originOrigin information for shipment addressObject AddressObjecttrue
destinationDestination information for shipment addressObject AddressObjecttrue
packagesPackages array of itemsArray PackageObjecttrue
insuranceThe insurance of the shipment, if insured the response will contain the amount of the insurance. MXN if national shipping, if not in USD.numbertrue
carriersAn array with each of the carriers you want to rate your shipment. Must match the valid carriers for your origin.country and type combination. See Available Carriers.Array of stringstrue

Address (Object)

FieldDescriptionTypeRequired
country2-digit country code for each address. Origin must always be MX or CO, and destination can be any country.stringtrue
postalCodePostal Code for the origin and destination addresses.stringtrue
cityCity name of the address.stringfalse
districtDistrict or neighborhood of the address.stringfalse

Package (Object)

FieldDescriptionTypeRequired
weightThe weight of the package in kilograms (KG).numbertrue
heightThe height of the package in centimeters (CM).numbertrue
widthThe width of the package in centimeters (CM).numbertrue
lengthThe length of the package in centimeters (CM).numbertrue
volumetricThe volumetric weight of the shipment, typically calculated based on the dimensions.numberfalse
typeThe type of the package.Enum: box, envelope, pallettrue
insuranceThe insurance of the shipment, if insured the response will contain the amount of the insurance. MXN if national shipping, if not in USD.numberfalse

API response

[
{
"ObjectId": null,
"ShippingId": "G1",
"carrier": "fedex",
"service_id": "fedex_mx_D-C03_ground",
"service": "ground",
"price": 120,
"days": "3 a 5 días",
"insurance": 0,
"currency": "MXN",
"metadata": {
"extended_area": {
"extended_area": false,
"origin": false,
"destination": false
}
}
},
{
"ObjectId": null,
"ShippingId": "G1",
"carrier": "fedex",
"service_id": "fedex_mx_P-C00_ground",
"service": "ground",
"price": 94.55,
"days": "3 a 5 días",
"insurance": 0,
"currency": "MXN",
"metadata": {
"account_id": "648a19d789be2a38ae8eb0d2",
"account_price": 1,
"extended_area": {
"extended_area": false,
"origin": false,
"destination": false
}
}
},
{
"ObjectId": null,
"ShippingId": "G1",
"carrier": "fedex",
"service_id": "fedex_mx_D-C03_express",
"service": "express",
"price": 145,
"days": "1 a 2 días",
"insurance": 0,
"currency": "MXN",
"metadata": {
"extended_area": {
"extended_area": false,
"origin": false,
"destination": false
}
}
},
{
"ObjectId": null,
"ShippingId": "G1",
"carrier": "fedex",
"service_id": "fedex_mx_P-C00_express",
"service": "express",
"price": 86.52,
"days": "1 a 2 días",
"insurance": 0,
"currency": "MXN",
"metadata": {
"account_id": "648a19d789be2a38ae8eb0d2",
"account_price": 1,
"extended_area": {
"extended_area": false,
"origin": false,
"destination": false
}
}
},
{
"ObjectId": "T0",
"ShippingId": "N6",
"carrier": "estafeta",
"service": "metropolitano",
"currency": "MXN",
"price": 68,
"insurance": 0,
"service_id": "estafeta_mx_D-C03_metropolitano",
"days": "2 días",
"metadata": {
"extended_area": {
"extended_area": false,
"origin": false,
"destination": false
},
"ocurre": false
}
},
{
"ObjectId": "78",
"ShippingId": "N6",
"carrier": "estafeta",
"service": "ground",
"currency": "MXN",
"price": 120,
"insurance": 0,
"service_id": "estafeta_mx_D-C03_terrestre",
"days": "5 días",
"metadata": {
"extended_area": {
"extended_area": false,
"origin": false,
"destination": false
},
"ocurre": false
}
},
{
"ObjectId": "D8",
"ShippingId": "N6",
"carrier": "estafeta",
"service": "2_days",
"currency": "MXN",
"price": 134,
"insurance": 0,
"service_id": "estafeta_mx_D-C03_2dias",
"days": "2 días",
"metadata": {
"extended_area": {
"extended_area": false,
"origin": false,
"destination": false
},
"ocurre": false
}
},
{
"ObjectId": "60",
"ShippingId": "N6",
"carrier": "estafeta",
"service": "next_day",
"currency": "MXN",
"price": 135,
"insurance": 0,
"service_id": "estafeta_mx_D-C03_next_day",
"days": "1 día",
"metadata": {
"extended_area": {
"extended_area": false,
"origin": false,
"destination": false
},
"ocurre": false
}
},
{
"ShippingId": "E1",
"ObjectId": "ECONOMY SELECT DOMESTIC",
"carrier": "dhl",
"service": "ground",
"service_id": "dhl_mx_D-C01_ground",
"insurance": 0,
"currency": "MXN",
"days": "1 a 2 días",
"metadata": {
"dhl": {
"productCode": "G",
"productName": "ECONOMY SELECT DOMESTIC"
}
},
"price": 170
},
{
"ShippingId": "E1",
"ObjectId": "ECONOMY SELECT DOMESTIC",
"carrier": "dhl",
"service": "ground",
"service_id": "dhl_mx_P-C00_ground",
"insurance": 0,
"currency": "MXN",
"days": "1 a 2 días",
"metadata": {
"account_id": "648a1a9d89be2a38ae8eb21a",
"account_price": 1,
"dhl": {
"productCode": "G",
"productName": "ECONOMY SELECT DOMESTIC"
}
},
"price": 138.14
},
{
"ShippingId": "E1",
"ObjectId": "EXPRESS DOMESTIC",
"carrier": "dhl",
"service": "express",
"service_id": "dhl_mx_D-C01_express",
"insurance": 0,
"currency": "MXN",
"days": "1 a 2 días",
"metadata": {
"dhl": {
"productCode": "N",
"productName": "EXPRESS DOMESTIC"
}
},
"price": 175
},
{
"ShippingId": "E1",
"ObjectId": "EXPRESS DOMESTIC",
"carrier": "dhl",
"service": "express",
"service_id": "dhl_mx_P-C00_express",
"insurance": 0,
"currency": "MXN",
"days": "1 a 2 días",
"metadata": {
"account_id": "648a1a9d89be2a38ae8eb21a",
"account_price": 1,
"dhl": {
"productCode": "N",
"productName": "EXPRESS DOMESTIC"
}
},
"price": 138.14
},
{
"ObjectId": "next_day_guaranteed",
"ShippingId": "N4",
"carrier": "quiken",
"service": "ground",
"service_id": "quiken_mx_D-C01_ground",
"price": 92,
"currency": "MXN",
"days": "Siguiente día",
"extra": "Next Day Guaranteed",
"metadata": {}
},
{
"ObjectId": "local_express",
"ShippingId": "N4",
"carrier": "quiken",
"service": "ground",
"service_id": "quiken_mx_D-C01_ground36hrs",
"price": 69,
"currency": "MXN",
"days": "36 horas",
"extra": "Next Day - 36 hrs",
"metadata": {}
},
{
"ObjectId": null,
"ShippingId": "E1",
"carrier": "mensajerosUrbanos",
"service": "ground",
"service_id": "mensajerosUrbanos_mx_A-P01_ground",
"insurance": 0,
"price": 117.29,
"currency": "MXN",
"days": "2 horas",
"metadata": {}
}
]