Informação de uma rota
Você pode obter uma rota pelo seu ID ou por algum ID de entrega que pertença à rota.
Endpoint
GET {{SHIPPIFY_API_URL}}/v1/routes/:id
Request
Propriedade | Tipo | Descrição | Obrigatório | Restrições |
---|---|---|---|---|
id | string | ID da rota ou ID da entrega. | SIM |
Response
Propriedade | Tipo | Descrição |
---|---|---|
route.id | string | Resultado do código. |
route.referenceId | string | Descrição do resultado. |
route.city | object | Dados da cidade. |
route.deliveries | array of Entrega | Lista de todas as entregas pertencentes à rota. |
currencyCode | string | Código da moeda. |
stepIds | array of objects | Lista em ordem com as etapas da rota. |
status | string | Status da rota. |
distances.routeDistances | arrray of numbers | Distâncias em cada etapa. |
distances.chargedDistances | arrray of numbers | Distâncias cobradas em cada etapa. |
Exemplo
curl --location --request GET 'https://api.shippify.co/v1/routes/r-shiinc-2217499/' \
--header 'Content-Type: application/json' \
--header 'Authorization: Basic XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX' \
--header 'Cookie: locale=es'
{
"payload": {
"route": {
"id": "r-shiinc-2217499",
"referenceId": "129709",
"city": {
"id": "3",
"name": "Santiago de Chile"
},
"deliveries": [
{
"id": "t-pruaas-4972",
"referenceId": "129709",
"state": 1,
"status": "processing",
"substatus": "processing",
"company": {
"id": 9065,
"name": "Prueba Pricing 2 no SaaS"
},
"pickup": {
"location": {
"latitude": -33.4429802,
"longitude": -70.5389736,
"address": "Av. Echeñique 8861, 7860169 La Reina, Región Metropolitana, Chile",
"instructions": "CLIENTE RETIRA PRODUCTOS EN POLICENTRO 2"
},
"timeWindow": {
"start": "2023-10-26T21:52:29.000Z",
"end": "2023-10-26T22:22:29.000Z"
},
"extras": [],
"contact": {
"name": "Oficina Shippify",
"email": "opsecuador@shippify.co",
"phonenumber": "1348029"
}
},
"dropoff": {
"location": {
"latitude": -33.4062104,
"longitude": -70.6336883,
"address": "Recoleta, Región Metropolitana, Chile",
"instructions": ""
},
"timeWindow": {
"start": "2023-10-26T22:37:29.000Z",
"end": "2023-10-26T23:07:29.000Z"
},
"extras": [],
"contact": {
"name": "Destinatario A",
"email": "",
"phonenumber": "435465675"
}
},
"fare": {
"service": 0,
"delivery": 0,
"cash": 0,
"currencyCode": "CLP"
},
"packages": {
"capacity": 3,
"contents": [
{
"id": "10000098-C",
"uuid": "85eaec2f-7258-41f2-8bee-6da5152809de",
"name": "T55002 TV IND 55 SMART LED 4K",
"size": 3,
"weight": 14,
"pickedUp": false,
"delivered": false,
"extras": {
"id_factura": "FAC01AA0012970941712200100000000000000420",
"SERIE_ITEM_NOTA_ENTREGA": "7900101291200",
"NRO_GUIA": "",
"SEC_GUIA": "0"
},
"scanned": false,
"price": 0,
"qty": 1
}
]
},
"tags": null,
"receiver": {
"name": "Destinatario A",
"email": "",
"phonenumber": "435465675"
},
"chargedDistance": 26.9,
"routeDistance": 26.9,
"deliveryType": "slot",
"jobId": null
},
{
"id": "t-pruaas-4973",
"referenceId": "129709",
"state": 1,
"status": "processing",
"substatus": "processing",
"company": {
"id": 9065,
"name": "Prueba Pricing 2 no SaaS"
},
"pickup": {
"location": {
"latitude": -33.4378,
"longitude": -70.6505,
"address": "Pl. de Armas 451, Santiago, 8320341, Región Metropolitana, Chile",
"instructions": "-"
},
"timeWindow": {
"start": "2023-10-27T18:24:11.000Z",
"end": "2023-10-27T18:54:11.000Z"
},
"extras": [],
"contact": {
"name": "Carlos Beltran",
"email": "carlos.beltran@hotmial.com",
"phonenumber": "09990252564"
}
},
"dropoff": {
"location": {
"latitude": -33.4608166,
"longitude": -70.7830274,
"address": "Puerto Santiago 259, Pudahuel, Región Metropolitana, Chile",
"instructions": "Bodega F06"
},
"timeWindow": {
"start": "2023-10-27T19:09:11.000Z",
"end": "2023-10-27T19:39:11.000Z"
},
"extras": [],
"contact": {
"name": "Dannis Gamboa",
"email": "hubcl@shippify.co",
"phonenumber": "+56233462525"
}
},
"fare": {
"service": 0,
"delivery": 0,
"cash": 10,
"currencyCode": "CLP"
},
"packages": {
"capacity": 3,
"contents": [
{
"id": "10000098-C",
"uuid": "8b02ab60-3dac-449a-91aa-a4616c38d045",
"name": "T55002 TV IND 55 SMART LED 4K",
"size": 3,
"weight": 14,
"pickedUp": false,
"delivered": false,
"extras": {
"id_factura": "FAC01AA0012970941712200100000000000000420",
"SERIE_ITEM_NOTA_ENTREGA": "7900101291200",
"NRO_GUIA": "",
"SEC_GUIA": "0"
},
"scanned": false,
"price": 0,
"qty": 1
}
]
},
"tags": [
{
"id": 0,
"name": null,
"color": null,
"company": null,
"driverVisible": null
},
{
"id": 1003,
"name": "Atenção Especial",
"color": "#48a5ba",
"company": 362,
"driverVisible": 0
}
],
"receiver": {
"name": "Dannis Gamboa",
"email": "hubcl@shippify.co",
"phonenumber": "+56233462525"
},
"chargedDistance": 26.9,
"routeDistance": 26.9,
"deliveryType": "slot",
"jobId": null
}
],
"currencyCode": "CLP",
"stepIds": [
{
"deliveryId": "t-pruaas-4973",
"activityType": "pickup"
},
{
"deliveryId": "t-pruaas-4972",
"activityType": "pickup"
},
{
"deliveryId": "t-pruaas-4973",
"activityType": "dropoff"
},
{
"deliveryId": "t-pruaas-4972",
"activityType": "dropoff"
}
],
"legDistances": [
13.1,
26.9,
20.1
],
"status": "processing",
"distances": {
"routeDistances": [
13.1,
26.9,
20.1
],
"chargedDistances": [
0,
0,
26.9,
26.9
]
}
}
}