The theme contract is what Tringify guarantees every hosted theme, and what a theme must do in return. Each rule below gives both sides. Where a gate is listed, a theme that breaks the rule is refused: themecheck gates run at upload, Theme Store publish and code save, and server gates refuse the request on the store. Advisory checks report a likely breach without refusing the theme. The Store MCP get_theme_contract tool returns the same rules, every ctx field and the setting types.
Phone numbers#
phone.countries#
The platform guarantees |
The theme must |
|---|---|
|
Build country pickers and phone fields only from |
Gate: none; the rule is not checked automatically. Advisory checks: themecheck bundled-countries warns at upload, Theme Store publish and code save. Fields: phone_countries*. Details: Customer and forms
phone.default#
The platform guarantees |
The theme must |
|---|---|
|
Start phone fields on |
Gate: none; the rule is not checked automatically. Fields: customer_settings.default_phone_country. Details: Customer and forms
phone.submit#
The platform guarantees |
The theme must |
|---|---|
Every phone input (sign-in, registration, add phone, addresses, contact form, back-in-stock, checkout) is checked on the server: valid for its country, inside the allowed list and stored as E.164. An invalid number is refused with a translated message. A Gift Card recipient's phone follows gift_card.recipient. |
Send one E.164 number (+ and digits). Bounding typing to |
Gate: the platform refuses with STOREFRONT_CUST_INVALID_PHONE or AUTH_PHONE_COUNTRY_NOT_ALLOWED (sign-in, registration, add phone, addresses, contact form, back-in-stock and checkout). Fields: forms.contact.phone*. Details: Customer accounts
phone.display#
The platform guarantees |
The theme must |
|---|---|
Every phone a theme shows has |
Show |
Gate: none; the rule is not checked automatically. Advisory checks: themecheck phone-display warns at upload, Theme Store publish and code save. Fields: customer.phone*, customer.addresses.items[].phone*, customer.order.contact.phone*, address.phone*, cart.items[].gift_card_recipient.phone*. Details: Customer and forms
Money#
money.formatted#
The platform guarantees |
The theme must |
|---|---|
Every price, total and amount comes formatted for the page language and the shopper's country (en-IN groups in lakhs). |
Output the formatted value, or the price through the |
Gate: none; the rule is not checked automatically. Advisory checks: themecheck money-arithmetic, money-filter, money-symbol, money-decimals warn at upload, Theme Store publish and code save. Fields: price.*, price_range.*, money_input.*, presented_money.*, *.formatted. Details: Money and languages
money.note#
The platform guarantees |
The theme must |
|---|---|
|
Print the notes as given with the product price and the cart total (on every cart surface), and print nothing for a null note. Let the merchant choose where they show and which of the three show (a Price notes block with tax, shipping and duty choices), and show them by default. Never override their text, and do not compose tax, shipping or duty notes from |
Gate: the platform refuses with THEME_IMPORT_INVALID_TEMPLATE (theme upload, Theme Store publish and code save: the product and cart pages). Fields: product.price_notes, cart.price_notes, product.price_note, cart.price_note. Details: Money and languages
Numbers#
number.formatted#
The platform guarantees |
The theme must |
|---|---|
Counts and measures that need locale formatting come formatted. |
Never format numbers in the theme. |
Gate: none; the rule is not checked automatically. Details: Money and languages
Dates and times#
time.display#
The platform guarantees |
The theme must |
|---|---|
A time the shopper relies on comes ready to show beside its RFC 3339 value, in a field ending |
Print the |
Gate: none; the rule is not checked automatically. Advisory checks: themecheck time-display warns at upload, Theme Store publish and code save. Fields: cart.items[].gift_card_recipient.deliver_at_display, customer.gift_cards.items[].sent_at_display, customer.gift_cards.items[].scheduled_at_display. Details: Gift Cards in your theme
Countries and addresses#
address.form#
The platform guarantees |
The theme must |
|---|---|
|
Build address forms only from |
Gate: none; the rule is not checked automatically. Advisory checks: themecheck bundled-countries warns at upload, Theme Store publish and code save. Fields: customer.address_form*. Details: Customer and forms
address.server#
The platform guarantees |
The theme must |
|---|---|
The server validates addresses (country, subdivision, postal code rules such as Indian pincodes) and refuses an invalid one with a translated message. |
Don't add validation rules of your own that differ from the server's. |
Gate: the platform refuses with STOREFRONT_CUST_COUNTRY_CODE_INVALID, SUBDIVISION_INVALID, VALIDATE_POSTAL_INVALID_FORMAT or VALIDATE_POSTAL_PINCODE_STATE_MISMATCH (customer addresses and checkout). Details: Customer accounts
Messages and labels#
messages.localized#
The platform guarantees |
The theme must |
|---|---|
Every result of a hosted action comes back as a localized message ( |
Show the platform's message. Never write your own error or success copy for a platform action. |
Gate: none; the rule is not checked automatically. Fields: form_error*, form_notice*, auth_notice*. Details: Response messages
labels.localized#
The platform guarantees |
The theme must |
|---|---|
Statuses, consent text, blocked reasons and filter labels come resolved for the shopper's language. |
Show the given label. Never map codes to words of your own. |
Gate: none; the rule is not checked automatically. Fields: *status_display, *.happened_at_display, *_label, *.status_name, *.display_value. Details: CTX overview
Store data#
ctx.needs#
The platform guarantees |
The theme must |
|---|---|
A section gets exactly the ctx roots its schema declares in |
Declare every root a section reads. |
Gate: themecheck ctx-read refuses the theme at upload, Theme Store publish and code save. Details: Section schema
ctx.contract#
The platform guarantees |
The theme must |
|---|---|
ctx carries only the fields in the published contract. |
Read only contract fields. |
Gate: themecheck ctx-path refuses the theme at upload, Theme Store publish and code save. Fields: every ctx field. Details: CTX overview
metafields.declared#
The platform guarantees |
The theme must |
|---|---|
Installing a theme creates exactly the metafield definitions in |
Declare every metafield the theme's sections and blocks read. |
Gate: themecheck metafield-undeclared refuses the theme at upload, Theme Store publish and code save. Fields: *.metafields*. Details: Metafields in themes
metafields.block#
The platform guarantees |
The theme must |
|---|---|
The platform metafield block ( |
The section that shows the page's own item (on a product, collection, category, vendor, brand, page or blog post template, the first section reading that item) must accept blocks ( |
Gate: none; the rule is not checked automatically. Advisory checks: themecheck metafield-block warns at upload, Theme Store publish and code save. Details: Metafields in themes
Settings#
settings.gate_pages#
The platform guarantees |
The theme must |
|---|---|
Required gate sections receive translated title and message settings; coming-soon notification outcomes and password errors are supplied as localized section settings. |
Read settings.title and settings.message on coming_soon, password and maintenance; read settings.notify_state and show settings.notify_success, settings.notify_error or settings.password_error when supplied, and require explicit consent in /notify forms. |
Gate: none; the rule is not checked automatically. Advisory checks: themecheck gate-text, notify-consent warn at upload, Theme Store publish and code save. Details: Gate pages
settings.ids#
The platform guarantees |
The theme must |
|---|---|
A product, collection, category, page, blog post or image setting stores the chosen item's id, and the template reads the item itself. |
Store ids, never slugs or handles. A theme package's templates may name only items of its own demo catalogue, by their demo handle; installing the theme clears them. |
Gate: themecheck setting-values refuses the theme at upload, Theme Store publish and code save; the platform refuses with THEME_SETTING_RESOURCE_ID_INVALID (theme editor save). Advisory checks: themecheck demo-picks warns at upload, Theme Store publish and code save. Details: Bound settings
settings.complete#
The platform guarantees |
The theme must |
|---|---|
The theme editor shows every setting a section, block or the theme declares with its label in the merchant's language (en, de, es, fr, it), the picker for its type, and its default until the merchant changes it. |
Ship every new setting complete: a label key defined in every editor language file (locales/ |
Gate: themecheck setting-missing-label refuses the theme at upload, Theme Store publish and code save. Advisory checks: themecheck setting-type-mismatch warns at upload, Theme Store publish and code save. Details: Section schema
settings.no_orphans#
The platform guarantees |
The theme must |
|---|---|
A store's saved setting values (section and block settings on every page, their translations and theme settings) carry over every code save and theme update through the migrations the schemas declare. |
When you rename, move or remove a setting, declare it in the schema's migrations so stored values move with it: rename_setting, move_setting or settings_to_blocks to keep a value, remove_setting to drop it on purpose. config/settings_schema.json takes rename_setting and remove_setting. A code save that would leave a store's saved value without its setting is refused, and so is a Theme Store version that drops a setting of the listing's latest version without a migration. |
Gate: the platform refuses with THEME_CODE_ORPHANS_SETTING_VALUES (code save: the code editor, Store MCP save_theme_code, theme sync, a zip uploaded into a theme and Theme Store updates); the platform refuses with THEME_VERSION_ORPHANS_SETTINGS (Theme Store publish, against the listing's latest version). Details: Section schema
Images#
images.widths#
The platform guarantees |
The theme must |
|---|---|
When a store image is added, its 640 and 1080 px versions are prepared in the background as soon as it is stored. A bulk import prepares them only for the images listings show first: each product's first image and each category, brand and vendor image. Every other width, and every other image, is prepared on its first request, which waits for it once. |
Use |
Gate: none; the rule is not checked automatically. Details: Platform filters
Customer account#
account.email_confirmation#
The platform guarantees |
The theme must |
|---|---|
|
When |
Gate: none; the rule is not checked automatically. Advisory checks: themecheck account-sign-in-forms warns at upload, Theme Store publish and code save. Fields: customer.email, customer.email_verified. Details: Customer accounts
account.forms_truthful#
The platform guarantees |
The theme must |
|---|---|
Every hosted account action accepts the multipart post the bridge sends and answers success only once the change is stored; otherwise it refuses with a translated message (such as |
Show the platform's message. Offer the email marketing opt-in only when |
Gate: none; the rule is not checked automatically. Fields: customer.accepts_marketing. Details: Customer accounts
Gift Cards#
gift_card.recipient#
The platform guarantees |
The theme must |
|---|---|
When a Gift Card product is added to the cart or bought now, the platform checks the recipient: an email or a phone number in international format (+ and the country code, any country; stored as E.164), a name and a message within the lengths in |
On every form that adds a Gift Card product ( |
Gate: the platform refuses with GIFT_CARD_INVALID (cart_add and buy_now for a Gift Card product). Fields: product.is_gift_card, cart.items[].gift_card_recipient*, forms.cart_add*, forms.buy_now*. Details: Gift Cards in your theme
gift_card.message#
The platform guarantees |
The theme must |
|---|---|
The platform owns the Gift Card page's routes, lookups and refusals. After a balance check that fails for any reason, or on a view link that opens nothing, |
Show the platform's message as given. Do not write your own not-found or reason text, and do not tell a wrong code apart from any other refusal. |
Gate: none; the rule is not checked automatically. Fields: gift_card, form_error*. Details: Gift Cards in your theme
gift_card.code#
The platform guarantees |
The theme must |
|---|---|
|
Print a code only where it is not null, and show |
Gate: none; the rule is not checked automatically. Fields: gift_card.code*, customer.gift_cards.items[].code*. Details: Gift Cards in your theme
Editing#
editing.merchant_editable#
The platform guarantees |
The theme must |
|---|---|
Merchants change their store's look and words in the theme editor, in their own language, without touching code, and keep those changes through theme updates. |
Take visible copy, images, links, colours and layout choices from section, block or theme settings, or from locale keys through the t filter, never from literals in markup or section CSS. Text without letters (digits, punctuation, symbols such as × or →) is not copy; black or white with transparency for shadows and scrims is not a palette colour. |
Gate: themecheck hardcoded-copy refuses the theme at upload, Theme Store publish and code save; themecheck hardcoded-asset-url refuses the theme at upload, Theme Store publish and code save; themecheck hardcoded-color refuses the theme at upload, Theme Store publish and code save. Details: Section schema
editing.prefer_settings#
The platform guarantees |
The theme must |
|---|---|
Template and setting values (the theme editor, templates/ |
When a change can be made through template or setting values, make it there instead of in code. Change code only for a new capability, and ship every new choice it brings as a setting, complete (settings.complete). |
Gate: none; the rule is not checked automatically. Details: Section schema
live.edits#
The platform guarantees |
The theme must |
|---|---|
A connected tool or app never changes the live theme directly. Its writes to the live theme (code, theme settings, sections and blocks) are saved to its own pending copy of the live theme, checked and rendered there; shoppers see them only after the merchant reviews them in Store Admin or the mobile app and publishes them. Publishing applies them to the live theme as one change in its history, which can be undone. |
Render correctly from a theme that is not live: every page works when previewed from a copy, and nothing depends on the theme's ID or on being the live theme. |
Gate: none; the rule is not checked automatically. Details: Connector OAuth and MCP reference
Platform updates#
stability#
The platform guarantees |
The theme must |
|---|---|
A published theme keeps rendering the same way as the platform adds features: names and types stay, filters keep their arguments and output, and checks added later apply only to new versions. |
Build only against behavior the docs describe, and check optional data before using it. |
Gate: none; the rule is not checked automatically. Details: Theme stability