AWB Printing

AWB (Air Waybill) printing allows merchants to generate and print shipping labels directly from the EasyStore admin panel without leaving the platform.

How It Works

  1. Merchant selects orders to print AWB from EasyStore admin panel
  2. Merchant clicks "Print AWB" button
  3. EasyStore sends a request to your registered AWB URL with order/fulfillment details
  4. Your app generates the shipping label from your logistics platform
  5. Your app returns the AWB URL for printing
┌─────────────────────────────────────────────────────────────────────────────────────────┐
│                              AWB Printing Flow                                          │
└─────────────────────────────────────────────────────────────────────────────────────────┘

┌──────────────┐    ┌──────────────┐    ┌──────────────┐    ┌──────────────┐
│   Merchant   │    │   EasyStore  │    │   Your App   │    │   Logistics  │
│  Admin Panel │    │    Server    │    │    Server    │    │     API      │
└──────┬───────┘    └──────┬───────┘    └──────┬───────┘    └──────┬───────┘
       │                   │                   │                   │
       │ 1. Select Orders  │                   │                   │
       │    Click "Print   │                   │                   │
       │    AWB" Button    │                   │                   │
       │ ─────────────────►│                   │                   │
       │                   │                   │                   │
       │                   │ 2. POST Request   │                   │
       │                   │ ─────────────────►│                   │
       │                   │ • order_id        │                   │
       │                   │ • fulfillment_id  │                   │
       │                   │ • shop domain     │                   │
       │                   │                   │                   │
       │                   │                   │ 3. Fetch AWB/Label│
       │                   │                   │ ─────────────────►│
       │                   │                   │ • tracking_number │
       │                   │                   │                   │
       │                   │                   │ 4. Return PDF/    │
       │                   │                   │    Label Data     │
       │                   │                   │ ◄─────────────────│
       │                   │                   │                   │
       │                   │ 5. Return AWB URL │                   │
       │                   │ ◄─────────────────│                   │
       │                   │ {                 │                   │
       │                   │   "type": "link", │                   │
       │                   │   "url": "..."    │                   │
       │                   │ }                 │                   │
       │                   │                   │                   │
       │ 6. Open AWB URL   │                   │                   │
       │ ◄─────────────────│                   │                   │
       │  (New Tab/Window) │                   │                   │
       │                   │                   │                   │
       │                   │                   │                   │
       ▼                   ▼                   ▼                   ▼

┌─────────────────────────────────────────────────────────────────────────────────────────┐
│  📄 PDF/Label Displayed                                                                 │
│  ┌───────────────────────────────────────────────────────────────────────────────────┐  │
│  │  ╔═══════════════════════════════════════════════════════════════════════════╗    │  │
│  │  ║                         SHIPPING LABEL                                    ║    │  │
│  │  ╠═══════════════════════════════════════════════════════════════════════════╣    │  │
│  │  ║  FROM:                          TO:                                       ║    │  │
│  │  ║  Merchant Store                 Customer Name                             ║    │  │
│  │  ║  123 Sender Street              456 Receiver Street                       ║    │  │
│  │  ║  City, State 12345              City, State 67890                         ║    │  │
│  │  ╠═══════════════════════════════════════════════════════════════════════════╣    │  │
│  │  ║  ████████████████████████████████████████                                 ║    │  │
│  │  ║  ██  BARCODE: EN813659438MY   ██                                         ║    │  │
│  │  ║  ████████████████████████████████████████                                 ║    │  │
│  │  ╚═══════════════════════════════════════════════════════════════════════════╝    │  │
│  └───────────────────────────────────────────────────────────────────────────────────┘  │
│  Merchant can print the label directly from browser                                     │
└─────────────────────────────────────────────────────────────────────────────────────────┘
      

Registering Your AWB URL

To register your AWB endpoints, please email dev@easystore.co with the following information:

  • Your app name
  • AWB URL endpoints for the topics you want to support:
    • awb/single - Single AWB printing
    • awb/bulk - Bulk AWB printing

EasyStore team will manually configure the endpoints for your app.

Request Headers

EasyStore includes the following headers with each AWB request:

Header Value
Easystore-Topic awb/single or awb/bulk
Easystore-Shop-Domain Store's EasyStore domain (e.g., myshop.easy.co)
Easystore-Hmac-Sha256 HMAC-SHA256 signature of payload using app secret
Content-Type application/json
User-Agent EasyStore

Request Format

Single AWB (awb/single)

Parameter Type Required Description
id int Yes Single order ID
fulfillment_id int Yes Fulfillment ID
fulfillment_order_id int Optional Fulfillment order ID
{
  "id": 12345,
  "fulfillment_id": 67890,
  "fulfillment_order_id": 11111
}
      

Bulk AWB (awb/bulk)

Parameter Type Required Description
ids array Yes Array of order IDs
{
  "ids": [12345, 12346, 12347]
}
      

Response Format

The response format is the same as the Order Fulfillment response format. Your endpoint can return different URLs to handle AWB-specific functionality.

Field Type Description
type string Either "link" (success) or "message" (error/info)
url string The redirect URL (only when type is "link")
message string Error/info message (only when type is "message")
style string Message style, e.g., "error" (only when type is "message")

Link Response (type: "link")

EasyStore will open the provided URL as an iframe within the Admin Panel. Return a URL that renders your AWB printing interface.

{
  "type": "link",
  "url": "https://apps.easystore.co/logistics/{app_handle}/awb?shop={shop}&order_id={id}"
}
      

Message Response (type: "message")

Display a toast notification in the Admin Panel for errors or information.

{
  "type": "message",
  "message": "AWB not available for this order",
  "style": "error"
}
      

Best Practice

💡 Tip: Show a "Print AWB" button on your fulfillment success page. After a successful fulfillment, display a "Print AWB" button directly in your success page. This provides a smoother operation flow for merchants, allowing them to immediately print shipping labels without navigating away.

Next Steps

Learn how to keep order status up-to-date with Parcel Status Update.

icon-accounticon-add-newicon-add-storeicon-appicon-appleicon-archiveicon-arrowdownicon-ascicon-bookicon-cancelicon-cart-addonicon-checkouticon-cherryicon-collectionicon-comfirmicon-confirmicon-couponicon-creditsicon-currencyicon-dashboardicon-discounticon-disintegrateicon-domainicon-dscicon-duplicateicon-editicon-emailicon-exclamation-triangleicon-exporticon-eyeicon-eye-slashicon-fullscreenicon-fullscreen-closeicon-generalicon-gifticon-gridicon-hddicon-helpicon-importicon-infoicon-integrationicon-invoiceicon-likeicon-listicon-locationicon-logouticon-new-tabicon-not-secureicon-optionicon-ordericon-outline-arrowdownicon-pageicon-paymenticon-plusicon-posicon-pricingicon-printericon-producticon-product-sumicon-product-sum-xicon-redirecticon-reporticon-reseticon-searchicon-secureicon-settingicon-shippingicon-staricon-storeicon-switch-storeicon-tagicon-taxesicon-templateicon-themeicon-tickicon-trashicon-unarchiveicon-uploadicon-user-tagicon-usersicon-weighticon-wholesale