Obter detalhes da entrega
curl --request GET \
--url https://api.taximachine.com.br/api/v2/integracao/entregas/{id}/detalhes \
--header 'Authorization: Basic <encoded-value>' \
--header 'api-key: <api-key>'import requests
url = "https://api.taximachine.com.br/api/v2/integracao/entregas/{id}/detalhes"
headers = {
"Authorization": "Basic <encoded-value>",
"api-key": "<api-key>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {Authorization: 'Basic <encoded-value>', 'api-key': '<api-key>'}
};
fetch('https://api.taximachine.com.br/api/v2/integracao/entregas/{id}/detalhes', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.taximachine.com.br/api/v2/integracao/entregas/{id}/detalhes",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Basic <encoded-value>",
"api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.taximachine.com.br/api/v2/integracao/entregas/{id}/detalhes"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Basic <encoded-value>")
req.Header.Add("api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.taximachine.com.br/api/v2/integracao/entregas/{id}/detalhes")
.header("Authorization", "Basic <encoded-value>")
.header("api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.taximachine.com.br/api/v2/integracao/entregas/{id}/detalhes")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Basic <encoded-value>'
request["api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"request_id": 83381,
"external_id": "PED-123",
"full_code": "FINISHED",
"short_code": "F",
"requested_at": "2025-02-20T11:45:13+00:00",
"manager": "Administrador",
"route_key": null,
"return_trip": false,
"category": "Moto",
"driver": {
"id": 5539,
"name": "Felipe Nunes",
"phone": "(99) 99898-9898",
"internationalPhone": "+5599998989898",
"cpf": "111.222.333-44",
"vtr": null,
"vehicle_plate": "MOJ-8232",
"vehicle_model": "gol"
},
"enterprise": {
"id": 12,
"name": "Empresa Exemplo",
"cost_center": "Administrativo",
"voucher_series": null,
"voucher_number": null,
"ticket_status": null,
"authorization_number": null,
"authorization_at": null,
"finalization_type": null
},
"progress": {
"accepted_at": "2025-02-20T14:12:32+00:00",
"accept_lat": -7.2091,
"accept_lng": -34.8781,
"accept_eta_seconds": 120,
"accept_eta_km": 0.8,
"accept_duration_minutes": 2,
"accept_distance_km": 0.8,
"estimated_distance_km": 4.05,
"estimated_duration_minutes": 7,
"estimated_value": 26.8,
"pickup_arrival": "2025-02-20T14:12:34+00:00",
"arrival_at_surroundings": null,
"start_trip": "2025-02-20T14:15:02+00:00",
"pending_at": null
},
"finished": {
"finished_at": "2025-02-20T14:12:45+00:00",
"finalized_distance_km": 4.1,
"traveled_distance_km": 4.2,
"stopped_time_virtual_taximeter": 30,
"final_value": 26.8,
"coupon_value": 0,
"address": {
"address": "Av. Epitácio Pessoa, 1200",
"neighborhood": "Tambauzinho",
"city": "João Pessoa",
"state": "PB",
"latitude": -7.1215,
"longitude": -34.8573
}
},
"stops": [
{
"order": 0,
"status": "F",
"notes": null,
"client": {
"name": "Maria Souza",
"phone": "(99) 99898-9898",
"internationalPhone": "+5599998989898"
},
"address": {
"address": "R. Silva Mariz, 51",
"complement": null,
"reference": null,
"neighborhood": "Cruz das Armas",
"city": "João Pessoa",
"state": "PB",
"latitude": -7.139168,
"longitude": -34.888007
},
"comprovante": {
"url": "https://exemplo-bucket.s3.amazonaws.com/upload/comprovante/parada/exemplo-1.jpg?X-Amz-Expires=1800&X-Amz-Signature=...",
"expira_em": "2025-02-20T14:58:17Z"
}
},
{
"order": 1,
"status": "F",
"notes": null,
"client": {
"name": "João Pereira",
"phone": "(99) 99777-7777",
"internationalPhone": "+5599997777777"
},
"address": {
"address": "Av. Epitácio Pessoa, 1200",
"complement": null,
"reference": null,
"neighborhood": "Tambauzinho",
"city": "João Pessoa",
"state": "PB",
"latitude": -7.1215,
"longitude": -34.8573
},
"comprovante": null
}
]
}
}Entregas
Obter detalhes da entrega
Obter detalhes da entrega
Cada item de stops traz comprovante, a foto que o condutor enviou ao confirmá-la, ou null quando a parada não tem foto ou quando a foto não está mais disponível. O objeto tem url, um link temporário que abre a imagem por 30 minutos, e expira_em, o fim dessa validade em ISO 8601 e em UTC; passado o prazo, o link para de funcionar e uma nova consulta devolve outro. Quem tem o link abre a foto sem autenticação: não guarde nem repasse a URL e consulte a entrega de novo quando precisar exibir a foto.
GET
/
entregas
/
{id}
/
detalhes
Obter detalhes da entrega
curl --request GET \
--url https://api.taximachine.com.br/api/v2/integracao/entregas/{id}/detalhes \
--header 'Authorization: Basic <encoded-value>' \
--header 'api-key: <api-key>'import requests
url = "https://api.taximachine.com.br/api/v2/integracao/entregas/{id}/detalhes"
headers = {
"Authorization": "Basic <encoded-value>",
"api-key": "<api-key>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {Authorization: 'Basic <encoded-value>', 'api-key': '<api-key>'}
};
fetch('https://api.taximachine.com.br/api/v2/integracao/entregas/{id}/detalhes', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.taximachine.com.br/api/v2/integracao/entregas/{id}/detalhes",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Basic <encoded-value>",
"api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.taximachine.com.br/api/v2/integracao/entregas/{id}/detalhes"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Basic <encoded-value>")
req.Header.Add("api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.taximachine.com.br/api/v2/integracao/entregas/{id}/detalhes")
.header("Authorization", "Basic <encoded-value>")
.header("api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.taximachine.com.br/api/v2/integracao/entregas/{id}/detalhes")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Basic <encoded-value>'
request["api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"request_id": 83381,
"external_id": "PED-123",
"full_code": "FINISHED",
"short_code": "F",
"requested_at": "2025-02-20T11:45:13+00:00",
"manager": "Administrador",
"route_key": null,
"return_trip": false,
"category": "Moto",
"driver": {
"id": 5539,
"name": "Felipe Nunes",
"phone": "(99) 99898-9898",
"internationalPhone": "+5599998989898",
"cpf": "111.222.333-44",
"vtr": null,
"vehicle_plate": "MOJ-8232",
"vehicle_model": "gol"
},
"enterprise": {
"id": 12,
"name": "Empresa Exemplo",
"cost_center": "Administrativo",
"voucher_series": null,
"voucher_number": null,
"ticket_status": null,
"authorization_number": null,
"authorization_at": null,
"finalization_type": null
},
"progress": {
"accepted_at": "2025-02-20T14:12:32+00:00",
"accept_lat": -7.2091,
"accept_lng": -34.8781,
"accept_eta_seconds": 120,
"accept_eta_km": 0.8,
"accept_duration_minutes": 2,
"accept_distance_km": 0.8,
"estimated_distance_km": 4.05,
"estimated_duration_minutes": 7,
"estimated_value": 26.8,
"pickup_arrival": "2025-02-20T14:12:34+00:00",
"arrival_at_surroundings": null,
"start_trip": "2025-02-20T14:15:02+00:00",
"pending_at": null
},
"finished": {
"finished_at": "2025-02-20T14:12:45+00:00",
"finalized_distance_km": 4.1,
"traveled_distance_km": 4.2,
"stopped_time_virtual_taximeter": 30,
"final_value": 26.8,
"coupon_value": 0,
"address": {
"address": "Av. Epitácio Pessoa, 1200",
"neighborhood": "Tambauzinho",
"city": "João Pessoa",
"state": "PB",
"latitude": -7.1215,
"longitude": -34.8573
}
},
"stops": [
{
"order": 0,
"status": "F",
"notes": null,
"client": {
"name": "Maria Souza",
"phone": "(99) 99898-9898",
"internationalPhone": "+5599998989898"
},
"address": {
"address": "R. Silva Mariz, 51",
"complement": null,
"reference": null,
"neighborhood": "Cruz das Armas",
"city": "João Pessoa",
"state": "PB",
"latitude": -7.139168,
"longitude": -34.888007
},
"comprovante": {
"url": "https://exemplo-bucket.s3.amazonaws.com/upload/comprovante/parada/exemplo-1.jpg?X-Amz-Expires=1800&X-Amz-Signature=...",
"expira_em": "2025-02-20T14:58:17Z"
}
},
{
"order": 1,
"status": "F",
"notes": null,
"client": {
"name": "João Pereira",
"phone": "(99) 99777-7777",
"internationalPhone": "+5599997777777"
},
"address": {
"address": "Av. Epitácio Pessoa, 1200",
"complement": null,
"reference": null,
"neighborhood": "Tambauzinho",
"city": "João Pessoa",
"state": "PB",
"latitude": -7.1215,
"longitude": -34.8573
},
"comprovante": null
}
]
}
}