Developers
Start building
AI/Tool reference/Storefront/Storefront style

Storefront style

The 16 tools of the Storefront style toolset in the Storefront area, with their permissions, approval rules and inputs.

On this page

Toolset storefront_style, 16 tools.

Records

brand

The store's brand that the theme, emails and share images draw from: logo, dark logo, icon, primary and accent colours, slogan and description per language, and social links. There is one record; pass any id, e.g. "current".

  • Permission: settings.read
  • Tools: brand_get

Actions

brand_update

Change the store's logo, icon, colours, slogan, description or social links; what is not given stays.

Writes over the version it read, so a brand someone saved in between is refused rather than overwritten; read brand_get again then.

  • Action key: brand.update
  • Permission: settings.write
  • Approval: Waits for approval when the store requires it for this action.
  • Effect: Changes the live store.
  • Retries: runs at most once; a repeat with the same idempotency key returns the first result.
FieldTypeRequiredDescription
logostring or nullA media library file as media://<id> (theme_media_search finds one), or null to clear it
logo_darkstring or nullA media library file as media://<id> (theme_media_search finds one), or null to clear it
iconstring or nullA media library file as media://<id> (theme_media_search finds one), or null to clear it
colorsobject
colors.primarystring or null#rrggbb, or null to clear it
colors.accentstring or null#rrggbb, or null to clear it
sloganmap of stringBy language code; an empty text removes that language
descriptionmap of stringBy language code; an empty text removes that language
sociallist of objectReplaces every social link; https addresses on each platform own host. at most 12 items
social[].platformstringyesone of "instagram", "facebook", "tiktok", "youtube", "pinterest", "linkedin", "x", "threads", "discord"
social[].urlstringyes1 to 300 characters

Example inputs:

{
  "colors": {
    "accent": "#c2410c"
  }
}
{
  "slogan": {
    "hu": "Minden, ami játék"
  }
}

theme_banner_set

Add or change an announcement bar or promo, discount or newsletter pop-up.

Add, change, schedule, switch off or delete one storefront banner: an announcement bar, a discount, newsletter or promo pop-up, a slide-in card, an age gate or a maintenance or coming-soon page. Pop-ups open immediately, after a delay, on scroll or on exit intent (trigger), on all or chosen pages, devices and audiences, between starts_at and ends_at. The cookie banner, language suggestion and newsletter pop-up overlay are platform pop-ups edited as sections, not here.

  • Action key: theme_banner.set
  • Permission: theme.write
  • Approval: Waits for approval when the store requires it for this action.
  • Effect: Changes a draft; nothing goes live until it is published.
  • Retries: runs at most once; a repeat with the same idempotency key returns the first result.
FieldTypeRequiredDescription
theme_idstringTheme ID. Omit to use the store active theme, or the only theme if none is marked active.
banner_idstringThe banner to change, from theme_customizer_get banners; omit to add one
templatestringA new banner starts from this template: announcement (a bar on top), discount (a pop-up with a code), newsletter (a sign-up pop-up), slide_in_promo (a corner card), age_gate, maintenance, coming_soon (full-page takeovers) or blank. one of "announcement", "age_gate", "newsletter", "discount", "slide_in_promo", "maintenance", "coming_soon", "blank"
namestringAdmin name; a new banner needs one. 1 to 80 characters
enabledboolean
deletestringRemoves the banner named by banner_id. always true
layoutstringone of "bar", "modal", "slide_in", "fullscreen"
positionstringone of "top", "bottom", "center", "bottom_left", "bottom_right"
contentobjectWords in the theme's base language (overview locales.base_locale)
content.eyebrowstring
content.headingstring
content.bodystring
content.notestring
content.image_altstring
content.primary_labelstring
content.secondary_labelstring
content.imagestringA media: ref from theme_media_search, or "" for none
content.primary_hrefstringWhere the main button goes: /path or https URL
content.codestringDiscount code shown with a copy button
content.newsletter_formbooleanShows the newsletter sign-up form
content.countdown_tostringISO date-time with zone, counts down to it
translationsmap of objectThe same words in other store languages, keyed by language (hu, en)
styleobject#rrggbb or var(--token) colours; accent paints the button
style.backgroundstring
style.textstring
style.accentstring
style.accent_textstring
triggerobject
trigger.typestringone of "immediate", "delay", "scroll", "exit_intent"
trigger.delay_secondsintegerat least -9007199254740991
trigger.scroll_percentintegerat least -9007199254740991
frequencystringHow often one shopper sees it. one of "always", "session", "once", "days"
rulesobjectWhere and when it shows: pages include/exclude use paths; starts_at and ends_at are YYYY-MM-DD store days or ISO date-times with zone, "" for open
rules.pagesstringone of "all", "home", "include", "exclude"
rules.pathslist of string
rules.devicesstringone of "all", "desktop", "mobile"
rules.audiencestringone of "all", "guests", "customers"
rules.starts_atstring
rules.ends_atstring

Example input:

