Every token in a render slug carries a prefix that says how to resolve it.
| Prefix | Means | Use it for |
|---|---|---|
| (none) | our internal id | internal tools and debugging |
s | a text slug | anything a person reads or edits |
p | the shop’s internal id | storefront templates |
pe | the shop’s external id | storefronts keyed on an external id |
Why p and pe matter
With those, the page hands us its own identifiers, a product id, an option id, and gets a render back without ever learning our numbering. No mapping table on your side.
s. Numeric ids are not guaranteed to survive a re-import, and the URL will 404 the day they change.
Prefer s for anything you store
Text slugs survive a re-import; numeric ids are not guaranteed to. If a URL is kept anywhere
outside the platform, a CMS, a PIM, a spreadsheet, build it with s.
What to reuse
Troubleshooting
A URL that looks right returns a 404
A bare number is read as our internal id. If you are passing a shop product id, it needs the
p prefix.
URLs stopped working after a re-import
They were built with numeric ids. Rebuild them with the s prefix.