Receber eventos
Registro de webhook obrigatório. Para receber webhooks você precisa ter pelo menos 2 URLs registradas — podem ser a mesma URL repetida ou URLs diferentes: uma para o webhook de Delivery request e outra para os eventos de status. Veja Criar webhook.
Nestes webhooks (eventos) é possível enviar um header Authorization para proteger seu endpoint. Avise qual token devemos usar em cada evento.
Eventualmente o cliente precisa cancelar uma solicitação. Garanta que seu sistema escuta de forma confiável os eventos de cancelamento — evita problemas de alocação de motorista e outros transtornos.
Em caso de dúvidas, fala com a gente que ajudamos.
Leia com atenção sobre o nosso sistema de timeout abaixo.
Timeout System
Aiming to deliver the best experience possible to our costumers, we have a Timeout System that will automatically CANCEL the delivery request after a default time of 30 minutes if it is not CONFIRMED by the carrier's system.
To avoid this scenario, you have to process and confirm the delivery as soon as possible, using Confirm Delivery. Please keep in mind that we will notify you via WEBHOOK in case of the delivery request has timed out and that this default time of 30 minutes is configurable.
If the DELIVERY_REQUEST event is not successful you should send a response with the error as a string value inside an object with the key abbiamo_error therefore we can mirror it in our dashboard to warn the seller about the issue. Example:
{
"abbiamo_error": "customer phone must be valid"
}