{
  "template": "announcement",
  "name": "Free shipping",
  "content": {
    "heading": "Free shipping over 50 EUR"
  }
}

theme_base_locale_set

Make another language the one the theme's base copy is written in.

Make locale the language the theme's base copy is written in, when the store's default language is not the theme's (overview base_locale). Text that language already has becomes the base; the old base moves to its own overlay; untranslated text keeps its old wording.

  • Action key: theme_base_locale.set
  • Permission: theme.write
  • Approval: Always waits for a person to approve it.
  • Effect: Changes a draft; nothing goes live until it is published.
  • Destructive: in compact mode it runs with run_destructive_action.
  • Retries: runs at most once; a repeat with the same idempotency key returns the first result.
FieldTypeRequiredDescription
theme_idstringTheme ID. Omit to use the store active theme, or the only theme if none is marked active.
localestringyesTwo or three letter language code such as "hu"

Example input:

{
  "locale": "hu"
}

theme_color_scheme_set

Add a named colour scheme or change one.

Change one named colour scheme (its colours or name) or add a new one. Every section, block and pop-up that picks the scheme through its color_scheme setting follows it; to recolour just one section, pick a scheme for it with theme_section_update instead. Answers with contrast warnings where text would read poorly.

  • Action key: theme_color_scheme.set
  • Permission: theme.write
  • Approval: Waits for approval when the store requires it for this action.
  • Effect: Changes a draft; nothing goes live until it is published.
  • Retries: runs at most once; a repeat with the same idempotency key returns the first result.
FieldTypeRequiredDescription
theme_idstringTheme ID. Omit to use the store active theme, or the only theme if none is marked active.
scheme_idstringThe scheme to change, from theme_customizer_get color_schemes; omit to add one
namestringA new scheme needs one; given with scheme_id it renames the scheme. 1 to 40 characters
copy_fromstringA new scheme starts from this scheme's colours; defaults to the first scheme
colorsmap of stringOnly the colours to change, as #rrggbb: background, foreground, primary, primary_foreground, secondary, muted, border, accent, button, button_label. button and button_label paint the buttons drawn in the scheme; foreground is its text

Example input:

{
  "name": "Dark",
  "colors": {
    "background": "#111111",
    "foreground": "#ffffff"
  }
}

theme_locale_keys_get

The theme's locale-file texts for one language, by flat key.

Read flattened locale-file keys for a locale, optionally filtered by prefix.

  • Action key: theme_locale_keys.get
  • Permission: theme.read
  • Approval: Runs without approval.
  • Effect: Reads only.
  • Retries: safe to repeat with the same input.
FieldTypeRequiredDescription
theme_idstringTheme ID. Omit to use the store active theme, or the only theme if none is marked active.
localestringyesLocale code such as "en" or "hu"
prefixstringReturn only keys equal to prefix or nested under it

Example input:

{
  "locale": "hu",
  "prefix": "cart"
}

theme_locale_keys_update

Merge entries into one language's locale file.

Merge locale-file entries for a locale.

  • Action key: theme_locale_keys.update
  • Permission: theme.write
  • Approval: Waits for approval when the store requires it for this action.
  • Effect: Changes a draft; nothing goes live until it is published.
  • Retries: runs at most once; a repeat with the same idempotency key returns the first result.
FieldTypeRequiredDescription
theme_idstringTheme ID. Omit to use the store active theme, or the only theme if none is marked active.
localestringyesLocale code to write
entriesmap of any valueyesLocale JSON object merged into the locale file

Example input:

{
  "locale": "hu",
  "entries": {
    "cart": {
      "title": "Kosár"
    }
  }
}

theme_og_image_get

How the draft draws the share image of a page kind (the picture links show on social sites and chats), and what the merchant may change about it.

  • Action key: theme_og_image.get
  • Permission: theme.read
  • Approval: Runs without approval.
  • Effect: Reads only.
  • Retries: safe to repeat with the same input.
FieldTypeRequiredDescription
theme_idstringTheme ID. Omit to use the store active theme, or the only theme if none is marked active.
kindstringyesWhich share image: default, product, collection, article or page. one of "default", "product", "collection", "article", "page"

Example input:

{
  "kind": "product"
}

theme_og_image_preview

Draw the draft's share image of a page kind with a real page's data, optionally with a design not saved yet. Nothing is stored.

  • Action key: theme_og_image.preview
  • Permission: theme.write
  • Approval: Runs without approval.
  • Effect: Reads only.
  • Retries: safe to repeat with the same input.
FieldTypeRequiredDescription
theme_idstringTheme ID. Omit to use the store active theme, or the only theme if none is marked active.
kindstringyesWhich share image: default, product, collection, article or page. one of "default", "product", "collection", "article", "page"
subject_idstringThe product, collection, article or page to draw it for
localestringat most 16 characters
designmap of any valueThe design to try, in the shape theme_og_image_get answers; the draft's saved one when omitted

Example input:

{
  "kind": "product",
  "subject_id": "019bb58e-0ec1-79c1-9f40-d39d8d07674b"
}

