Migration from 2026-01 API & Webhook to 2026-07

The following guide will help you migrate the API and webhook from version 2026-01 to version 2026-07.

What's the difference?

ChangeBeforeAfter
Base URLhttps://api.aftership.com/tracking/2026-01https://api.aftership.com/tracking/2026-07
as-api-version response header value2026-012026-07
as-webhook-version request header value2026-012026-07

What do I need to do?

Make the following updates to your application's code:

  1. Replace the base URL from https://api.aftership.com/tracking/2026-01 to https://api.aftership.com/tracking/2026-07.
  2. When editing existing URLs or adding new ones, select the correct Webhook version. Please review your webhook settings for verification.
  3. Parse the header to distinguish between different versions. Otherwise, no action is required.
LanguageRepository URL
Javahttps://github.com/AfterShip/tracking-sdk-java
Nodejshttps://github.com/AfterShip/tracking-sdk-nodejs
.NEThttps://github.com/AfterShip/tracking-sdk-net
Pythonhttps://github.com/AfterShip/tracking-sdk-python
Rubyhttps://github.com/AfterShip/tracking-sdk-ruby
PHPhttps://github.com/AfterShip/tracking-sdk-php
Golanghttps://github.com/AfterShip/tracking-sdk-go

10 new delivery sub-statuses have been added. For a comprehensive list, refer to this document.

Sub-status codeSub-status messageDescription
Delivered_005Delivered to neighborThe shipment was delivered to a neighbor.
Exception_016Delayed (Processing issue)The shipment has experienced a delay due to a processing issue within the carrier network. This could be a vehicle issue, sorting error, misroute, etc.
Exception_017Delayed (Extreme weather)The shipment has experienced a delay due to extreme weather conditions such as storms, floods, or heavy snow.
Exception_018Incorrect missing documentsThe shipment has been placed on hold due to inaccurate or missing documents required by regulatory agencies. It may be delayed or returned to sender if not resolved.
Exception_019Delayed (Late flight)The shipment has experienced a delay due to a delayed or rescheduled flight.
Exception_020Shipment cancelledThe shipment was voided or canceled by the sender or carrier.
Exception_021Shipment disposedThe shipment was destroyed or discarded, usually due to it being prohibited, damaged, or unable to be delivered or returned.
InTransit_011Import customs clearance completedThe shipment has successfully cleared import customs.
InTransit_012Import customs clearance startedThe shipment is now undergoing import customs clearance.
InTransit_013Drop off for carrier pickupThe shipment has been dropped off at a designated location (such as a drop box, service point, or post office) and is awaiting carrier pickup.

What do I need to do?

  • Parse the new sub-status codes in the API response and the webhook body if you want to retrieve data from the new sub-statuses. Otherwise, no further action is required.

The new shipment_dimensions field returns the physical dimensions of the package, including length, width, and height.

What do I need to do?

  • Parse the shipment_dimensions field in the API response and the webhook body if you want to retrieve data from the new field. Otherwise, no further action is required.

The new checkpoints[].hash field returns a unique hash identifier for each checkpoint event, which can be used for deduplication.

What do I need to do?

  • Parse the checkpoints[].hash field in the API response and the webhook body if you want to retrieve data from the new field. Otherwise, no further action is required.

The new customers[].id field stores the customer's identifier on the merchant or platform (for example, Shopify) side. This field is both readable and writable.

What do I need to do?

  • Provide customers[].id in the API request if you want to associate a customer with their platform ID.
  • Parse the field in the API response and the webhook body if you want to retrieve the data. Otherwise, no further action is required.

The new proof_of_delivery field returns an array of proof of delivery (POD) records, such as a signature or photo captured upon successful delivery. This field returns a value only after the feature is enabled. Please contact your customer success manager if you'd like to know more.

FieldR/WDescription
proof_of_delivery[].typeRead-onlyThe file type of the proof of delivery record. Currently, only images are supported.
proof_of_delivery[].urlRead-onlyThe URL of the proof of delivery record.

What do I need to do?

  • Parse the proof_of_delivery field in the API response and the webhook body if you want to retrieve data. Otherwise, no further action is required.

