checkout-ui-ext
Skill0 starsChanged 4 months agoMITView on GitHub
Scaffold a Shopify checkout UI extension with extension.toml and src/Checkout.jsx. Use when the user asks to create a checkout extension, add a banner or input to the checkout page, build an upsell widget for checkout, or scaffold a Shopify checkout UI extension.
In this repository5 other files it gives its agents.
- admin-api-querySkill
- liquid-sectionSkill
- shopify-functionSkill
- theme-auditSkill
- theme-initSkill
The file
We split this skill into the rules it gives an agent
12 rules. About 0 are common, 5 are distinctive, and 7 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈5
Distinctive · estimate
This author's own choices. Worth a look.
7
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 10
Create a Shopify checkout UI extension using React and the @shopify/ui-extensions-react/checkout package.
- Distinctive: line 18
Ask the user: "What should the extension do?" Example answers: show a banner, collect a gift note, offer a free item, display loyalty …
- Distinctive: line 19
Ask for the target. Common targets are:
- Distinctive: line 28
Read the generated extension files, announce each requested change, then make only the requested UI and configuration changes.
- Very specific: line 110
Keep the package.json, lockfile, and build scripts emitted by shopify app generate extension.
- Very specific: line 142
Every Banner has a title. Screen readers announce it as a region.
- Very specific: line 143
Use Text with appearance="subdued" rather than custom colors.
- Very specific: line 144
Never render raw HTML from a settings field.
- Very specific: line 148
Do not use api_version = "unstable" or omit the version.
- Very specific: line 149
Do not fetch from third-party domains without setting network_access = true in the extension TOML and declaring the domain in the app's …
- Distinctive: line 150
Do not include secret tokens in the extension bundle.
- Distinctive: line 151
Do not block checkout progress unless the extension has a clear validation reason and a visible error message for the buyer.
≈ “Common” is an estimate: at least 1 in 5 of the 213,895 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Scaffold a checkout UI extension
Create a Shopify checkout UI extension using React and the @shopify/ui-extensions-react/checkout package. Start with the files generated by the installed Shopify CLI, then make the minimum requested customization. This keeps package versions and target contracts aligned with the developer's CLI.
Inputs
$ARGUMENTS is an optional extension handle in kebab-case (for example upsell-banner). If empty, ask the user for the handle and purpose.
Workflow
- Ask the user: "What should the extension do?" Example answers: show a banner, collect a gift note, offer a free item, display loyalty points.
- Ask for the target. Common targets are:
purchase.checkout.block.render(flexible, merchant places it in the editor)purchase.checkout.delivery-address.render-beforepurchase.checkout.shipping-option-list.render-afterpurchase.checkout.payment-method-list.render-afterpurchase.checkout.reductions.render-afterpurchase.thank-you.block.render
- Confirm the parent Shopify app directory. Extensions live under
extensions/<handle>/. - Confirm before running
shopify app generate extension, choose the checkout UI template, and use the requested handle. The CLI owns the initial package versions and file layout. - Read the generated extension files, announce each requested change, then make only the requested UI and configuration changes. Retain the generated package versions unless the user is deliberately upgrading them.
- Print the commands to build and preview.
shopify.extension.toml
api_version = "2026-07"
[[extensions]]
name = "Upsell banner"
handle = "upsell-banner"
type = "ui_extension"
[[extensions.targeting]]
module = "./src/Checkout.jsx"
target = "purchase.checkout.block.render"
[extensions.capabilities]
network_access = false
block_progress = false
api_access = true
[extensions.settings]
[[extensions.settings.fields]]
key = "banner_title"
type = "single_line_text_field"
name = "Banner title"
description = "Heading shown in the checkout banner."
[[extensions.settings.fields]]
key = "banner_body"
type = "multi_line_text_field"
name = "Banner body"
description = "Body text shown in the checkout banner."Example src/Checkout.jsx
import {
reactExtension,
Banner,
BlockStack,
Text,
useApi,
useSettings,
useTranslate,
} from "@shopify/ui-extensions-react/checkout";
export default reactExtension(
"purchase.checkout.block.render",
() => <Extension />
);
function Extension() {
const translate = useTranslate();
const { extension } = useApi();
const { banner_title, banner_body } = useSettings();
const title = typeof banner_title === "string" && banner_title.length > 0
? banner_title
: translate("defaultTitle");
const body = typeof banner_body === "string" && banner_body.length > 0
? banner_body
: translate("defaultBody");
return (
<Banner title={title} status="info">
<BlockStack>
<Text>{body}</Text>
<Text size="small" appearance="subdued">
{translate("placement", { target: extension.target })}
</Text>
</BlockStack>
</Banner>
);
}Package versions and testing
Keep the package.json, lockfile, and build scripts emitted by shopify app generate extension. Shopify releases Checkout UI extension API packages in lockstep with API versions; the generated template prevents this skill from pinning a stale or nonexistent package version.
The Shopify CLI bundles the extension with its internal builder. You do not need Vite or Rollup. Calling shopify app build from the app root builds every extension in extensions/. For API 2026-04 or later, add focused unit tests with @shopify/ui-extensions-tester when the extension has logic beyond static display.
Locales: locales/en.default.json
{
"defaultTitle": "Special offer",
"defaultBody": "Add one more item to unlock free shipping.",
"placement": "Shown at {target}"
}Build and preview
From the app root:
shopify app devThis opens a tunnel, installs the extension on the development store, and shows a preview URL. Open the preview URL and walk through checkout to see the extension in the target position.
Capability notes
network_access = falsekeeps latency low and removes a surface for data leaks. Turn it on only if the extension must call your backend.block_progress = falsemeans the extension cannot stop a buyer from completing checkout. Turn it on only when the extension collects information that must be present before the order is placed (for example, a gift note). A blocking extension must useuseBuyerJourneyInterceptto validate.api_access = trueis required to read cart and buyer data through theuseApihooks.
Accessibility checks
- Every Banner has a
title. Screen readers announce it as a region. - Use
Textwithappearance="subdued"rather than custom colors. Shopify themes handle contrast. - Never render raw HTML from a settings field. Render only inside
<Text>or other Shopify UI components.
Do not
- Do not use
api_version = "unstable"or omit the version. Pin to a released version. - Do not fetch from third-party domains without setting
network_access = truein the extension TOML and declaring the domain in the app's Partner Dashboard. The CLI rejects deploys that call out to undeclared domains. - Do not include secret tokens in the extension bundle. The bundle is public.
- Do not block checkout progress unless the extension has a clear validation reason and a visible error message for the buyer.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

