AfterShip
aftershipAfterShip provides shipment tracking, courier detection and connections, and estimated delivery date prediction for ecommerce operations.
Acciones disponibles (17)
Cada acción es una operación que el agente puede ejecutar contra este conector. Haz clic en una acción para ver sus parámetros.
Create Courier ConnectionAFTERSHIP_CREATE_COURIER_CONNECTIONAcciónConnect one courier account using the courier-specific credential fields advertised by courier metadata.
AFTERSHIP_CREATE_COURIER_CONNECTIONAcciónConnect one courier account using the courier-specific credential fields advertised by courier metadata.
Parámetros de entrada
courier_slugstringObligatorioCourier slug to connect. Use LIST_COURIERS to resolve the slug and inspect its required credential fields.
carrier_account_fieldsobjectObligatorioCarrier-specific secret values keyed by the exact field names from the courier's credentials.fields metadata. Values are sent only to AfterShip; do not use this field for non-secret metadata, and credential values are never included in this action's output.
Parámetros de salida
dataanyObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
Create TrackingAFTERSHIP_CREATE_TRACKINGAcciónCreate one shipment tracking record from a tracking number and optional courier, order, route, customer, and delivery metadata.
AFTERSHIP_CREATE_TRACKINGAcciónCreate one shipment tracking record from a tracking number and optional courier, order, route, customer, and delivery metadata.
Parámetros de entrada
idstringOptional caller-defined tracking ID; omit to let AfterShip generate one.
notestringInternal note associated with the tracking.
titlestringHuman-readable tracking title.
languagestringRecipient ISO 639-1 language code.
order_idstringGlobally unique order identifier.
customersobject[]Customers associated with the tracking, up to three.
last_mileobjectKnown last-mile courier and tracking number.
order_datestringOrder date-time, preferably including its timezone.
location_idstringAfterShip fulfillment location ID; cannot be combined with explicit origin fields.
origin_citystringOrigin city.
pickup_notestringPickup instructions shown to the recipient.
courier_slugstringCourier slug; cannot be combined with courier_slug_group.
order_numberstringHuman-readable order number.
origin_statestringOrigin state or province.
tracking_keystringAdditional carrier tracking credential required by some couriers.
custom_fieldsobjectNon-personal custom string fields associated with the shipment.
delivery_typestringenumShipment delivery method.
pickup_at_storedoor_to_doorpickup_at_courierorder_id_pathstringURL for the order in the merchant system.
shipment_tagsstring[]Tags used to categorize the shipment.
shipment_typestringCarrier service type for the shipment.
pickup_locationstringPickup location shown to the recipient.
shipping_methodstringMerchant-facing shipping method name.
tracking_numberstringObligatorioCarrier tracking number for the shipment.
destination_citystringDestination city.
destination_statestringDestination state or province.
courier_slug_groupstringCourier slug group for detection; cannot be combined with courier_slug.
origin_postal_codestringOrigin postal code.
shipment_directionstringenumDirection in the ecommerce fulfillment lifecycle.
forwardreturntracking_ship_datestringShipment-ready date or date-time accepted by the courier.
origin_raw_locationstringUnstructured origin address.
courier_connection_idstringCourier connection to use when multiple accounts exist for the courier.
origin_country_regionstringOrigin ISO 3166-1 alpha-3 country or region code.
destination_postal_codestringDestination postal code.
tracking_account_numberstringCarrier account number required by some couriers.
destination_raw_locationstringUnstructured destination address.
destination_country_regionstringDestination ISO 3166-1 alpha-3 country or region code.
order_promised_delivery_dateobjectPromised delivery date or range in the recipient timezone.
Parámetros de salida
dataanyObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
Create Trackings BatchAFTERSHIP_CREATE_TRACKINGS_BATCHAcciónSequentially create 1-20 tracking records through AfterShip's single-record create endpoint. This operation is non-atomic: each item consumes one request, successful earlier creates are not rolled back, and no create is retried automatically. Item-specific 400 and 409 rejections do not stop later items; authentication, permission, rate-limit, server, malformed-success, and transport failures stop processing and mark remaining items not_attempted.
AFTERSHIP_CREATE_TRACKINGS_BATCHAcciónSequentially create 1-20 tracking records through AfterShip's single-record create endpoint. This operation is non-atomic: each item consumes one request, successful earlier creates are not rolled back, and no create is retried automatically. Item-specific 400 and 409 rejections do not stop later items; authentication, permission, rate-limit, server, malformed-success, and transport failures stop processing and mark remaining items not_attempted.
Parámetros de entrada
trackingsobject[]ObligatorioTracking records to create in order, from 1 to 20. Each item uses the full single-tracking create contract and consumes one provider request.
Parámetros de salida
dataanyObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
Delete Courier ConnectionAFTERSHIP_DELETE_COURIER_CONNECTIONAcciónPermanently remove one courier account connection by an ID obtained from list or create. Warning: this destructive action cannot be undone.
AFTERSHIP_DELETE_COURIER_CONNECTIONAcciónPermanently remove one courier account connection by an ID obtained from list or create. Warning: this destructive action cannot be undone.
Parámetros de entrada
courier_connection_idstringObligatorioCourier connection ID to permanently remove. Use an ID returned by LIST_COURIER_CONNECTIONS or CREATE_COURIER_CONNECTION.
Parámetros de salida
dataanyObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
Delete TrackingAFTERSHIP_DELETE_TRACKINGAcciónPermanently delete one tracking record by its AfterShip tracking ID. Warning: this destructive action cannot be undone.
AFTERSHIP_DELETE_TRACKINGAcciónPermanently delete one tracking record by its AfterShip tracking ID. Warning: this destructive action cannot be undone.
Parámetros de entrada
tracking_idstringObligatorioAfterShip tracking ID to permanently delete.
Parámetros de salida
dataanyObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
Detect CourierAFTERSHIP_DETECT_COURIERAcciónReturn couriers that may handle a tracking number, using optional courier and shipment hints to narrow detection.
AFTERSHIP_DETECT_COURIERAcciónReturn couriers that may handle a tracking number, using optional courier and shipment hints to narrow detection.
Parámetros de entrada
tracking_keystringAdditional carrier tracking credential used as a detection hint.
courier_slugsstring[]Candidate courier slugs; cannot be combined with courier_slug_group.
tracking_numberstringObligatorioCarrier tracking number to analyze.
destination_statestringDestination state or province used as a detection hint.
courier_slug_groupstringCandidate courier slug group; cannot be combined with courier_slugs.
tracking_ship_datestringShipment date in YYYYMMDD format when required by a courier.
origin_country_regionstringOrigin uppercase ISO 3166-1 alpha-3 country or region code.
destination_postal_codestringDestination postal code used as a courier-specific hint.
tracking_account_numberstringCarrier account number used as a detection hint.
destination_country_regionstringDestination uppercase ISO 3166-1 alpha-3 country or region code.
Parámetros de salida
dataanyObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
Get Courier ConnectionAFTERSHIP_GET_COURIER_CONNECTIONAcciónReturn one courier account connection by an ID obtained from list or create.
AFTERSHIP_GET_COURIER_CONNECTIONAcciónReturn one courier account connection by an ID obtained from list or create.
Parámetros de entrada
courier_connection_idstringObligatorioCourier connection ID returned by list or create; do not invent a UUID.
Parámetros de salida
dataanyObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
Get TrackingAFTERSHIP_GET_TRACKINGAcciónReturn one tracking record by its AfterShip tracking ID, with optional field selection and checkpoint translation.
AFTERSHIP_GET_TRACKINGAcciónReturn one tracking record by its AfterShip tracking ID, with optional field selection and checkpoint translation.
Parámetros de entrada
fieldsstring[]Response fields to include; omit for the full tracking object.
languagestringTarget language code for translated checkpoint messages.
tracking_idstringObligatorioAfterShip tracking ID returned by create or list, not the carrier tracking number.
Parámetros de salida
dataanyObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
List Courier ConnectionsAFTERSHIP_LIST_COURIER_CONNECTIONSAcciónReturn one cursor-controlled page of courier account connections, optionally filtered by courier slug.
AFTERSHIP_LIST_COURIER_CONNECTIONSAcciónReturn one cursor-controlled page of courier account connections, optionally filtered by courier slug.
Parámetros de entrada
limitintegerMaximum connections to return in this page (1-200).
cursorstringOpaque next cursor returned by a previous call; omit for the first page.
courier_slugstringCourier slug whose connections should be returned.
Parámetros de salida
dataanyObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
List CouriersAFTERSHIP_LIST_COURIERSAcciónReturn courier metadata, optionally limited to account-activated couriers or selected courier slugs, including required tracking and credential field definitions.
AFTERSHIP_LIST_COURIERSAcciónReturn courier metadata, optionally limited to account-activated couriers or selected courier slugs, including required tracking and credential field definitions.
Parámetros de entrada
activebooleanSet true to return couriers activated for the connected AfterShip account; omit to use provider default behavior.
courier_slugsstring[]Courier slugs to return.
Parámetros de salida
dataanyObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
List TrackingsAFTERSHIP_LIST_TRACKINGSAcciónReturn one cursor-controlled page of shipment trackings, optionally filtered by identifiers, courier, status, dates, route, or shipment metadata.
AFTERSHIP_LIST_TRACKINGSAcciónReturn one cursor-controlled page of shipment trackings, optionally filtered by identifiers, courier, status, dates, route, or shipment metadata.
Parámetros de entrada
tagstringenumTracking status to match.
PendingInfoReceivedInTransitOutForDeliveryAttemptFailDeliveredAvailableForPickupExceptionExpiredlimitintegerMaximum trackings to return in this page (1-200).
cursorstringOpaque next cursor returned by a previous call; omit for the first page.
fieldsstring[]Optional response fields to include.
keywordstringSearch text for matching trackings.
order_idsstring[]Order IDs to match.
transit_timeintegerMatch shipments with this transit time in days.
courier_slugsstring[]Courier slugs to match.
shipment_tagsstring[]Shipment tags to match.
created_at_maxstringInclusive upper bound for creation time.
created_at_minstringInclusive lower bound for creation time.
updated_at_maxstringInclusive upper bound for update time.
updated_at_minstringInclusive lower bound for update time.
return_to_senderboolean[]Filter by return-to-sender state.
tracking_numbersstring[]Tracking numbers to match, up to 50.
origin_country_regionsstring[]Origin ISO alpha-3 country or region codes.
destination_country_regionsstring[]Destination ISO alpha-3 country or region codes.
courier_destination_country_regionstringCourier-resolved destination country or region code.
Parámetros de salida
dataanyObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
Mark Tracking CompletedAFTERSHIP_MARK_TRACKING_COMPLETEDAcciónMark a tracking as delivered, lost, or returned to sender. Warning: a successful call stops automatic tracking updates until the tracking is retracked.
AFTERSHIP_MARK_TRACKING_COMPLETEDAcciónMark a tracking as delivered, lost, or returned to sender. Warning: a successful call stops automatic tracking updates until the tracking is retracked.
Parámetros de entrada
reasonstringObligatorioenumCompletion outcome to record: delivered, lost, or returned to sender.
DELIVEREDLOSTRETURNED_TO_SENDERtracking_idstringObligatorioAfterShip tracking ID to mark completed, not the carrier tracking number.
event_datetimestringWhen the completion event occurred, as YYYY-MM-DD, YYYY-MM-DDTHH:mm:ss, or YYYY-MM-DDTHH:mm:ssZ.
Parámetros de salida
dataanyObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
Predict Estimated Delivery DateAFTERSHIP_PREDICT_ESTIMATED_DELIVERY_DATEAcciónPredict an estimated delivery date before a tracking number exists. This paid endpoint requires Predict trial access or an AfterShip advanced plan.
AFTERSHIP_PREDICT_ESTIMATED_DELIVERY_DATEAcciónPredict an estimated delivery date before a tracking number exists. This paid endpoint requires Predict trial access or an AfterShip advanced plan.
Parámetros de entrada
weightobjectTotal package weight.
pickup_timestringKnown local pickup date-time in the origin time zone; do not combine with estimated_pickup.
courier_slugstringObligatorioAfterShip courier slug for the planned shipment.
package_countintegerNumber of packages in the shipment.
origin_addressobjectObligatorioOrigin address with a country code and either a state or postal code.
estimated_pickupobjectOrder schedule from which AfterShip should estimate pickup; do not combine with pickup_time.
service_type_namestringCourier service type used for the shipment.
destination_addressobjectObligatorioDestination address with a country code and either a state or postal code.
Parámetros de salida
dataanyObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
Predict Estimated Delivery Dates BatchAFTERSHIP_PREDICT_ESTIMATED_DELIVERY_DATES_BATCHAcciónPredict estimated delivery dates atomically for one to five planned shipments. One invalid item fails the whole batch. The connected AfterShip organization must have a Predict trial or advanced-plan entitlement.
AFTERSHIP_PREDICT_ESTIMATED_DELIVERY_DATES_BATCHAcciónPredict estimated delivery dates atomically for one to five planned shipments. One invalid item fails the whole batch. The connected AfterShip organization must have a Predict trial or advanced-plan entitlement.
Parámetros de entrada
estimated_delivery_datesobject[]ObligatorioOne to five prediction requests. Every item requires a courier, both addresses, and exactly one pickup-time form. One invalid item fails the entire batch.
Parámetros de salida
dataanyObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
Retrack TrackingAFTERSHIP_RETRACK_TRACKINGAcciónRestart automatic updates for an expired tracking. Only expired trackings are eligible, and each successful call irreversibly consumes one of at most three retrack attempts for that tracking.
AFTERSHIP_RETRACK_TRACKINGAcciónRestart automatic updates for an expired tracking. Only expired trackings are eligible, and each successful call irreversibly consumes one of at most three retrack attempts for that tracking.
Parámetros de entrada
tracking_idstringObligatorioAfterShip ID of an expired tracking to retrack. This action only accepts expired trackings, and each successful call consumes one of the tracking's maximum three retrack attempts.
Parámetros de salida
dataanyObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
Update Courier ConnectionAFTERSHIP_UPDATE_COURIER_CONNECTIONAcciónReplace carrier-specific credentials on an existing courier account connection. Warning: this consequential credential rotation replaces the complete credential set; incorrect values can stop future tracking updates.
AFTERSHIP_UPDATE_COURIER_CONNECTIONAcciónReplace carrier-specific credentials on an existing courier account connection. Warning: this consequential credential rotation replaces the complete credential set; incorrect values can stop future tracking updates.
Parámetros de entrada
courier_connection_idstringObligatorioCourier connection ID returned by list or create.
carrier_account_fieldsobjectObligatorioComplete carrier-specific secret values keyed by the exact field names advertised for this connection's courier. Values are sent only to AfterShip and are never included in this action's output.
Parámetros de salida
dataanyObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
Update TrackingAFTERSHIP_UPDATE_TRACKINGAcciónUpdate editable order, courier, route, customer, and delivery metadata on an existing tracking record.
AFTERSHIP_UPDATE_TRACKINGAcciónUpdate editable order, courier, route, customer, and delivery metadata on an existing tracking record.
Parámetros de entrada
notestringReplacement internal note.
titlestringReplacement human-readable tracking title.
languagestringReplacement recipient ISO 639-1 language code.
order_idstringReplacement globally unique order identifier.
customersobject[]Replacement customer list, up to three.
last_mileobjectReplacement last-mile courier and tracking number. Send null explicitly to clear the existing last-mile value.
order_datestringReplacement order date-time.
location_idstringReplacement AfterShip fulfillment location ID; do not combine with explicit origin fields.
origin_citystringReplacement origin city.
pickup_notestringReplacement pickup instructions.
tracking_idstringObligatorioAfterShip tracking ID to update.
courier_slugstringReplacement courier slug.
order_numberstringReplacement human-readable order number.
origin_statestringReplacement origin state or province.
tracking_keystringReplacement additional carrier tracking credential.
custom_fieldsobjectReplacement non-personal custom string fields.
delivery_typestringenumReplacement delivery method.
pickup_at_storedoor_to_doorpickup_at_courierorder_id_pathstringReplacement URL for the order in the merchant system.
shipment_typestringReplacement carrier service type.
pickup_locationstringReplacement pickup location.
shipping_methodstringReplacement merchant-facing shipping method.
destination_citystringReplacement destination city.
destination_statestringReplacement destination state or province.
origin_postal_codestringReplacement origin postal code.
shipment_directionstringenumReplacement ecommerce fulfillment direction.
forwardreturntracking_ship_datestringReplacement shipment-ready date or date-time.
origin_raw_locationstringReplacement unstructured origin address.
origin_country_regionstringReplacement origin ISO 3166-1 alpha-3 country code.
destination_postal_codestringReplacement destination postal code.
tracking_account_numberstringReplacement carrier account number.
destination_raw_locationstringReplacement unstructured destination address.
destination_country_regionstringReplacement destination ISO 3166-1 alpha-3 country code.
order_promised_delivery_dateobjectReplacement promised delivery date or date range.
Parámetros de salida
dataanyObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not