Multi-piece shipment (MPS) refers to a scenario where a single shipment order is fulfilled by multiple physical packages. Each piece has its own carrier-assigned tracking number, but all pieces belong to the same shipment. The following new fields expose MPS metadata. These fields return a value only after the feature is enabled. To enable, go to AfterShip Tracking Admin > Settings > Shipment tracking > Multi-piece shipments.

FieldR/WDescription
multi_piece_infoRead-onlyMulti-piece shipment metadata describing a group of packages that belong to the same shipment. This commonly occurs when an order is too large to fit in one box, or when items are packed separately for handling reasons. This field returns a value only when your subscription plan includes the multi-piece feature.
multi_piece_info.typeRead-onlyIndicates the role of the current tracking object within the multi-piece shipment: master (the main tracking number representing the entire shipment; it may not always exist) or child (a sub-tracking number belonging to one of the pieces in the shipment)
multi_piece_info.pieces[]Read-onlyList of all pieces in the MPS, including the master and all child pieces
multi_piece_info.pieces[].tracking_idRead-onlyAfterShip system-assigned unique identifier for the piece
multi_piece_info.pieces[].tracking_numberRead-onlyCarrier-assigned tracking number for the piece
multi_piece_info.pieces[].typeRead-onlyType of the piece within the MPS: master or child
multi_piece_info.pieces[].trackableRead-onlyIndicates whether the tracking number can be used to retrieve tracking updates on the carrier's side. If not, it means the carrier can only return a child tracking number, but cannot independently provide tracking updates for the sub-shipment. In this case, it is not recommended for you to import this tracking number into AfterShip for tracking. Possible values: true or false

What do I need to do?

  • Parse the new fields in the API response and the webhook body if you want to retrieve data. Otherwise, no further action is required.

The following new fields indicate the business direction of a shipment and link forward and return shipments together. The return_shipment and forward_shipment fields return a value only after the feature is enabled. To enable, go to AfterShip Tracking Admin > Settings > Shipment tracking > Return shipments.

FieldR/WDescription
shipment_directionRead/WriteIndicates the business direction of the shipment in the e-commerce fulfillment lifecycle: forward (a forward, outbound-to-customer shipment created for order fulfillment) or return (a return, customer-to-merchant shipment created for after-sales return or exchange). This field is populated in either of the following cases: 1. You explicitly provided it when creating the tracking. 2. AfterShip automatically detected a linked forward or return shipment. It also determines which related shipment object (forward_shipment or return_shipment) may appear in the response.
return_shipmentRead-onlyThe associated return shipment linked to the current outbound shipment. This field is only present when shipment_direction = "forward" and AfterShip has detected a linked return shipment.
return_shipment.idRead-onlyAfterShip system-assigned unique identifier of the linked return shipment. This field is only returned when both of the following conditions are met: 1. AfterShip has detected a linked return shipment. 2. The Auto-import for return shipments feature is enabled in your AfterShip account. When auto-import is disabled, id will not be returned, but tracking_number and slug may still be present. To enable this feature, go to AfterShip Tracking Admin > Settings > Shipment Tracking > Return Shipments.
return_shipment.tracking_numberRead-onlyCarrier-assigned tracking number of the linked return shipment. Can be used together with return_shipment.slug to create a new tracking subscription and retrieve the return shipment's checkpoints.
return_shipment.slugRead-onlyCarrier slug (identifier) of the linked return shipment. Can be used together with return_shipment.tracking_number to subscribe to tracking updates for the return shipment.
forward_shipmentRead-onlyThe original outbound shipment linked to this return. Use this to trace a return back to its source delivery. This field is only present when shipment_direction = "return" and AfterShip has detected a linked forward shipment.
forward_shipment.idRead-onlyAfterShip system-assigned unique identifier of the linked outbound shipment

What do I need to do?

  • Provide shipment_direction in the API request if you want to label a shipment as forward or return.
  • Parse the new fields in the API response and the webhook body if you want to retrieve data. Otherwise, no further action is required.

Please refer to the New Delivery Sub-statuses section of the guide.

Please refer to the Tracking Model Fields Added section of the guide.

After January 7, 2029, requests made to the 2026-01 version will be automatically redirected to the oldest supported API version. While this redirection aims to minimize disruptions, it may not fully support all functionalities available in the newer versions. We recommend migrating at your earliest convenience.