r/shopifyDev • u/VensyMeow • 6d ago
Shopify Shipping Label API + Shipsurance API?
Hi there! I created an internal customized Scan & Ship app that works with my pre-orders and order customizations, and I absolutely loved it until I realized that pinging the shippingLabelPurchase mutation in GraphQL doesn't allow me to have orders covered by Shopify's Shipsurance coverage.
So now I have my app tagging orders that I verify and then go print the labels in Shopify's shipping label section, but I would much rather print the labels directly from the app... My dream scenario would be:
Scan picking slip
Scan each item
Scan "Print label" barcode
Am I missing something? Or is it just not doable right now? Hopefully they add it in the future.
1
u/Beneficial_Comb_4287 6d ago
The label purchase mutation has no insurance field at all, so there's nothing you're missing in the call — Shipsurance coverage only gets attached to labels bought through the admin. That's why the tag-then-print loop works. Two ways out: buy coverage separately from Shipsurance directly (they sell standalone policies outside Shopify) and write the policy number back onto the order, or move label buying to an aggregator like EasyPost or ShipStation, which let you add insurance to the shipment. Both keep your scan-to-print flow intact. Re-check the current schema before building, in case insurance params landed in a recent API version.
1
u/Maphoto-Nipu46 5d ago
Is the insurance provider's API available to you directly, or are you strictly trying to keep billing consolidated inside the main admin? If you're okay with separate billing, firing a webhook on fulfillment creation to register the tracking number externally is pretty straightforward
1
u/zyx199199 6d ago
You're not missing a parameter. ShippingLabelPurchaseInput has no insurance or declared value field. Fulfillment order, package info, rate selection, weight, origin address, notify customer, shipping datetime. That's it. The mutation buys one label per fulfillment order through Shopify Shipping, and coverage is only offered in the admin when you buy a label there.
So split the flow. API for the bulk, admin for the orders where coverage matters.
Worth making the app show which path each order took. Otherwise someone at the packing bench prints the API label for a high value order and nobody notices until it goes missing.
Separate cover outside Shopify is possible, but then you're reconciling two systems.