theme_preset_apply

Set every look setting of the draft to a preset's values.

Apply a design preset to the draft: every look setting takes the preset value, or the shipped default where the preset has none. Content settings and layouts stay. preset_id "default" restores the shipped look.

  • Action key: theme_preset.apply
  • Permission: theme.write
  • Approval: Waits for approval when the store requires it for this action.
  • Effect: Changes a draft; nothing goes live until it is published.
  • Retries: runs at most once; a repeat with the same idempotency key returns the first result.
FieldTypeRequiredDescription
theme_idstringTheme ID. Omit to use the store active theme, or the only theme if none is marked active.
preset_idstringyesPreset id from theme_preset_list. at least 1 characters

Example input:

{
  "preset_id": "default"
}

theme_preset_list

The theme's design presets with their swatches, and which is the current look.

List the theme's design presets: id, label, colour swatches and whether it is the current look. A preset sets the look settings (colours, fonts, shapes) in one step.

  • Action key: theme_preset.list
  • Permission: theme.read
  • Approval: Runs without approval.
  • Effect: Reads only.
  • Retries: safe to repeat with the same input.
FieldTypeRequiredDescription
theme_idstringTheme ID. Omit to use the store active theme, or the only theme if none is marked active.
localestringLanguage for the labels, such as "hu"; defaults to the admin language

Example input:

{}

theme_preview_get

A preview link of the theme draft, or of the published theme.

Create a customizer preview and return its preview_url. The draft URL carries a signed token showing unpublished changes; the plain storefront keeps showing the published theme until theme_publish runs.

  • Action key: theme_preview.get
  • Permission: theme.read
  • Approval: Runs without approval.
  • Effect: Reads only.
  • Retries: safe to repeat with the same input.
FieldTypeRequiredDescription
theme_idstringTheme ID. Omit to use the store active theme, or the only theme if none is marked active.
sourcestringPreview source; defaults to draft. one of "draft", "published"

Example input:

{}

theme_settings_get

The theme's settings groups with their fields and current values.

Get settings groups, field defs, and current values. Pass group to narrow.

  • Action key: theme_settings.get
  • Permission: theme.read
  • Approval: Runs without approval.
  • Effect: Reads only.
  • Retries: safe to repeat with the same input.
FieldTypeRequiredDescription
theme_idstringTheme ID. Omit to use the store active theme, or the only theme if none is marked active.
groupstringSettings group id to return alone

Example input:

{
  "group": "colors"
}

theme_settings_translate

AI-translate the theme-wide texts (menus, announcement bar, store name) into a language.

AI-translate the theme-wide text (menu labels, announcement bar, store name, other settings copy) from the base language into target_locale and save it. By default only text without a current translation; theme_translate covers a whole language including pages.

  • Action key: theme_settings.translate
  • Permission: theme.write and translation.use
  • Approval: Waits for approval when the store requires it for this action.
  • Effect: Changes a draft; nothing goes live until it is published.
  • Retries: runs at most once; a repeat with the same idempotency key returns the first result.
FieldTypeRequiredDescription
theme_idstringTheme ID. Omit to use the store active theme, or the only theme if none is marked active.
target_localestringyesLanguage to translate into. 2 to 16 characters
pathslist of stringSettings text paths such as "menus.primary.0.label"; omit for all of them. at least 1 characters
forcebooleanAlso replace the listed paths where a person wrote the translation

Example input:

{
  "target_locale": "de"
}

theme_settings_update

Merge theme settings by their flat dot paths into the draft.

Merge flat (dot-path) theme settings. Menus are arrays: use theme_menu_add_item or theme_menu_remove_item.

  • Action key: theme_settings.update
  • Permission: theme.write
  • Approval: Waits for approval when the store requires it for this action.
  • Effect: Changes a draft; nothing goes live until it is published.
  • Retries: runs at most once; a repeat with the same idempotency key returns the first result.
FieldTypeRequiredDescription
theme_idstringTheme ID. Omit to use the store active theme, or the only theme if none is marked active.
flatmap of any valueyesDot-path settings values to merge. The header and footer are sections of the layout.header and layout.footer groups; their scroll, transparency and mobile menu settings are section settings, not theme settings.

Example input:

{
  "flat": {
    "colors.accent": "#c2410c"
  }
}

theme_translate

AI-translate the theme's texts and section copy from its base language into another.

AI-translate theme locale keys and section copy from the theme's base language (overview base_locale) into a target locale.

  • Action key: theme.translate
  • Permission: theme.write and translation.use
  • Approval: Waits for approval when the store requires it for this action.
  • Effect: Changes a draft; nothing goes live until it is published.
  • Retries: runs at most once; a repeat with the same idempotency key returns the first result.
FieldTypeRequiredDescription
theme_idstringTheme ID. Omit to use the store active theme, or the only theme if none is marked active.
target_localestringyesLocale to translate into; the base language itself is a no-op
only_missingbooleanOnly fill missing keys; defaults to true

Example input:

{
  "target_locale": "de"
}
Last updated