DOCS

Order metafields

Order metafields

Access Zonos order data directly from your Shopify orders.

Zonos writes order details to Shopify order metafields under the zonos namespace. This gives you direct access to Zonos order IDs, item-level cost breakdowns, and duty/tax/fee subtotals without needing to call the Zonos API separately.

These metafields are available on every Shopify order processed through Zonos and can be accessed via the Shopify Admin API, Shopify Flow, or any tool that reads order metafields.

Available metafields 

Zonos writes three metafields to each Shopify order, all under the zonos namespace.

zonos_id

The unique Zonos order ID linked to this Shopify order. Use this ID to look up the full order in Zonos Dashboard or via the Zonos API.

Example value

order_19d69db6-450f-45a7-a4a1-c678c7d7dd90

zonos_subtotals

A JSON object containing the aggregated duty, tax, fee, and shipping totals for the order.

Example value

{
  "duties": 0,
  "taxes": 400.39,
  "fees": -78.93,
  "shipping": 966.87
}
FieldDescription
dutiesTotal duty amount for the order.
taxesTotal tax amount for the order.
feesTotal fees for the order. Negative values indicate credits or adjustments.
shippingTotal shipping cost for the order.

zonos_items

A JSON array containing item-level cost breakdowns. Each item includes amounts in both the customer's paid currency and your shop's base currency.

Example value

[
  {
    "amount": 830.53,
    "productId": "49380521509183",
    "currencyCode": "CAD",
    "paidAmount": {
      "amount": 830.53,
      "currencyCode": "CAD"
    },
    "shopAmount": {
      "amount": 606.85,
      "currencyCode": "USD"
    }
  }
]
FieldDescription
amountItem amount in the customer's currency.
productIdThe Shopify product ID for this item.
currencyCodeThe currency the customer paid in.
paidAmount.amountThe amount the customer paid for this item.
paidAmount.currencyCodeCurrency of the paid amount.
shopAmount.amountThe equivalent amount in your shop's base currency.
shopAmount.currencyCodeYour shop's base currency code.

Accessing metafields 

You can access these metafields through any method that supports reading Shopify order metafields:

  • Shopify Admin API (GraphQL or REST)
  • Shopify Flow for automating workflows based on Zonos order data
  • Third-party apps that read order metafields (e.g., reporting tools, ERPs)

Example: Query via Shopify GraphQL API

Shopify GraphQL query

query OrderZonosMetafields($orderId: ID!) {
  order(id: $orderId) {
    metafields(namespace: "zonos", first: 10) {
      edges {
        node {
          key
          value
        }
      }
    }
  }
}
Book a demo

Was this page helpful?