In the event of a possible cancellation or update of a task. Instaleap will send the necessary information to the 3PL so that they can manage the cancellation of the service. Said endpoint must be of type POST. Below is the information sent by Instaleap:

task_idId of the task within Instaleap. It is used to manage the task.
created_atDate of sending the payload to the 3PL.
event_typeThe event type describes each of the task updates.
""CANCELLED"": Event sent when an order cancellation is made. This is a final state of the order.
""TASK_RESET"": Event sent when the task is removed from the resource and all its steps are restarted. This task remains unassigned and can be assigned to another resource to start from the first step. It should be handled as a Cancellation.
""PRICES_UPDATED"": Event sent when an update of totals, shipping fee, taxes of the order were made.
""PAYMENT_UPDATED"": Event sent when an update is made to the payment method, amount paid, payment status.
taskPayload with task information
slot_infoObject that contains the slot information, contains the following fields:
from: start date
to: end date
reason: slot type, it can be of the following types:
packages_quantitynumber of packages

Here is an example of the Payload sent:

    "task_id": "b4e23f2b-3eeb-4b6c-b196-aa6be921769d",
    "created_at": "2021-12-29T21:30:04.411Z",
    "event_type": "CANCELLED",
    "task": {
    "job_number": "I23H6HN",
    "client_id": "TEST_ID",
    "created_at": "2021-12-29T21:30:04.411Z",
    "shopper_web_url": "https://3pl-app.instaleap.io/...",
    "fleet_info": {...},
    "recipient": {...},
    "origin": {...},
    "destination": {...},
    "job_items": […],
    "payment_info": {
        "currency_code": "MXN",
        "prices": {
            "shipping_fee": 6000,
            "order_value": 450000,
        "payment": {
           "method": "PREPAID",
   "job_comment": "some comment" | null,
     "from": "2023-09-21T14:00:00.000Z",
     "to":  "2023-09-21T15:59:00.000Z",
     "reason": "STATIC"
   "packages_quantity": 5

Example of the expected response:

    "service_id": "your_id_123",
    "message": "RECEIVED"