How POP manages customer fiscal data on Shopify
Goal
Understand where POP reads the customer’s fiscal data from (customer type, VAT number, Tax Code, PEC) and where to manually correct it before invoicing.
Prerequisites
- Access to Shopify Admin (order and/or customer).
Steps
POP uses two mechanisms for the customer’s fiscal data on an order:
- Order metafields
app.pop_*— structured fields automatically created by POP (pop_customer_type,pop_vat,pop_tax_code,pop_pec), populated from checkout (Checkout Extension on Shopify Plus, embed script on non-Plus) or from automatic detection from customer data. If pinned in Shopify Admin, they are visible and editable directly by the operator. - Order customAttributes (“Additional details”) — legacy, unstructured mechanism, used as a fallback when the corresponding metafields are not set.
Priority: when POP generates a document, it first reads the order app.pop_* metafields; it falls
back to customAttributes only if the corresponding metafields are absent.
The customer metafields (same namespace/keys) store the same data on the customer profile to prefill subsequent checkouts.
Fixing a fiscal data point before invoicing
- Open the order in Shopify Admin.
- Edit the relevant
app.pop_*order metafield (it must be pinned to be visible). - Save: the next generation will immediately use the updated value.
If the metafields have not been created (e.g. the POP wizard/license is not completed), the app shows a recovery section on the Home page with a button to recreate them manually.
Verify
- Generate a document for an order with the
app.pop_vatmetafield set to a value different from the corresponding customAttribute: the document must use the metafield value. - After editing a pinned order metafield, regenerate the document and verify that the new value was used.
Common errors
- I don’t see fiscal fields on the order or the customer — check that the POP wizard/license are
completed and that the
pop_*metafields have been created; if missing, use the recreation button from the Home page. - I fixed the customAttribute but the invoice doesn’t change — order metafields always take priority: fix the metafield, not the customAttribute.
- Non-Plus store, POS, or manual orders — on these channels the data might not be collected at checkout: it must be entered manually into the order metafields before invoicing (see shopify-non-plus-billing-fields for collection via the theme).
Related configuration
For the customer’s billing address on a specific order, see shopify-billing-address-override. For the seller’s address, see shopify-seller-fiscal-data.