Repository navigation
Add typed JSON output to app dev clean - #8818
Conversation
|
/snapit |
|
🫰✨ Thanks @isaacroldan! Your snapshot has been published to npm. Built from Test the snapshot by installing your package globally: pnpm i -g --@shopify:registry=https://registry.npmjs.org @shopify/cli@0.0.0-snapshot-20261007120943Caution After installing, validate the version by running |
2c38b82 to
c02e6c7
Compare
|
/snapit |
|
🫰✨ Thanks @isaacroldan! Your snapshot has been published to npm. Built from Test the snapshot by installing your package globally: pnpm i -g --@shopify:registry=https://registry.npmjs.org @shopify/cli@0.0.0-snapshot-20261007133854Caution After installing, validate the version by running |
|
/snapit |
|
🫰✨ Thanks @isaacroldan! Your snapshot has been published to npm. Built from Test the snapshot by installing your package globally: pnpm i -g --@shopify:registry=https://registry.npmjs.org @shopify/cli@0.0.0-snapshot-20261007140356Caution After installing, validate the version by running |
| app: appSchema, | ||
| storeDomain: zod | ||
| .string() | ||
| .regex(/^[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.myshopify\.com$/) |
There was a problem hiding this comment.
Note for future consistency work: we have store domain consistency rules, but I wonder if it's worth making them re-usable in the code rather than re-implementing in each schema?
There was a problem hiding this comment.
to be honest, i don't think we need a regex for this? it can be a generic zod.string() 🤔
I'll update it.
WHY are these changes introduced?
Let scripts read the dev-preview cleanup outcome. Related to #23668.
WHAT is this pull request doing?
Add
--jsonwith app identity and the canonical store domain, ornullfor local/unknown domains. Reject missing deletion data before reporting success.Text:
Dev preview stopped.JSON:
{"status":"success","app":{"name":"Example","clientId":"client-id"},"storeDomain":"example.myshopify.com"}.Interactive JSON prompts need #8812. Successful postrun output is tracked in the shared issue note.
How to manually test your changes?
Use a linked test app and a development store.
shopify app dev clean --store <store>.myshopify.com --json --no-input > result.json. Check one success object with the correct app and store.--json; check the existing success banner. Use an inaccessible store with--json; expect one error object and a nonzero exit.shopify app dev clean --json-schemato inspect the contract.Checklist