If you're integrating with the SKULabs API and encountering a validation error on purchase_order/create, you may be wondering why store_id is required — especially if the stores returned by store/get look like connected sales channels rather than document configuration scopes.
This article explains what a "store" represents in SKULabs, why store_id is required for POs, and how to determine which one to use.
What is a "store" in SKULabs?
In SKULabs, a store is the configuration scope for a specific selling channel or logical storefront within an account. It is not limited to a single Shopify or Amazon connection — an account may have multiple stores representing different channels (Shopify, Amazon, Walmart, a manual store, etc.), and each store can carry its own distinct settings.
Why store_id is required on Purchase Orders
store_id is required because it determines which store-level configuration applies to the Purchase Order. This includes:
Document templates — PO PDF, print, and email templates can be configured per store. The
store_idtells SKULabs which template and branding settings to use when generating the PO.Business identity fields — Stores can have different logos, addresses, return addresses, and contact details. The
store_idtells SKULabs which identity to render in the PO header and footer.Multi-store separation — In multi-store accounts,
store_idprovides a consistent scope so POs can be created, listed, and managed against the intended store configuration without ambiguity.
How to find the right store_id
Call
store/getto retrieve the stores associated with the account.Identify the correct store record for the account.
Use that store's
store_idin yourpurchase_order/createrequest.
Which store_id should I use?
Single-store accounts — Use the one available store_id.
Multi-store accounts — Use the store that should "own" the PO's document output and configuration — that is, the store whose template, logo, and address fields should appear on the generated PO. If unsure, advise the account holder to use their primary store, or the store whose PO template they want applied.
Summary
store_id is required because SKULabs stores are the configuration context for PO templates and branding. It is not just a commerce channel identifier — it is how SKULabs resolves which template, identity fields, and store-specific document settings to apply when generating or rendering the Purchase Order.
