shopify 4.9.4 → 5.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/analytics-Q6QDIDYT.js +1 -0
- package/dist/analytics-VKKJNJ62.js +1 -0
- package/dist/assets/hydrogen/starter/CHANGELOG.md +7 -0
- package/dist/assets/hydrogen/starter/package.json +2 -2
- package/dist/assets/hydrogen/vite/package.json +3 -4
- package/dist/assets/hydrogen/vite/vite.config.js +3 -3
- package/dist/bootstrap.js +1 -1
- package/dist/{chunk-LKXFHYLI.js → chunk-24NUJTIH.js} +1 -1
- package/dist/chunk-2CMEKSI7.js +1 -0
- package/dist/chunk-2DID73ML.js +1 -0
- package/dist/chunk-2ORRV7GH.js +1 -0
- package/dist/chunk-2VSNFOKD.js +1 -0
- package/dist/chunk-335BUVBP.js +1 -0
- package/dist/{chunk-UEBUGSBT.js → chunk-3A3DZVEJ.js} +1 -1
- package/dist/chunk-3C6VLJ5D.js +319 -0
- package/dist/{chunk-PB5ZZET5.js → chunk-3G4HJO72.js} +30 -30
- package/dist/chunk-3LVCG4JB.js +1 -0
- package/dist/chunk-43KLFFP7.js +1 -0
- package/dist/chunk-43R5VGKT.js +1 -0
- package/dist/chunk-46MSIQ6Z.js +1 -0
- package/dist/chunk-4ARCB6DT.js +1 -0
- package/dist/chunk-4C2DAX5T.js +1 -0
- package/dist/chunk-4CRBTSVP.js +2 -0
- package/dist/chunk-4GCI2YCZ.js +8 -0
- package/dist/chunk-4GOJQKY5.js +1 -0
- package/dist/chunk-4RDFMBRG.js +9 -0
- package/dist/chunk-4SS6DXC7.js +5 -0
- package/dist/{chunk-J4J2YXH3.js → chunk-4TI7U2PN.js} +1 -1
- package/dist/{chunk-67EBF76X.js → chunk-52FDK2LC.js} +1 -1
- package/dist/chunk-53BG3NLH.js +3 -0
- package/dist/{chunk-LD6ZCTZ3.js → chunk-5B76DT7X.js} +1 -1
- package/dist/{chunk-A2VCTDKH.js → chunk-5NEGOQT6.js} +1 -1
- package/dist/{chunk-MW3JKGJH.js → chunk-5OMJFPQW.js} +1 -1
- package/dist/chunk-5TB52UUV.js +2 -0
- package/dist/chunk-5UWMXOHM.js +7 -0
- package/dist/chunk-6BNKBCCU.js +1 -0
- package/dist/chunk-6DXP7PQ7.js +1 -0
- package/dist/chunk-6PUU6ZNQ.js +1 -0
- package/dist/chunk-7GHSE7SG.js +1 -0
- package/dist/{chunk-7556AIVG.js → chunk-7IFE4UQY.js} +1 -1
- package/dist/chunk-7LAKWAKX.js +25 -0
- package/dist/chunk-7MVWDCI3.js +1 -0
- package/dist/chunk-7NSK77WG.js +3 -0
- package/dist/chunk-7QUZWCJZ.js +3 -0
- package/dist/chunk-7RPFJZLP.js +1 -0
- package/dist/{chunk-LJIJEGND.js → chunk-7UOA4DI7.js} +2 -2
- package/dist/chunk-7WPUV7GY.js +6 -0
- package/dist/chunk-7Y7AZRL3.js +10 -0
- package/dist/{chunk-NGSEF3UX.js → chunk-ACA2BGAD.js} +1 -1
- package/dist/chunk-AJMDF3QC.js +1 -0
- package/dist/{chunk-R7YJNDXW.js → chunk-AXC2MHHO.js} +1 -1
- package/dist/{chunk-DEF2G7S4.js → chunk-AYL6KBPE.js} +1 -1
- package/dist/chunk-BAHIL37I.js +1 -0
- package/dist/{chunk-RSC5NQAT.js → chunk-BCYTZ7LM.js} +1 -1
- package/dist/{chunk-AVMNIZAJ.js → chunk-BJPDJIS4.js} +1 -1
- package/dist/{chunk-7VAKNVFD.js → chunk-BN7ZXAZJ.js} +1 -1
- package/dist/chunk-BVSKBX7T.js +16 -0
- package/dist/chunk-BWRNXCVN.js +4 -0
- package/dist/{chunk-XNPUZRWP.js → chunk-C3KEDG33.js} +1 -1
- package/dist/{chunk-WEXOA4C4.js → chunk-C7V755IT.js} +1 -1
- package/dist/chunk-CCMDZX35.js +7 -0
- package/dist/chunk-CCQNP5YR.js +1 -0
- package/dist/chunk-CEIJKJOF.js +11 -0
- package/dist/chunk-CIK5BF7V.js +1 -0
- package/dist/{chunk-6YDLNP4G.js → chunk-CVVQQLCF.js} +1 -1
- package/dist/chunk-CW2T7EOQ.js +1 -0
- package/dist/chunk-CZ22VZDA.js +376 -0
- package/dist/{chunk-3G2ZQ2EF.js → chunk-D7NB7YR6.js} +1 -1
- package/dist/{chunk-DYPZX7MW.js → chunk-DFQ4WTET.js} +2 -2
- package/dist/chunk-DJAZBPYA.js +3 -0
- package/dist/chunk-DNMXVMJM.js +47 -0
- package/dist/{chunk-CLD3NZYD.js → chunk-EGCWR5AS.js} +1 -1
- package/dist/{chunk-BOE2ST6J.js → chunk-EITIW5OX.js} +1 -1
- package/dist/chunk-EMSF57ZB.js +1 -0
- package/dist/{chunk-ZEBMW5KS.js → chunk-EXFBZPZS.js} +1 -1
- package/dist/chunk-FDXHQZTO.js +26 -0
- package/dist/{chunk-Q2XLIWG4.js → chunk-FFHH5LOR.js} +1 -1
- package/dist/{chunk-MMQZO2W2.js → chunk-FNLECT7B.js} +1 -1
- package/dist/{chunk-PO5T44H3.js → chunk-FWB3GLMW.js} +1 -1
- package/dist/chunk-FZCGRIOM.js +1 -0
- package/dist/{chunk-G7JW4UIM.js → chunk-G6ZMSWEU.js} +1 -1
- package/dist/chunk-GAMC2BNY.js +7 -0
- package/dist/chunk-GB6E3ATN.js +4 -0
- package/dist/chunk-GCNA3HXH.js +8 -0
- package/dist/{chunk-IGDVKRB4.js → chunk-GFVKTWFT.js} +1 -1
- package/dist/chunk-GQNOVEKP.js +2 -0
- package/dist/{chunk-5BTLE67Z.js → chunk-GRGFA26K.js} +1 -1
- package/dist/chunk-GXORLBVN.js +2 -0
- package/dist/{chunk-3V4VL3SD.js → chunk-H4V55Y3Z.js} +118 -118
- package/dist/chunk-HCZG7YJ6.js +16 -0
- package/dist/chunk-HF4NDEX3.js +1 -0
- package/dist/chunk-HIRTL45Q.js +1 -0
- package/dist/chunk-I4OVLRQR.js +1 -0
- package/dist/{chunk-ENQXB532.js → chunk-I6FRVYGE.js} +1 -1
- package/dist/chunk-IEQ4UOH3.js +4 -0
- package/dist/{chunk-PIZDYS7T.js → chunk-IILLQOUC.js} +60 -60
- package/dist/{chunk-45SZ5PSE.js → chunk-IQVRP7CT.js} +1 -1
- package/dist/chunk-IUP7POIE.js +6 -0
- package/dist/chunk-IUTZIN2T.js +10 -0
- package/dist/chunk-IWEKM5Y3.js +1 -0
- package/dist/chunk-IWTNUJGY.js +2 -0
- package/dist/chunk-J6TW43TG.js +1 -0
- package/dist/chunk-JDR6UVZA.js +8 -0
- package/dist/{chunk-CVFPY2SH.js → chunk-JEA3C7ON.js} +1 -1
- package/dist/chunk-JOJV5E2K.js +1 -0
- package/dist/chunk-JYMDWR25.js +1 -0
- package/dist/{chunk-TPHHQAUD.js → chunk-KDPQXURV.js} +1 -1
- package/dist/{chunk-MW3IMZJ5.js → chunk-KGRIYAMA.js} +1 -1
- package/dist/chunk-KJQDS5HI.js +1 -0
- package/dist/chunk-KKPOOIE4.js +2 -0
- package/dist/{chunk-VS7QVU3Z.js → chunk-KSDU4YOB.js} +1 -1
- package/dist/chunk-L7MSPGDS.js +5 -0
- package/dist/{chunk-43URS56H.js → chunk-LDU5T3DN.js} +1 -1
- package/dist/chunk-LHKVXJPX.js +1 -0
- package/dist/{chunk-EO4YJFMY.js → chunk-LMQGNECW.js} +86 -200
- package/dist/{chunk-TQ7URMGS.js → chunk-LQ7ENG4V.js} +1 -1
- package/dist/chunk-LVLAOBJM.js +103 -0
- package/dist/chunk-LWCTKI4Z.js +18 -0
- package/dist/chunk-M3ACZWMR.js +1 -0
- package/dist/chunk-M4BVLMPH.js +31 -0
- package/dist/{chunk-NCRWOW6F.js → chunk-M5TGCSUK.js} +1 -1
- package/dist/chunk-M7LPHCP2.js +274 -0
- package/dist/{chunk-IDKRJ2F4.js → chunk-MDRVCBDO.js} +1 -1
- package/dist/chunk-MR2AUT7Q.js +1 -0
- package/dist/chunk-MXJAH2GW.js +5 -0
- package/dist/{chunk-UU6BRRYS.js → chunk-MYAIWSOO.js} +1 -1
- package/dist/{chunk-NT4A37HG.js → chunk-N2RFDHRY.js} +1 -1
- package/dist/{chunk-GSE6FXZU.js → chunk-NB4BRW3H.js} +1 -1
- package/dist/chunk-NDKSG4CC.js +97 -0
- package/dist/chunk-NK2MGR6A.js +1 -0
- package/dist/chunk-NOH63WC6.js +12 -0
- package/dist/{chunk-BVB3DTNE.js → chunk-OGWPS55W.js} +1 -1
- package/dist/chunk-OQ5CLM2H.js +4 -0
- package/dist/{chunk-PVAZCZSY.js → chunk-OQU3HLAE.js} +1 -1
- package/dist/chunk-OVWUGAEU.js +11 -0
- package/dist/chunk-OX7UVDSU.js +6 -0
- package/dist/chunk-P33TONYG.js +1 -0
- package/dist/chunk-PEVIRAMR.js +6 -0
- package/dist/{chunk-YPCXVZ2N.js → chunk-PGLWZMJU.js} +4 -4
- package/dist/chunk-PIAD3F6M.js +16 -0
- package/dist/chunk-PMHP57MH.js +20 -0
- package/dist/{chunk-F3PZGSOY.js → chunk-POKY4RWR.js} +1 -1
- package/dist/chunk-PSSYLJG4.js +2 -0
- package/dist/chunk-PYIICTLX.js +1 -0
- package/dist/chunk-PZUGDE7N.js +2 -0
- package/dist/{chunk-NU5WLZ6Y.js → chunk-Q2SZCZE7.js} +1 -1
- package/dist/{chunk-MUM34KUM.js → chunk-Q2XRITUG.js} +1 -1
- package/dist/chunk-Q5MEFIMV.js +4 -0
- package/dist/chunk-Q66CI37F.js +7 -0
- package/dist/chunk-QFWWCZOI.js +1 -0
- package/dist/{chunk-TR4OWSEX.js → chunk-QFYLJVJW.js} +1 -1
- package/dist/chunk-QKVVJXWS.js +3 -0
- package/dist/chunk-QN3774QI.js +1 -0
- package/dist/chunk-R2BDABJD.js +213 -0
- package/dist/{chunk-7HWMURCW.js → chunk-R7EMV77H.js} +1 -1
- package/dist/chunk-RFGEM5JC.js +3 -0
- package/dist/{chunk-7A3RW2VM.js → chunk-RVQV6G5M.js} +1 -1
- package/dist/chunk-S67I4E7M.js +5 -0
- package/dist/chunk-SFPXYHHL.js +1 -0
- package/dist/{chunk-4OCVXE5Y.js → chunk-SFQEHDJY.js} +1 -1
- package/dist/chunk-SL3VBI62.js +3 -0
- package/dist/{chunk-LOWSU4BB.js → chunk-SNNZ4U2W.js} +1 -1
- package/dist/chunk-T2IUXXCT.js +1 -0
- package/dist/chunk-TPSA4JN5.js +1 -0
- package/dist/chunk-TTEF7GTX.js +1 -0
- package/dist/{chunk-FQL2WEKX.js → chunk-U25W35TX.js} +1 -1
- package/dist/chunk-UIQL5ZF3.js +1 -0
- package/dist/chunk-UK6576EO.js +1 -0
- package/dist/chunk-ULD7CIOY.js +4 -0
- package/dist/{chunk-D3KFKT4D.js → chunk-UOS2XLGG.js} +1 -1
- package/dist/{chunk-EMH7OHCW.js → chunk-UVRKTMF7.js} +1 -1
- package/dist/{chunk-ZTICX3AO.js → chunk-UWMZ5CSB.js} +1 -1
- package/dist/chunk-UZROQRLX.js +2 -0
- package/dist/{chunk-5BGUKF7L.js → chunk-V75WUEFU.js} +1 -1
- package/dist/chunk-VB7YQMAM.js +5 -0
- package/dist/chunk-VHUD3CBC.js +3 -0
- package/dist/chunk-VMMUJN4T.js +17 -0
- package/dist/{chunk-S36VGP37.js → chunk-VW6QS7DO.js} +1 -1
- package/dist/chunk-VWH3VPYI.js +1 -0
- package/dist/{chunk-4TF7ER72.js → chunk-WBJ6ZHYH.js} +1 -1
- package/dist/chunk-WDFCOZAY.js +16 -0
- package/dist/chunk-WFWISGLS.js +1 -0
- package/dist/chunk-WGUOLSMG.js +1 -0
- package/dist/{chunk-PFXNBHQQ.js → chunk-WJSUIUBW.js} +2 -2
- package/dist/{chunk-TFXUDHCP.js → chunk-WMAFG2JD.js} +1 -1
- package/dist/chunk-X2H6I2WW.js +5 -0
- package/dist/{chunk-DSS4ECIH.js → chunk-X7HVAVSZ.js} +1 -1
- package/dist/{chunk-NYYXH2SX.js → chunk-XBQDMGUN.js} +1 -1
- package/dist/chunk-XITZIDCL.js +18 -0
- package/dist/chunk-XKRJKUA7.js +1 -0
- package/dist/{chunk-FEQHCE2E.js → chunk-XM7YUXTF.js} +2 -2
- package/dist/chunk-XMODGI45.js +1 -0
- package/dist/{chunk-B3M3KIOU.js → chunk-XNNKLUTN.js} +1 -1
- package/dist/chunk-XTREQ4A2.js +1 -0
- package/dist/chunk-YGYEM6QO.js +1 -0
- package/dist/{chunk-LWU5TKNA.js → chunk-YKS7MH3F.js} +9 -6
- package/dist/chunk-YTUDXZLN.js +1 -0
- package/dist/{chunk-I3J63RFV.js → chunk-YTUUU33R.js} +1 -1
- package/dist/chunk-YVVU4J5O.js +3 -0
- package/dist/{chunk-4TZCRMBJ.js → chunk-YVY32DNA.js} +1 -1
- package/dist/chunk-Z5SILNH2.js +7 -0
- package/dist/chunk-ZAA2DXK5.js +5 -0
- package/dist/chunk-ZDQO6CNY.js +1 -0
- package/dist/chunk-ZGV3HNEV.js +1 -0
- package/dist/chunk-ZQDDRIBA.js +22 -0
- package/dist/{chunk-QTLGMJDW.js → chunk-ZT5WFUKJ.js} +4 -4
- package/dist/chunk-ZYQ2XWC5.js +5 -0
- package/dist/cli/commands/app/build.js +1 -1
- package/dist/cli/commands/app/bulk/cancel.js +1 -1
- package/dist/cli/commands/app/bulk/execute.js +1 -1
- package/dist/cli/commands/app/bulk/status.js +1 -1
- package/dist/cli/commands/app/config/link.js +1 -1
- package/dist/cli/commands/app/config/pull.js +1 -1
- package/dist/cli/commands/app/config/use.js +1 -1
- package/dist/cli/commands/app/config/validate.js +1 -1
- package/dist/cli/commands/app/demo/watcher.js +1 -1
- package/dist/cli/commands/app/deploy.js +1 -1
- package/dist/cli/commands/app/dev/clean.js +1 -1
- package/dist/cli/commands/app/dev.js +1 -1
- package/dist/cli/commands/app/env/pull.js +1 -1
- package/dist/cli/commands/app/env/show.js +1 -1
- package/dist/cli/commands/app/execute.js +1 -1
- package/dist/cli/commands/app/function/build.js +1 -1
- package/dist/cli/commands/app/function/info.js +1 -1
- package/dist/cli/commands/app/function/replay.js +1 -1
- package/dist/cli/commands/app/function/run.js +1 -1
- package/dist/cli/commands/app/function/schema.js +1 -1
- package/dist/cli/commands/app/function/typegen.js +1 -1
- package/dist/cli/commands/app/generate/extension.js +1 -1
- package/dist/cli/commands/app/graphiql.js +1 -1
- package/dist/cli/commands/app/import/channel-config.js +1 -1
- package/dist/cli/commands/app/import/custom-data-definitions.js +1 -1
- package/dist/cli/commands/app/import/dashboard-extensions.js +1 -1
- package/dist/cli/commands/app/import-custom-data-definitions.js +1 -1
- package/dist/cli/commands/app/import-extensions.js +1 -1
- package/dist/cli/commands/app/info.js +1 -1
- package/dist/cli/commands/app/init.js +1 -1
- package/dist/cli/commands/app/logs.js +1 -1
- package/dist/cli/commands/app/release.js +1 -1
- package/dist/cli/commands/app/security/check.js +1 -1
- package/dist/cli/commands/app/security/clean.js +1 -1
- package/dist/cli/commands/app/security/instructions.js +1 -1
- package/dist/cli/commands/app/security/record.js +1 -1
- package/dist/cli/commands/app/security/review.js +1 -1
- package/dist/cli/commands/app/subscription-migrations/cancel.js +1 -1
- package/dist/cli/commands/app/subscription-migrations/list.js +1 -1
- package/dist/cli/commands/app/subscription-migrations/schedule.js +1 -1
- package/dist/cli/commands/app/subscription-migrations/status.js +1 -1
- package/dist/cli/commands/app/subscription-migrations/unschedule.js +1 -1
- package/dist/cli/commands/app/versions/list.js +1 -1
- package/dist/cli/commands/app/webhook/trigger.js +1 -1
- package/dist/cli/commands/auth/login.js +1 -1
- package/dist/cli/commands/auth/logout.js +1 -1
- package/dist/cli/commands/cache/clear.js +1 -1
- package/dist/cli/commands/config/autoupgrade/off.js +1 -1
- package/dist/cli/commands/config/autoupgrade/on.js +1 -1
- package/dist/cli/commands/config/autoupgrade/status.js +1 -1
- package/dist/cli/commands/debug/command-flags.js +1 -1
- package/dist/cli/commands/doc/fetch.d.ts +34 -1
- package/dist/cli/commands/doc/fetch.js +1 -1
- package/dist/cli/commands/doc/search.d.ts +53 -1
- package/dist/cli/commands/doc/search.js +1 -1
- package/dist/cli/commands/docs/generate.js +1 -1
- package/dist/cli/commands/doctor-release/doctor-release.js +1 -1
- package/dist/cli/commands/doctor-release/theme/index.js +1 -1
- package/dist/cli/commands/help.d.ts +6 -6
- package/dist/cli/commands/help.js +1 -1
- package/dist/cli/commands/kitchen-sink/async.js +1 -1
- package/dist/cli/commands/kitchen-sink/index.js +1 -1
- package/dist/cli/commands/kitchen-sink/prompts.js +1 -1
- package/dist/cli/commands/kitchen-sink/static.js +1 -1
- package/dist/cli/commands/notifications/generate.js +1 -1
- package/dist/cli/commands/notifications/list.js +1 -1
- package/dist/cli/commands/organization/list.js +1 -1
- package/dist/cli/commands/search.js +1 -1
- package/dist/cli/commands/send-analytics.js +1 -1
- package/dist/cli/commands/theme/check.js +1 -1
- package/dist/cli/commands/theme/console.js +1 -1
- package/dist/cli/commands/theme/delete.js +1 -1
- package/dist/cli/commands/theme/dev.js +1 -1
- package/dist/cli/commands/theme/duplicate.js +1 -1
- package/dist/cli/commands/theme/info.js +1 -1
- package/dist/cli/commands/theme/init.js +1 -1
- package/dist/cli/commands/theme/language-server.js +1 -1
- package/dist/cli/commands/theme/list.js +1 -1
- package/dist/cli/commands/theme/metafields/pull.js +1 -1
- package/dist/cli/commands/theme/open.js +1 -1
- package/dist/cli/commands/theme/package.js +1 -1
- package/dist/cli/commands/theme/preview.js +1 -1
- package/dist/cli/commands/theme/profile.js +1 -1
- package/dist/cli/commands/theme/publish.js +1 -1
- package/dist/cli/commands/theme/pull.js +1 -1
- package/dist/cli/commands/theme/push.js +1 -1
- package/dist/cli/commands/theme/rename.js +1 -1
- package/dist/cli/commands/theme/share.js +1 -1
- package/dist/cli/commands/upgrade.d.ts +64 -0
- package/dist/cli/commands/upgrade.js +1 -1
- package/dist/cli/commands/version.js +1 -1
- package/dist/cli/help.js +1 -1
- package/dist/cli/services/commands/doc/fetch-result.d.ts +2 -0
- package/dist/cli/services/commands/doc/fetch-result.js +22 -0
- package/dist/cli/services/commands/doc/fetch.d.ts +2 -1
- package/dist/cli/services/commands/doc/fetch.js +2 -15
- package/dist/cli/services/commands/doc/search-result.d.ts +2 -0
- package/dist/cli/services/commands/doc/search-result.js +14 -0
- package/dist/cli/services/commands/doc/search.d.ts +9 -1
- package/dist/cli/services/commands/doc/search.js +27 -2
- package/dist/cli/services/commands/doc/types.d.ts +107 -0
- package/dist/cli/services/commands/doc/types.js +47 -0
- package/dist/cli/services/commands/help/types.d.ts +6 -6
- package/dist/command-event-context-LFUZ7UCA.js +1 -0
- package/dist/command-json-schema-2UMKY7MY.js +1 -0
- package/dist/command-registry.js +1 -1
- package/dist/conf-store-RI3TL6I4.js +1 -0
- package/dist/custom-oclif-loader-IZCKN67O.js +1 -0
- package/dist/deprecations-IFVUXXDB.js +1 -0
- package/dist/dist-4H2B7BMN.js +1 -0
- package/dist/dist-QNWOGQN3.js +1 -0
- package/dist/{environment-RSUK27TA.js → environment-O7ECODHU.js} +1 -1
- package/dist/environments-CYMEN7NV.js +1 -0
- package/dist/error-IL6WQMSW.js +1 -0
- package/dist/error-handler-74HKA23T.js +1 -0
- package/dist/fs-AINFLJ2E.js +1 -0
- package/dist/hooks/did-you-mean.js +1 -1
- package/dist/hooks/hydrogen-init.js +1 -1
- package/dist/hooks/plugin-plugins.js +1 -1
- package/dist/hooks/postrun.js +1 -1
- package/dist/hooks/prerun.js +1 -1
- package/dist/hooks/public-metadata.js +1 -1
- package/dist/hooks/sensitive-metadata.js +1 -1
- package/dist/hooks/tunnel-provider.js +1 -1
- package/dist/hooks/tunnel-start.js +1 -1
- package/dist/index.js +13 -13
- package/dist/is-global-2VLKV46Q.js +1 -0
- package/dist/json-error-HZB5YIHV.js +1 -0
- package/dist/{lib-TYM5B75S.js → lib-PJHT4MKY.js} +1 -1
- package/dist/{lib-55QUD4AJ.js → lib-VKSQ65BQ.js} +1 -1
- package/dist/{lib-PH52G55H.js → lib-YEZOHXF3.js} +1 -1
- package/dist/{local-R3UAQN7T.js → local-KOZETREJ.js} +1 -1
- package/dist/{metadata-JWJG4JV4.js → metadata-IBPHZB7N.js} +1 -1
- package/dist/{morph-BABFBRSW.js → morph-CRY35DIK.js} +1 -1
- package/dist/node-package-manager-DXSRNEDC.js +1 -0
- package/dist/notifications-system-XA3EBOGJ.js +1 -0
- package/dist/os-X73O7BAB.js +1 -0
- package/dist/out-B2GISN65.js +1 -0
- package/dist/output-3OYXK3Z5.js +1 -0
- package/dist/{path-CPAYTWQW.js → path-3L2QRACZ.js} +1 -1
- package/dist/system-JWYYT4PM.js +1 -0
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/ui-PCG5D6RZ.js +1 -0
- package/dist/upgrade-7U2TUNC4.js +1 -0
- package/dist/version-7DGU2KYH.js +1 -0
- package/dist/version-SXQTRBXB.js +1 -0
- package/dist/workerd-MQZ3NKJI.js +18 -0
- package/oclif.manifest.json +1664 -427
- package/package.json +8 -8
- package/dist/analytics-APDNTBDE.js +0 -1
- package/dist/analytics-LX52KYSE.js +0 -1
- package/dist/chunk-2PDVBGQH.js +0 -7
- package/dist/chunk-2YVSZFXJ.js +0 -4
- package/dist/chunk-35WQTGN3.js +0 -5
- package/dist/chunk-37BGAWAW.js +0 -2
- package/dist/chunk-3C4WVKSO.js +0 -6
- package/dist/chunk-3LHE4GIX.js +0 -1
- package/dist/chunk-47IQIIFX.js +0 -383
- package/dist/chunk-4ES7BJEK.js +0 -1
- package/dist/chunk-4IFY7V7W.js +0 -1
- package/dist/chunk-4JGWKUJN.js +0 -2
- package/dist/chunk-4O5GQ3DS.js +0 -7
- package/dist/chunk-4O7LK5RG.js +0 -26
- package/dist/chunk-4TFJ5RW7.js +0 -8
- package/dist/chunk-4ZNBEMRT.js +0 -20
- package/dist/chunk-5JIJDUXX.js +0 -20
- package/dist/chunk-66YRAUWX.js +0 -3
- package/dist/chunk-6A4H3HPY.js +0 -7
- package/dist/chunk-6HPUOCFF.js +0 -1
- package/dist/chunk-6IDEDOXW.js +0 -2
- package/dist/chunk-6IMHGT7F.js +0 -8
- package/dist/chunk-6MC2BEW4.js +0 -1
- package/dist/chunk-73D5O7A3.js +0 -1
- package/dist/chunk-7E4MJCVE.js +0 -10
- package/dist/chunk-7HNRK2CR.js +0 -1
- package/dist/chunk-7SJHVJ3W.js +0 -5
- package/dist/chunk-ALK66U3O.js +0 -3
- package/dist/chunk-AMLCWRHU.js +0 -4
- package/dist/chunk-AYIU6Z4C.js +0 -1
- package/dist/chunk-BIWG3FQQ.js +0 -5
- package/dist/chunk-BQ3U3CQV.js +0 -1
- package/dist/chunk-C6IBY7NW.js +0 -16
- package/dist/chunk-CQF5NDTJ.js +0 -4
- package/dist/chunk-DMDLJRLW.js +0 -1
- package/dist/chunk-DMNWSUKV.js +0 -5
- package/dist/chunk-FK7GA4QQ.js +0 -1
- package/dist/chunk-FO2R6KHG.js +0 -1
- package/dist/chunk-FOAV642V.js +0 -1
- package/dist/chunk-GE4MLO3C.js +0 -5
- package/dist/chunk-GM4EFJJF.js +0 -7
- package/dist/chunk-GN66BRYF.js +0 -1
- package/dist/chunk-GPRZYFDE.js +0 -1
- package/dist/chunk-GZ7VGCVW.js +0 -3
- package/dist/chunk-HASIOUH2.js +0 -3
- package/dist/chunk-HILYTMVA.js +0 -1
- package/dist/chunk-HJHS23Q3.js +0 -1
- package/dist/chunk-HLPAVELJ.js +0 -1
- package/dist/chunk-HPM3HF7A.js +0 -1
- package/dist/chunk-HQJ62PII.js +0 -3
- package/dist/chunk-HQY6JM6G.js +0 -6
- package/dist/chunk-HSYMUYEZ.js +0 -359
- package/dist/chunk-I5PQZRYM.js +0 -32
- package/dist/chunk-IPZ6LUJV.js +0 -4
- package/dist/chunk-J4NBPC57.js +0 -1
- package/dist/chunk-J6LQR2F6.js +0 -7
- package/dist/chunk-JYGZD4HM.js +0 -1
- package/dist/chunk-K3HUQLIC.js +0 -6
- package/dist/chunk-K7D53KSJ.js +0 -1
- package/dist/chunk-KQFA5YTT.js +0 -97
- package/dist/chunk-KTD7VLHL.js +0 -2
- package/dist/chunk-L4DFMMOI.js +0 -1
- package/dist/chunk-LJZTSQRD.js +0 -11
- package/dist/chunk-LLPB6JN5.js +0 -9
- package/dist/chunk-LYIXRMQJ.js +0 -46
- package/dist/chunk-MCNK5SJ6.js +0 -2
- package/dist/chunk-MJZSSCGD.js +0 -5
- package/dist/chunk-N55MSO3X.js +0 -12
- package/dist/chunk-N5AZZYQA.js +0 -4
- package/dist/chunk-NCVGCVQ5.js +0 -6
- package/dist/chunk-O5FFMTJE.js +0 -25
- package/dist/chunk-OE3HSNSE.js +0 -16
- package/dist/chunk-ONF7XXEL.js +0 -1
- package/dist/chunk-PG4S5HJJ.js +0 -5
- package/dist/chunk-PHG4DASY.js +0 -18
- package/dist/chunk-PP4VCR4Y.js +0 -1
- package/dist/chunk-PWS4VFSD.js +0 -1
- package/dist/chunk-Q37WAD6F.js +0 -1
- package/dist/chunk-Q43LBSPT.js +0 -1
- package/dist/chunk-QAJZUJR5.js +0 -1
- package/dist/chunk-QO5RNGWA.js +0 -1
- package/dist/chunk-QPQS2YU3.js +0 -1
- package/dist/chunk-QUXQM3S3.js +0 -1
- package/dist/chunk-R3KSOCMB.js +0 -6
- package/dist/chunk-R74WHKHH.js +0 -15
- package/dist/chunk-RJSQMKKS.js +0 -1
- package/dist/chunk-RK2V6OIJ.js +0 -2
- package/dist/chunk-RUHQNF2W.js +0 -1
- package/dist/chunk-RXTLNUPF.js +0 -1
- package/dist/chunk-SNE4RHM4.js +0 -1
- package/dist/chunk-SQAS5RVZ.js +0 -10
- package/dist/chunk-SZI6G247.js +0 -103
- package/dist/chunk-TVCWDEVS.js +0 -1
- package/dist/chunk-TYMYIUIQ.js +0 -1
- package/dist/chunk-UIC7K2HX.js +0 -7
- package/dist/chunk-UNHT4ZFP.js +0 -317
- package/dist/chunk-UQ6ALA3Y.js +0 -3
- package/dist/chunk-UWI76E2L.js +0 -18
- package/dist/chunk-VE35YELD.js +0 -1
- package/dist/chunk-VGBUN3CZ.js +0 -17
- package/dist/chunk-VMNOSVPT.js +0 -8
- package/dist/chunk-VNFUCH6T.js +0 -1
- package/dist/chunk-W4KE7AO6.js +0 -1
- package/dist/chunk-WEPO4J2F.js +0 -19
- package/dist/chunk-WLWHCUPZ.js +0 -1
- package/dist/chunk-XGKCPD6W.js +0 -1
- package/dist/chunk-XNVOKAF2.js +0 -1
- package/dist/chunk-XSMCQLJW.js +0 -1
- package/dist/chunk-XUUIBSLW.js +0 -1
- package/dist/chunk-XWQM2NZ2.js +0 -2
- package/dist/chunk-Y3PY5LP7.js +0 -3
- package/dist/chunk-Y62EMOQA.js +0 -1
- package/dist/chunk-Y743UVBS.js +0 -16
- package/dist/chunk-YBSX53QP.js +0 -1
- package/dist/chunk-YHCP326A.js +0 -16
- package/dist/chunk-YHESTFMZ.js +0 -4
- package/dist/chunk-YT27FIQN.js +0 -275
- package/dist/chunk-YTR5JHNJ.js +0 -2
- package/dist/chunk-YYA5VGDW.js +0 -1
- package/dist/chunk-Z6X2GT6Q.js +0 -1
- package/dist/chunk-ZEE32UH6.js +0 -1
- package/dist/cli/commands/app/app-logs/sources.js +0 -1
- package/dist/command-json-schema-SS4GDJTQ.js +0 -1
- package/dist/conf-store-54YJCIDK.js +0 -1
- package/dist/custom-oclif-loader-3UBH7Q7R.js +0 -1
- package/dist/deprecations-ZX7ZKF6L.js +0 -1
- package/dist/dist-JMNE7MP6.js +0 -1
- package/dist/dist-M2AXGBOL.js +0 -1
- package/dist/environments-KD2IDYPG.js +0 -1
- package/dist/error-AA6LW3PN.js +0 -1
- package/dist/error-handler-4VW3AV2G.js +0 -1
- package/dist/fs-4QZCAEP7.js +0 -1
- package/dist/is-global-FKG327CG.js +0 -1
- package/dist/json-error-32ETFU3V.js +0 -1
- package/dist/node-package-manager-M4XHUTQR.js +0 -1
- package/dist/notifications-system-QVM2JWKB.js +0 -1
- package/dist/os-FEHBQQKP.js +0 -1
- package/dist/out-53ABAVL7.js +0 -1
- package/dist/output-2LS5AOAH.js +0 -1
- package/dist/system-TMD2LYZM.js +0 -1
- package/dist/ui-FNPICAAH.js +0 -1
- package/dist/upgrade-YYPP5VZY.js +0 -1
- package/dist/version-OX3MORI6.js +0 -1
- package/dist/version-P7D5ME4Z.js +0 -1
- package/dist/workerd-TKVRZK2F.js +0 -18
package/dist/chunk-WEPO4J2F.js
DELETED
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import{p as C,v as Y}from"./chunk-Y3PY5LP7.js";import{ca as re,da as q}from"./chunk-NCRWOW6F.js";import{b as H}from"./chunk-NU5WLZ6Y.js";import{r as L}from"./chunk-3C4WVKSO.js";import{y as w,z as E}from"./chunk-47IQIIFX.js";import{i as $}from"./chunk-Q37WAD6F.js";import{Ib as p,Kb as P,Lb as G,Nb as j,R as I,Xa as N,db as A,ya as T}from"./chunk-UWI76E2L.js";import{b as oe}from"./chunk-I3J63RFV.js";import{c as O,e as S,o as b}from"./chunk-6IDEDOXW.js";import{e as k,g as v}from"./chunk-VKWPEFWQ.js";v();v();var r=k(q(),1),l=k(re(),1);function se(e,t){return e instanceof Error&&"code"in e&&e.code==="ENOENT"&&"path"in e&&typeof e.path=="string"&&S(e.path)===S(t)}async function F(e,t){try{return await t()}catch(n){throw e!==void 0&&se(n,e)?new $(`Theme Check config file not found: ${e}`):n}}function ce(e){switch(e){case"error":return r.Severity.ERROR;case"suggestion":case"warning":return r.Severity.WARNING;case"style":case"info":return r.Severity.INFO;case"crash":return}}function U(e){switch(e){case r.Severity.ERROR:return"error";case r.Severity.WARNING:return"warning";case r.Severity.INFO:return"info"}}function ae(e){return new Map(e.map(t=>[t.uri,t.source]))}function ue(e,t,n){let o=e.split(`
|
|
2
|
-
`).slice(t,n+1),s=o.length===1;return o.map((c,a)=>{let u=t+a+1,d=s?c.trim():c;return`${u} ${d}`}).join(`
|
|
3
|
-
`)}function fe(e){switch(e){case r.Severity.ERROR:return{error:`
|
|
4
|
-
[error]:`};case r.Severity.WARNING:return{warn:`
|
|
5
|
-
[warning]:`};case r.Severity.INFO:return{info:`
|
|
6
|
-
[info]:`}}}function he(e,t){return e.map((i,o)=>{let{message:s,uri:c,start:a,end:u,check:d,severity:m}=i,f=t.get(c),x=f===void 0?[]:[`
|
|
7
|
-
|
|
8
|
-
${ue(f,a.line,u.line)}`],_=o===e.length-1?"":`
|
|
9
|
-
|
|
10
|
-
`;return[fe(m),{bold:d},{subdued:`
|
|
11
|
-
${s}`},...x,_]}).flat()}var me=(e,t)=>e.severity-t.severity;function W(e){let t=e.reduce((n,i)=>{let{uri:o}=i,s=r.path.fsPath(o);return n[s]??=[],n[s].push(i),n},{});return Object.keys(t).reduce((n,i)=>(n[i]=t[i].sort(me),n),{})}function B(e){return e.reduce((t,n)=>(t[n.severity]=(t[n.severity]??0)+1,t),{})}function M(e,t,n){let i=[`${n.length} files inspected`];if(e.length===0)i.push("with no offenses found.");else{i.push(`with ${e.length} total offenses found across ${Object.keys(t).length} files.`);let o=B(e);o[r.Severity.ERROR]&&i.push(`
|
|
12
|
-
${o[r.Severity.ERROR]} errors.`),o[r.Severity.WARNING]&&i.push(`
|
|
13
|
-
${o[r.Severity.WARNING]} warnings.`),o[r.Severity.INFO]&&i.push(`
|
|
14
|
-
${o[r.Severity.INFO]} info issues.`)}return i}function D(e,t,n,i){let o=ae(n);Object.keys(e).sort().forEach(c=>{let a=c.replace(t,"").slice(1);w({headline:i?`[${i}] ${a}`:a,body:he(e[c],o)})})}function J(e,t){return Object.entries(e).map(([n,i])=>{let o=i.map(c=>({check:c.check,severity:U(c.severity),start_row:c.start.line,start_column:c.start.character,end_row:c.end.line,end_column:c.end.character,message:c.message})),s=B(i);return{environment:t,path:n,offenses:o,errorCount:s[r.Severity.ERROR]??0,warningCount:s[r.Severity.WARNING]??0,infoCount:s[r.Severity.INFO]??0}})}function V(e,t){t||process.exit(0);let n=ce(t),i=n!==void 0&&e.some(o=>o.severity<=n);process.exit(i?1:0)}function de(e){return e.split(`
|
|
15
|
-
`).map(t=>`# ${t}`).join(`
|
|
16
|
-
`)}async function z(e){let t=".theme-check.yml",n=O(e,t);if(await N(n)){P(`${t} already exists at ${e}`);return}let{settings:i}=await(0,r.loadConfig)(void 0,e),o=de(l.default.stringify(i)),s=l.default.stringify({extends:"theme-check:recommended",ignore:["node_modules/**"]});await T(n,`${s}${o}`),G(`Created ${t} at ${e}`)}var pe=async(e,t)=>{let n=(0,r.applyFixToString)(e.source,t),i=r.path.fsPath(e.uri);await T(i,n)};async function K(e,t){await(0,r.autofix)(e,t,pe)}async function Q(e,t,n){let{ignore:i,settings:o,rootUri:s}=await F(t,()=>(0,r.loadConfig)(t,e)),c={extends:[],ignore:I(i??[]),rootUri:s,...o},a=n?{[n]:c}:c;p(l.default.stringify(a))}async function X(e,t,n){let{settings:i,ignore:o,checks:s}=await F(t,()=>(0,r.loadConfig)(t,e)),c=I(o??[]),u=Object.keys(i).reduce((m,f)=>{let{severity:x,enabled:_,...ee}=i[f];if(!_)return m;let te=U(x??r.Severity.INFO),y=s.find(ie=>ie.meta.code===f),ne=y&&y.meta?{description:y.meta.docs.description,doc:y.meta.docs.url}:{};return m[f]={severity:te,...ne,ignored_patterns:`[${c.join(", ")}]`,...ee},m},{}),d=n?{[n]:u}:u;p(l.default.stringify(d))}function Z(e){return"_handle"in e&&typeof e._handle=="object"&&e._handle!==null&&typeof e._handle.setBlocking=="function"}var h=k(oe(),1);var g=k(q(),1);var R=class extends Y{static summary="Validate the theme.";static descriptionWithMarkdown="Calls and runs [Theme Check](https://shopify.dev/docs/themes/tools/theme-check) to analyze your theme code for errors and to ensure that it follows theme and Liquid best practices. [Learn more about the checks that Theme Check runs.](https://shopify.dev/docs/themes/tools/theme-check/checks)";static description=this.descriptionForHelp();static flags={...H,path:C.path,"auto-correct":h.Flags.boolean({char:"a",required:!1,description:"Automatically fix offenses",env:"SHOPIFY_FLAG_AUTO_CORRECT"}),config:h.Flags.string({char:"C",required:!1,description:`Use the config provided, overriding .theme-check.yml if present
|
|
17
|
-
Supports all theme-check: config values, e.g., theme-check:theme-app-extension,
|
|
18
|
-
theme-check:recommended, theme-check:all
|
|
19
|
-
For backwards compatibility, :theme_app_extension is also supported `,env:"SHOPIFY_FLAG_CONFIG"}),"fail-level":h.Flags.string({required:!1,description:"Minimum severity for exit with error code",env:"SHOPIFY_FLAG_FAIL_LEVEL",options:["crash","error","suggestion","style","warning","info"],default:"error"}),init:h.Flags.boolean({required:!1,description:"Generate a .theme-check.yml file",env:"SHOPIFY_FLAG_INIT"}),list:h.Flags.boolean({required:!1,description:"List enabled checks",env:"SHOPIFY_FLAG_LIST"}),output:h.Flags.string({char:"o",required:!1,description:"The output format to use",env:"SHOPIFY_FLAG_OUTPUT",options:["text","json"],default:"text"}),print:h.Flags.boolean({required:!1,description:"Output active config to STDOUT",env:"SHOPIFY_FLAG_PRINT"}),version:h.Flags.boolean({char:"v",required:!1,description:"Print Theme Check version",env:"SHOPIFY_FLAG_VERSION"}),environment:C.environment};static multiEnvironmentsFlags=["path"];async command(t,n,i){let o=t.path,s=t.environment?.[0],a=t.config?.startsWith(":")&&g.LegacyIdentifiers.has(t.config.slice(1))?g.LegacyIdentifiers.get(t.config.slice(1)):t.config;if(t.init){await z(o);return}if(t.version){let m=await A(O("node_modules","@shopify","theme-check-node","package.json"),{type:"file",cwd:b(import.meta.url)}),f="unknown";m&&(f=await L(m)??"unknown"),p(f);return}if(t.print){await Q(o,a,s);return}if(t.list){await X(o,a,s);return}let{offenses:u,theme:d}=await le(o,t.output,a,s);if(t["auto-correct"]&&await K(d,u),!i)return V(u,t["fail-level"])}};async function le(e,t,n,i){let{offenses:o,theme:s}=await F(n,()=>(0,g.themeCheckRun)(e,n,a=>{process.env.SHOPIFY_TMP_FLAG_DEBUG&&j(a)})),c=W(o);if(t==="text"&&(D(c,e,s,i),(o.length?w:E)({headline:i?`[${i}] Theme Check Summary.`:"Theme Check Summary.",body:M(o,c,s)})),t==="json"){let a=process.stdout;Z(a)&&a._handle.setBlocking(!0),p(JSON.stringify(J(c,i)))}return{offenses:o,theme:s}}export{R as a,le as b};
|
package/dist/chunk-WLWHCUPZ.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{A as h,ba as F,c,ca as g,f as k,g as v,n as m}from"./chunk-3V4VL3SD.js";import{b as l}from"./chunk-QTLGMJDW.js";import{i as n,l as A}from"./chunk-Q37WAD6F.js";import{Cb as b,Eb as f}from"./chunk-UWI76E2L.js";import{i as q}from"./chunk-FOAV642V.js";import{g as d}from"./chunk-VKWPEFWQ.js";d();d();var $={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"publicApiVersions"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"publicApiVersions"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"handle"}},{kind:"Field",name:{kind:"Name",value:"supported"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};var S=new Map;async function Y(t,r,e,o){let p="Admin",u=o??await T(r),s=r.storeFqdn,i=V(r);l()==="local"&&(i["x-forwarded-host"]=s,s=new m().host("app"));let a=E(s,u,r);return F({query:t,api:p,addedHeaders:i,url:a,token:r.token,variables:e})}async function D(t){let{query:r,session:e,variables:o,version:p,responseOptions:u,preferredBehaviour:s}=t,i=p??S.get(e.storeFqdn);i??=await T(e,s);let a=e.storeFqdn,y=V(e);l()==="local"&&(y["x-forwarded-host"]=a,a=new m().host("app"));let x={url:E(a,i,e),api:"Admin",token:e.token,addedHeaders:y},w;return"refresh"in e&&(w={type:"token_refresh",handler:e.refresh}),g({...x,query:r,variables:o,responseOptions:u,unauthorizedHandler:w,preferredBehaviour:s})}function V(t){return h(t)?{"X-Shopify-Shop":t.storeFqdn,"X-Shopify-Access-Token":t.token}:{}}async function T(t,r){let o=(await N(t,r)).reverse()[0];return S.set(t.storeFqdn,o),o}async function N(t,r){return(await R(t,r)).filter(o=>o.supported).map(o=>o.handle).sort()}async function R(t,r){try{return(await D({query:$,session:t,variables:{},version:"unstable",responseOptions:{handleErrors:!1},preferredBehaviour:r})).publicApiVersions}catch(e){if(e instanceof c&&e.response.status===403){let o=t.storeFqdn.replace(".myshopify.com","");throw new n(f`Looks like you don't have access to this dev store: (${b.link(o,`https://${t.storeFqdn}`)})`,f`If you're not the owner, create a dev store staff account for yourself`)}throw e instanceof c&&(e.response.status===401||e.response.status===404)?new n(`Error connecting to your store ${t.storeFqdn}: ${e.message} ${e.response.status} ${e.response.data}`):e instanceof c&&e.response.status===402?new n(`The store ${t.storeFqdn} is currently unavailable.`,"This usually means the store is frozen, paused, or closed. Check the store in the Shopify admin and try again once it is reactivated."):e instanceof c&&e.response.status>=500?new n(`The Admin API for ${t.storeFqdn} returned a server error (HTTP ${e.response.status}).`,"This is a problem on the Shopify side, not with your command. Wait a moment and try again."):v(e)?new n(`Request to ${t.storeFqdn} was aborted before it completed.`,"The request was cancelled or timed out before the store responded. Try running the command again."):k(e)?new n(`Network error connecting to your store ${t.storeFqdn}: ${e instanceof Error?e.message:String(e)}`,"Check your internet connection and try again."):new A(`Unknown error connecting to your store ${t.storeFqdn}: ${e instanceof Error?e.message:String(e)}`)}}function E(t,r,e){let o=r??"unstable";return e&&h(e)?`https://${q}/cli/admin/api/${o}/graphql.json`:`https://${t}/admin/api/${o}/graphql.json`}export{Y as a,D as b,N as c,R as d,E as e};
|
package/dist/chunk-XGKCPD6W.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{h as l}from"./chunk-3LHE4GIX.js";import{K as c}from"./chunk-3V4VL3SD.js";import{i as u}from"./chunk-Q37WAD6F.js";import{g as i}from"./chunk-VKWPEFWQ.js";i();var s=["live","unpublished","development"];async function x(e,r){let t=await c(e,r);return p(t)}async function p(e){let r=e.storeFqdn,t=(await l(e)).filter(d);if(t.length===0)throw new u(`There are no themes in the ${r} store`);return t.sort(w)}function d(e){return s.includes(e.role)}function w(e,r){return s.indexOf(e.role)-s.indexOf(r.role)}i();function b(e,r,t){return y(e,r,t)??T(e,r,t)}function y(e,r,t){let o=t.role;if(!o)return;let n=`No themes on the store ${e} match the role "${o}"`;return m(r,h=>h.role===o).orThrow(n)}function T(e,r,t){return t.themeIdentifiers.flatMap(n=>{let h=`No themes on the store ${e} match the ID or name "${n}"`;return m(r,f=>`${f.id}`===n||f.name.toLowerCase()===n.toLowerCase()?!0:L(f.name.toLowerCase(),n.toLowerCase())).orThrow(h)})}function m(e,r){let t=e.filter(r);return t.length>0?{orThrow:o=>t}:{orThrow:o=>{throw new u(o)}}}var a=class{queryProps;constructor(r){this.queryProps=r}get role(){for(let r of s)if(this.queryProps[r])return r}get themeIdentifiers(){return[this.queryProps.theme,this.queryProps.themes].flat().filter(t=>!!t)}any(){return Object.values(this.queryProps).some(r=>r?.length!==void 0?r.length>0:!!r)}};function L(e,r){let t=r.replace(/(^\*)|(\*$)/g,"");return r.startsWith("*")&&r.endsWith("*")?e.includes(t):r.startsWith("*")?e.endsWith(t):r.endsWith("*")?e.startsWith(t):!1}export{s as a,x as b,p as c,b as d,a as e};
|
package/dist/chunk-XNVOKAF2.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{b as i,c as n}from"./chunk-NU5WLZ6Y.js";import{b as u}from"./chunk-4ZNBEMRT.js";import{M as a}from"./chunk-3V4VL3SD.js";import{a as e}from"./chunk-7VAKNVFD.js";import{Ib as c,Lb as r,b as t}from"./chunk-UWI76E2L.js";import{g as s}from"./chunk-VKWPEFWQ.js";s();var m=e({name:"AuthLogoutResult",schema:t.object({status:t.literal("success")}).strict()}),o=class p extends u{static descriptionWithMarkdown="Logs you out of the Shopify account or Partner account and store.";static description=this.descriptionForHelp();static flags={...i,...n};static get jsonOutputSchema(){return m}async run(){let{flags:l}=await this.parse(p);await a(),l.json?c(m.encode({status:"success"})):r("Logged out from all the accounts")}};export{o as a};
|
package/dist/chunk-XSMCQLJW.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as h,b as w}from"./chunk-YPCXVZ2N.js";import{j as f}from"./chunk-3V4VL3SD.js";import{T as d}from"./chunk-47IQIIFX.js";import{i}from"./chunk-Q37WAD6F.js";import{Ka as m,ra as p}from"./chunk-UWI76E2L.js";import{c as u}from"./chunk-6IDEDOXW.js";import{g as l}from"./chunk-VKWPEFWQ.js";l();import{writeFile as g}from"fs/promises";var S=1024*1024,y=100,U=y*S,E=3,_=new Set([408,429,500,502,503,504]);async function j(o,e){let t=u(e,"manifest.json");await g(t,JSON.stringify(o,null,2))}var A=["!**/*.js.map","!**/*.metafile.json"];async function k(o,e,t){let n=t??["**/*",...A];e.endsWith(".br")?await w({inputDirectory:o,outputPath:e,matchFilePattern:n}):await h({inputDirectory:o,outputZipPath:e,matchFilePattern:n})}async function C(o,e){let t=await m(e);if(t>U){let s=`${(Math.ceil(t/S*100)/100).toFixed(2)} MB`;throw new i(`Your app bundle exceeds the ${y} MB upload limit (it is ${s}).`,"Check the asset paths in your extension configuration \u2014 a misconfigured source can pull in much more than intended. Exclude large files or directories from your bundle, then try again.")}let n=p(e),r;for(let s=1;s<=E;s++){if(r=await f(o,{method:"put",body:n},"slow-request"),r.ok)return;let T=s===E;if(_.has(r.status)&&!T){await r.text().catch(()=>{}),await d(2**s*.1);continue}break}let a=r?.status,c=(await r?.text().catch(()=>""))?.trim();throw new i(`Failed to upload your app bundle to storage${a?` (HTTP ${a})`:""}.`,"This is usually transient. Please try again, and check your network connection if it persists.",c?[`Storage responded with: ${c.slice(0,300)}`]:void 0)}async function D(o,e){let t=await o.generateSignedUploadUrl(e);if(!t.assetUrl||t.userErrors?.length>0){let n=t.userErrors.map(r=>r.message).join(", ");throw new i(n)}return t.assetUrl}export{j as a,A as b,k as c,C as d,D as e};
|
package/dist/chunk-XUUIBSLW.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{g as I}from"./chunk-VKWPEFWQ.js";I();var o="4.9.4";export{o as a};
|
package/dist/chunk-XWQM2NZ2.js
DELETED
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{a as y}from"./chunk-PWS4VFSD.js";import{a as d}from"./chunk-PO5T44H3.js";import{Ha as h}from"./chunk-UNHT4ZFP.js";import{b as g,c as l}from"./chunk-NU5WLZ6Y.js";import{a as m}from"./chunk-7VAKNVFD.js";import{Ib as u,Vb as f,b as e}from"./chunk-UWI76E2L.js";import{g as o}from"./chunk-VKWPEFWQ.js";o();o();function S(s){return s.allExtensions.filter(t=>t.isFunctionExtension).map(t=>({source:`extensions.${t.configuration.handle}`,namespace:"extensions",handle:t.handle,name:t.name,type:t.type,externalType:t.externalType,humanName:t.humanName,uid:t.uid,directory:t.directory,configurationPath:t.configurationPath,configuration:t.configuration,entrySourceFilePath:t.entrySourceFilePath,outputPath:t.outputPath,surface:t.surface,features:t.features,dependency:t.dependency}))}o();var P=e.object({source:e.string(),namespace:e.literal("extensions"),handle:e.string(),name:e.string(),type:e.string(),externalType:e.string(),humanName:e.string(),uid:e.string(),directory:e.string(),configurationPath:e.string(),configuration:e.record(e.unknown()),entrySourceFilePath:e.string(),outputPath:e.string(),surface:e.string(),features:e.array(e.string()),dependency:e.string().optional()}).strict(),c=m({name:"AppLogSourcesResult",schema:e.object({sources:e.array(P)}).strict(),definitions:{AppLogSource:P}});o();function j(s,t){if(t==="json"){u(c.encode({sources:s}));return}let r=new Map;s.forEach(({source:a})=>{let n=a.split(".");if(n.length>=2){let i=n[0];r.has(i)||r.set(i,[]),r.set(i,[...r.get(i),a])}});for(let[a,n]of r)u(f(a,n.join(`
|
|
2
|
-
`)))}var p=class s extends y{static summary="Print out a list of sources that may be used with the logs command.";static descriptionWithMarkdown="The output source names can be used with the `--source` argument of `shopify app logs` to filter log output. Currently only function extensions are supported as sources.";static get jsonOutputSchema(){return c}static description=this.descriptionForHelp();static flags={...g,...d,...l};async run(){let{flags:t}=await this.parse(s),{app:r}=await h({directory:t.path,clientId:t["client-id"],forceRelink:t.reset,userProvidedConfigName:t.config});return r.errors.isEmpty()?j(S(r),t.json?"json":"text"):process.exit(2),{app:r}}};export{p as a};
|
package/dist/chunk-Y3PY5LP7.js
DELETED
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
import{a as ne}from"./chunk-7556AIVG.js";import{d as ie}from"./chunk-NU5WLZ6Y.js";import{a as se,b as q}from"./chunk-4ZNBEMRT.js";import{B as C,K as L,pa as V,ra as U,sa as X,u as w}from"./chunk-3V4VL3SD.js";import{e as x}from"./chunk-QTLGMJDW.js";import{A as N,B as I,E as re,a as Q,x as te}from"./chunk-47IQIIFX.js";import{b as K}from"./chunk-HILYTMVA.js";import{d as Z,e as ee}from"./chunk-DSS4ECIH.js";import{i as F,l as oe}from"./chunk-Q37WAD6F.js";import{Cb as R,Eb as l,Ja as W,Nb as h,Ya as _}from"./chunk-UWI76E2L.js";import{b as Ie}from"./chunk-I3J63RFV.js";import{c as Y,e as k,h as J,p as $}from"./chunk-6IDEDOXW.js";import{e as Te,g as f}from"./chunk-VKWPEFWQ.js";f();var T=Te(Ie(),1);var O={path:T.Flags.string({description:"The path where you want to run the command. Defaults to the current working directory.",env:"SHOPIFY_FLAG_PATH",parse:async t=>{let e=k(t);return _(e)?W(e)?e:(I({headline:"The path must be a directory, not a file.",body:[`The provided path is not a directory: ${e}`,`Did you mean: ${J(e)}`]}),process.exit(1)):(I({headline:"A path was explicitly provided but doesn't exist.",body:[`Please check the path and try again: ${e}`]}),process.exit(1))},default:async()=>$(),noCacheDefault:!0}),password:T.Flags.string({description:"Password generated from the Theme Access app or an Admin API token.",env:"SHOPIFY_CLI_THEME_TOKEN"}),store:T.Flags.string({char:"s",description:"Store URL. It can be the store prefix (example) or the full myshopify.com URL (example.myshopify.com, https://example.myshopify.com).",env:"SHOPIFY_FLAG_STORE",parse:async t=>w(t)}),environment:T.Flags.string({char:"e",description:"The environment to apply to the current command.",env:"SHOPIFY_FLAG_ENVIRONMENT",multiple:!0})},ae="Wrap the value in double quotes if you're using wildcards.",qe=t=>({only:T.Flags.string({char:"o",multiple:!0,description:`${t.charAt(0).toUpperCase()+t.slice(1)} only the specified files (Multiple flags allowed). ${ae}`,env:"SHOPIFY_FLAG_ONLY"}),ignore:T.Flags.string({char:"x",multiple:!0,description:`Skip ${t}ing the specified files (Multiple flags allowed). ${ae}`,env:"SHOPIFY_FLAG_IGNORE"})});f();f();import{AsyncLocalStorage as _e}from"node:async_hooks";var pe=new _e,ce,ue,me,de;function S(){return ce??=new x({projectName:"shopify-cli-theme-conf"}),ce}function j(){return ue??=new x({projectName:"shopify-cli-development-theme-config"}),ue}function D(){return me??=new x({projectName:"shopify-cli-repl-theme-config"}),me}function M(){return de??=new x({projectName:"shopify-cli-theme-store-password"}),de}function B(t=S()){return pe.getStore()?.store??t.get("themeStore")}function fe(t,e=S()){e.set("themeStore",t)}function He(t=S()){return h(l`Getting development theme...`),j().get(v(t))}function ze(t,e=S()){h(l`Setting development theme...`),j().set(v(e),t)}function Ye(t=S()){h(l`Removing development theme...`),j().delete(v(t))}function Je(t=S()){return h(l`Getting REPL theme...`),D().get(v(t))}function We(t,e=S()){h(l`Setting REPL theme to ${t}...`),D().set(v(e),t)}function Ke(t=S()){h(l`Removing REPL theme...`),D().delete(v(t))}function Qe(t=S()){let e=v(t);return h(l`Getting storefront password for shop ${e}...`),M().get(e)}function Ve(t,e=S()){let o=v(e);h(l`Setting storefront password for shop ${o}...`),M().set(o,t)}function Xe(t=S()){let e=v(t);h(l`Removing storefront password for ${e}...`),M().delete(e)}function v(t=S()){let e=B(t);if(!e)throw new oe("Theme store is not set. This indicates an unexpected issue with the CLI. Please report this to the Shopify CLI team.",["It may be possible to recover by running",{command:"shopify theme list --store <store>"},"(setting the store flag to the store you wish to use) and then running the command again."]);return e}async function he(t,e){return pe.run({store:t},e)}function le(t){let e=t.store??B();if(!e)throw V(new F("A store is required",`Specify the store passing ${l`${R.genericShellCommand(`--${O.store.name}=example.myshopify.com`)}`.value} or set the ${l`${R.genericShellCommand(O.store.env)}`.value} environment variable.`));return fe(e),e}f();f();var Se="shopify.theme.toml",ct=new Intl.DateTimeFormat(void 0,{hour12:!1,hour:"2-digit",minute:"2-digit",second:"2-digit"}),ut=["**/.git","**/.vscode","**/.hg","**/.bzr","**/.svn","**/_darcs","**/CVS","**/*.sublime-(project|workspace)","**/.DS_Store","**/.sass-cache","**/Thumbs.db","**/desktop.ini","**/config.yml","**/node_modules/",".prettierrc.json","**/{blocks,layout,snippets}/**/*.liquid.tmp.*","**/{config,locales}/**/*.json.tmp.*","**/{sections,templates}/**/*.{liquid,json}.tmp.*"],mt=50;f();f();var G="7e9cb568cfd431c538f36d1ad3f2b4f6";var Fe="shopify-cli-store",be=240*1e3,ge;function P(){return ge??=new x({projectName:Fe}),ge}function b(t){return`${G}::${Ee(t)}`}function Ee(t){return t.replace(/\\/g,"\\\\").replace(/\./g,"\\.")}function d(t){return typeof t=="string"}function ke(t){if(!t||typeof t!="object")return;let e=t;if(typeof e.id=="number")return{id:e.id,...d(e.email)?{email:e.email}:{},...d(e.firstName)?{firstName:e.firstName}:{},...d(e.lastName)?{lastName:e.lastName}:{},...typeof e.accountOwner=="boolean"?{accountOwner:e.accountOwner}:{}}}function $e(t){if(!t||typeof t!="object")return;let e=t;if(!(!d(e.shopId)||!d(e.name)||!d(e.createdAt)))return{shopId:e.shopId,name:e.name,createdAt:e.createdAt,...d(e.placeholderAccountUuid)?{placeholderAccountUuid:e.placeholderAccountUuid}:{},...d(e.country)?{country:e.country}:{},...d(e.accessUrl)?{accessUrl:e.accessUrl}:{}}}function Pe(t){if(!t||typeof t!="object")return;let e=t;if(!d(e.store)||!d(e.clientId)||!d(e.userId)||!d(e.accessToken)||!Array.isArray(e.scopes)||!e.scopes.every(d)||!d(e.acquiredAt))return;let o=ke(e.associatedUser),r=e.kind==="preview"?"preview":"standard",n=r==="preview"?$e(e.preview):void 0;if(!(r==="preview"&&!n))return{store:e.store,clientId:e.clientId,userId:e.userId,accessToken:e.accessToken,scopes:e.scopes,acquiredAt:e.acquiredAt,...d(e.refreshToken)?{refreshToken:e.refreshToken}:{},...d(e.expiresAt)?{expiresAt:e.expiresAt}:{},...d(e.refreshTokenExpiresAt)?{refreshTokenExpiresAt:e.refreshTokenExpiresAt}:{},...o?{associatedUser:o}:{},...r==="preview"?{kind:r}:{},...n?{preview:n}:{}}}function ye(t,e,o){if(!e||typeof e!="object")return;let{sessionsByUserId:r,currentUserId:n}=e;if(!(r!==void 0||n!==void 0))return;let s=b(t);if(!r||typeof r!="object"||Array.isArray(r)||typeof n!="string"){o.delete(s);return}let a=Object.fromEntries(Object.entries(r).flatMap(([u,c])=>{let p=Pe(c);return p?[[u,p]]:[]}));if(Object.keys(a).length!==Object.keys(r).length)if(a[n])o.set(s,{currentUserId:n,sessionsByUserId:a});else{o.delete(s);return}return{currentUserId:n,sessionsByUserId:a}}function H(t,e){return ye(t,e.get(b(t)),e)}function Ce(t){return t.config?.store??{}}function we(t=P()){let e=[],o=`${G}::`;for(let[r,n]of Object.entries(Ce(t))){if(!r.startsWith(o))continue;let i=ye(r.slice(o.length),n,t),s=i?.sessionsByUserId[i.currentUserId];s&&e.push(s)}return e}function Ae(t,e=P()){let o=w(t),r=H(o,e);if(!r)return;let n=r.sessionsByUserId[r.currentUserId];if(!n){e.delete(b(o));return}return n}function wt(t,e=P()){let o=b(t.store),r=H(t.store,e),n={currentUserId:t.userId,sessionsByUserId:{...r?.sessionsByUserId??{},[t.userId]:t}};e.set(o,n)}function At(t,e,o){let r=w(t),n=typeof e=="string"?e:void 0,i=(typeof e=="string"?o:e)??P(),s=b(r);if(!n){i.delete(s);return}let a=H(r,i);if(!a)return;let{[n]:u,...c}=a.sessionsByUserId,p=Object.keys(c);if(p.length===0){i.delete(s);return}i.set(s,{currentUserId:a.currentUserId===n?p[0]:a.currentUserId,sessionsByUserId:c})}function ve(t){if(!t.expiresAt)return!1;let e=new Date(t.expiresAt).getTime();return Number.isNaN(e)?!0:e-be<Date.now()}var z=class extends q{static baseFlags={...q.baseFlags,...ie};environmentsFilename(){return Se}async command(e,o,r=!1,n,i){}async run(e){let o=this.constructor,r=o.multiEnvironmentsFlags,{args:n,flags:i}=await this.parse(o),s="password"in o.flags,a=(Array.isArray(i.environment)?i.environment:[i.environment]).filter(Boolean),u=r!==null&&r.some(m=>Array.isArray(m)?m.includes("store"):m==="store");if(a.length<=1){if(a[0]&&!i.store&&u)throw new F("Please provide a valid environment.");let m=s?await this.createSession(i):void 0,A=this.constructor.name.toLowerCase();if(U(`theme-command:${A}:single-env:authenticated`),i.path&&!_(i.path))throw new F(`Path does not exist: ${i.path}`);try{await this.command(i,m,!1,n)}finally{await this.logAnalyticsData(m)}return}if(r===null){N({body:"This command does not support multiple environments."});return}let{flags:c}=await this.parse(se(o),this.argv);if("path"in c){this.errorOnGlobalPath();return}let p=await this.loadEnvironments(a,i,c),g=await this.validateEnvironments(p,r,s);"force"in o.flags&&!i.force&&!await this.showConfirmation(this.constructor.name,r,g)||await this.runConcurrent(g.valid)}storeAuthScopes(){}async loadEnvironments(e,o,r){let n=new Map;for(let i of e){let s=await ne(i,"shopify.theme.toml",{from:o.path,silent:!0});s?.store&&typeof s.store=="string"&&(s.store=w(s.store)),s?.path&&typeof s.path=="string"&&(s.path=k(s.path)),n.set(i,{flags:{...o,...s,...r,environment:[i]},validationFlags:{...s,...r}})}return n}async validateEnvironments(e,o,r){let n=[],i=[],s=r?this.storeAuthSessionsForTheme(Array.from(e.values()).map(({validationFlags:u})=>u)):new Map,a=Array.from(e.entries()).map(([u,{flags:c,validationFlags:p}])=>({environmentName:u,flags:c,validationFlags:p,storeAuthSession:this.storeAuthSessionFromCache(p,s)}));for(let{environmentName:u,flags:c,validationFlags:p,storeAuthSession:g}of a){let y=this.validConfig(p,o,u,g);if(y!==!0){let m=y.join(", ");i.push({environment:u,reason:`Missing flags: ${m}`});continue}n.push({environment:u,flags:c,requiresAuth:r,storeAuthSession:g})}return{valid:n,invalid:i}}async showConfirmation(e,o,r){let s={message:[`Run ${e.toLowerCase()} in the following environments?`],confirmationMessage:"Yes, proceed",cancellationMessage:"Cancel"},a=[...r.valid.map(({environment:u,flags:c})=>{let p=o.map(g=>{let y=Array.isArray(g)?g.find(m=>c[m]):g;if(y==="password")return"password";if(y==="path"&&typeof c.path=="string"){let m=c.path.split(/[/\\]/);if(m.length===1)return`path: ${c.path}`;let A=m[0]===""?`/${m[1]}`:m[0],E=m.at(-1);return`path: ${A}/.../${E}`}return y&&`${y}: ${c[y]}`}).join(", ");return[u,{subdued:p||"No flags required"}]}),...r.invalid.map(({environment:u,reason:c})=>[u,{error:`Skipping | ${c}`}])];return s.infoTable={Environment:a},r.invalid.length>0&&(s.confirmationMessage="Proceed anyway (will skip invalid environments)"),re(s)}async runConcurrent(e){let o=new Q,r=e.map(s=>s.flags.store),n=new Set(r),i=r.length===n.size?[e]:this.createSequentialGroups(e);for(let s of i)await te({processes:s.map(({environment:a,flags:u,requiresAuth:c,storeAuthSession:p})=>({prefix:a,action:async(g,y,m)=>{try{let A=u.store;await he(A,async()=>{let E=c?await this.createSession(u,p):void 0,xe=this.constructor.name.toLowerCase();U(`theme-command:${xe}:multi-env:authenticated`);try{await this.command(u,E,!0,{},{stdout:g,stderr:y})}finally{await this.logAnalyticsData(E)}})}catch(A){A instanceof Error&&(A.message=`Environment ${a} failed:
|
|
2
|
-
|
|
3
|
-
${A.message}`,I({body:[A.message]}))}}})),abortSignal:o.signal,showTimestamps:!0,renderOptions:{stdout:process.stderr}})}createSequentialGroups(e){let o=[];return e.forEach(r=>{let n=o.find(i=>!i.some(s=>s.flags.store===r.flags.store));n?n.push(r):o.push([r])}),o}async createSession(e,o){let r=le({store:e.store}),n=e.password;return n?await L(r,n):o??await this.storeAuthSessionForTheme({store:r})??await L(r,n)}async storeAuthSessionForTheme(e){let o=this.storeAuthScopes();if(!o)return;let r=typeof e.store=="string"?e.store:void 0,n=e.password;if(!r||n)return;let i=w(r),s=Ae(i);if(s)return this.adminSessionFromStoreAuthSession(s,i,o)}storeAuthSessionsForTheme(e){let o=this.storeAuthScopes();if(!o)return new Map;let r=new Set(e.filter(({store:n,password:i})=>typeof n=="string"&&!i).map(({store:n})=>w(n)));return r.size===0?new Map:new Map(we().map(n=>{let i=w(n.store);if(!r.has(i))return;let s=this.adminSessionFromStoreAuthSession(n,i,o);return s?[i,s]:void 0}).filter(n=>n!==void 0))}storeAuthSessionFromCache(e,o){let r=typeof e.store=="string"?e.store:void 0,n=e.password;if(!(!r||n))return o.get(w(r))}adminSessionFromStoreAuthSession(e,o,r){if(ve(e)){h(`Ignoring stored store auth session for ${o}: it expired at ${e.expiresAt??"unknown"}.`);return}if(!this.hasRequiredStoreAuthScopes(e.scopes,r)){h(`Ignoring stored store auth session for ${o}: it is missing required scopes (has: ${e.scopes.join(", ")}; needs: ${r.join(", ")}).`);return}return h(`Using stored store auth session for ${o} (scopes: ${e.scopes.join(", ")}).`),C(e.userId),{token:e.accessToken,storeFqdn:o}}expandImpliedStoreAuthScopes(e){let o=new Set(e);for(let r of e){let n=r.match(/^(unauthenticated_)?write_(.*)$/);n&&o.add(`${n[1]??""}read_${n[2]}`)}return o}hasRequiredStoreAuthScopes(e,o){let r=this.expandImpliedStoreAuthScopes(e);return o.every(n=>r.has(n))}validConfig(e,o,r,n){let i=o.filter(s=>Array.isArray(s)?!s.some(a=>this.hasRequiredFlag(e,a,n)):!this.hasRequiredFlag(e,s,n)).map(s=>Array.isArray(s)?s.join(" or "):s);return i.length>0?(N({body:[`Missing required flags in environment configuration${r?` for ${r}`:""}:`,{list:{items:i}}]}),i):!0}hasRequiredFlag(e,o,r){return o==="password"&&r?!0:!!e[o]}errorOnGlobalPath(){let e=Y($(),"shopify.theme.toml"),o=_(e);I({body:["Can't use `--path` flag with multiple environments.",...o?["Configure each environment's theme path in your shopify.theme.toml file instead."]:["Run this command from the directory containing shopify.theme.toml.","No shopify.theme.toml found in current directory."]]})}async logAnalyticsData(e){if(!e)return;let o=X();await Z(()=>({store_fqdn_hash:K(e.storeFqdn),store_domain:e.storeFqdn,cmd_theme_timings:JSON.stringify(o.timings),cmd_theme_errors:JSON.stringify(o.errors),cmd_theme_retries:JSON.stringify(o.retries),cmd_theme_events:JSON.stringify(o.events)})),await ee(()=>({store_fqdn:e.storeFqdn}))}};export{G as a,we as b,Ae as c,wt as d,At as e,B as f,He as g,ze as h,Ye as i,Je as j,We as k,Ke as l,Qe as m,Ve as n,Xe as o,O as p,qe as q,le as r,ct as s,ut as t,mt as u,z as v};
|
package/dist/chunk-Y62EMOQA.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{A as s,y as d,z as a}from"./chunk-47IQIIFX.js";import{Ib as r}from"./chunk-UWI76E2L.js";import{g as t}from"./chunk-VKWPEFWQ.js";t();t();function l(e){let i=e.status==="success"?{schemaVersion:1,...e.submission}:{schemaVersion:1,...e.submission,failure:e.failure};return JSON.stringify(i,null,2)}function p(e){return JSON.stringify({schemaVersion:1,outcomes:e.outcomes},null,2)}function D(e){f(e)}function R(e,i){return i.json?r(l(e)):e.status==="failed"?S(e):i.watch?d({headline:"Subscription migration operations.",body:e.submission.operations.map(({operation:o})=>c(o))}):f(e.submission),e.status==="failed"?1:0}function v(e,i){let o=e.outcomes.some(({status:n})=>n==="failed");return i.json?r(p(e)):o?s({headline:"Some subscription migration operations could not be canceled.",body:m(e.outcomes)}):a({headline:"Subscription migration operations canceled.",body:m(e.outcomes)}),o?1:0}function f(e){let i=e.action==="schedule"?"scheduled":"unscheduled";a({headline:`Subscription migrations ${i}.`,body:[`Shops: ${e.total}`,"Operation IDs:",...e.operations.map(({operation:o})=>o.id),"Save every operation ID. You will need them to check or cancel this submission."]})}function S(e){if(e.failure.type==="operations"){s({headline:"Some subscription migration operations failed.",body:["Failed operation IDs:",...e.failure.operationIds,"Terminal operation outcomes:",...e.submission.operations.map(({operation:o})=>c(o)),"Save every operation ID. You will need them to inspect this submission."]});return}let i=e.submission.operations.map(({operation:o})=>o.id);s({headline:i.length===0?"Subscription migration submission failed.":"Some subscription migration operations were accepted before submission failed.",body:[...i.length===0?["Accepted operation IDs: None."]:["Accepted operation IDs:",...i],`Batch index: ${e.failure.batchIndex}`,"Errors:",...e.failure.userErrors.map(({message:o})=>o),...i.length===0?[]:["Save every accepted operation ID. You will need them to check or cancel accepted operations."]]})}function m(e){let i=e.filter(n=>n.status==="success"),o=e.filter(n=>n.status==="failed");return[...i.length===0?["Canceled operations: None."]:["Canceled operations:",...i.map(({operation:n})=>c(n))],...o.length===0?[]:["Failed operations:",...o.map(({operationId:n,operation:u,userErrors:b})=>{let h=u?` (returned status: ${u.status})`:"";return`${n}: ${b.map(({message:g})=>g).join("; ")}${h}`})]]}function c(e){return`${e.id}: ${e.status} (${e.results.edges.length}/${e.total} settled)`}export{D as a,R as b,v as c};
|
package/dist/chunk-Y743UVBS.js
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import{c as Ge}from"./chunk-TFXUDHCP.js";import{D as $e,E as He,H as te,L as D,X as Be,Z as E,_ as je,a as Pe,ca as b,da as K,e as qe,ga as V,ha as Ke,ia as A,j as Oe,k as ie,q as y,r as Me,s as ae,u as U}from"./chunk-3V4VL3SD.js";import{b as We}from"./chunk-ZDF5N422.js";import{w as oe}from"./chunk-3C4WVKSO.js";import{b as Le}from"./chunk-QTLGMJDW.js";import{a as Ve}from"./chunk-XUUIBSLW.js";import{D as Je,E as Ze,F as Qe,I as Xe,J as en,T as nn,z as Ye}from"./chunk-47IQIIFX.js";import{e as Ue,g as Ee}from"./chunk-HILYTMVA.js";import{a as we}from"./chunk-7VAKNVFD.js";import{i as c,l as T}from"./chunk-Q37WAD6F.js";import{Cb as tn,Eb as P,Ib as on,Nb as se,R as C,X as W,Xa as ze,_a as Ce,b as t,ja as xe,qa as Re}from"./chunk-UWI76E2L.js";import{i as re}from"./chunk-B4OMIONW.js";import{g as an}from"./chunk-UEBUGSBT.js";import{c as Ie,i as j}from"./chunk-6IDEDOXW.js";import{e as B,g as s}from"./chunk-VKWPEFWQ.js";s();function q(e,{httpsOnly:n=!1,message:i="Invalid URL"}={}){return e.refine(a=>de(a,n),{message:i}).refine(a=>!a.includes(`
|
|
2
|
-
`),{message:i})}function it(e,{message:n="URL must be HTTPS URL or start with /"}={}){return e.refine(i=>i.startsWith("/")||de(i,!0),{message:n})}var rn=/[\r\n\t]/;function sn(e){return de(e,!0)}function de(e,n){try{let i=new URL(e);return n?i.protocol==="https:":["http:","https:"].includes(i.protocol)}catch{return!1}}function at(e){return typeof e=="string"&&!e.startsWith("/")?`/${e}`:e}var wi=30;function tt(e){return e.length<=wi}s();s();s();function dn(e){return qe`
|
|
3
|
-
query OrganizationBetaFlags($organizationId: OrganizationID!) {
|
|
4
|
-
organization(organizationId: $organizationId) {
|
|
5
|
-
id
|
|
6
|
-
${e.map(n=>`flag_${n}: hasFeatureFlag(handle: "${n}")`).join(`
|
|
7
|
-
`)}
|
|
8
|
-
}
|
|
9
|
-
}`}s();var ln={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"OrganizationExpFlags"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"organizationId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"OrganizationID"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"flagHandles"}},type:{kind:"NonNullType",type:{kind:"ListType",type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"organization"},arguments:[{kind:"Argument",name:{kind:"Name",value:"organizationId"},value:{kind:"Variable",name:{kind:"Name",value:"organizationId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"enabledFlags"},arguments:[{kind:"Argument",name:{kind:"Name",value:"flagHandles"},value:{kind:"Variable",name:{kind:"Name",value:"flagHandles"}}}]},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};s();var le=class extends c{},w=class extends c{constructor(n,i){let a="unknown",o=d=>`an ${d}`;He(n)?(a=n.orgName,o=d=>`the ${d} organization`):$e(n)&&(a=n.email,o=d=>`the ${d} user`);let r=P`${tn.yellow(a)}`.value,l=[[`Your current active session is associated with ${o(r)} account. To start a new session with a different account, run`,{command:"shopify auth login"}],["Have you",{link:{label:"created a Shopify Partners organization",url:"https://partners.shopify.com/signup"}},{char:"?"}],["Does your account include",{subdued:"Manage app"},"permissions?, please contact the owner of the organization to grant you access."],"Have you confirmed your accounts from the emails you received?",["Need to connect to a different App or organization? Run the command again with",{command:"--reset"}]];i&&l.push(["Do you have access to the right Shopify Partners organization? The CLI is loading",{link:{label:"this organization",url:`https://partner.shopify.com/${i}`}}]),super("No Organization found",void 0,l)}};async function ft(){let e=mn(),n=await e.organizations();if(n.length===0){let i=await e.session();throw new w(i.accountInfo)}return n}async function Nt(e,n){let i=await n.orgFromId(e);if(!i)throw new w((await n.session()).accountInfo,e);return i}async function gt(e,n,i,a=["APP_DEVELOPMENT"]){let o=await i.storeByDomain(e.id,n,a);if(!o){let l=a.length===1&&a[0]==="APP_DEVELOPMENT"?"Ensure you have provided the correct store domain, that the store is a dev store, and that you have access to the store.":"Ensure you have provided the correct store domain and that you have access to the store.";throw new le(`Could not find store for domain ${n} in organization ${e.businessName}.`,l)}return o}s();var un={skipEsbuildReactDedeuplication:"SHOPIFY_CLI_SKIP_ESBUILD_REACT_DEDUPLICATION",disableGraphiQLExplorer:"SHOPIFY_CLI_DISABLE_GRAPHIQL",useDynamicConfigSpecifications:"SHOPIFY_CLI_DYNAMIC_CONFIG",enableAppLogPolling:"SHOPIFY_CLI_ENABLE_APP_LOG_POLLING",templatesJsonPath:"SHOPIFY_CLI_APP_TEMPLATES_JSON_PATH",mkcertBinaryPath:"SHOPIFY_CLI_MKCERT_BINARY",disableMinificationOnDev:"SHOPIFY_CLI_DISABLE_MINIFICATION_ON_DEV"},Ii={app:"shopify.app.toml",web:"shopify.web.toml",appEnvironments:"shopify.environments.toml",lockFile:".shopify.lock",hiddenConfig:"project.json",hiddenFolder:".shopify"},yt={production:".env"},bt={reactTypes:"17.0.30"},cn={extensions:{directoryName:"extensions",defaultRegistrationLimit:1},web:{directoryName:"web",configurationName:Ii.web}},Ft={graphiql:3457,localhost:3458},_t=/^([a-zA-Z_$])([a-zA-Z0-9_$])*$/;s();var G;(function(e){e.Partners="Partners",e.BusinessPlatform="BusinessPlatform"})(G||(G={}));s();s();var pn=50,kn=250,xi=t.object({namespace:t.string(),key:t.string(),owner_type:t.string().optional()}),Ri=t.object({sms_marketing:t.boolean().optional(),customer_privacy:t.boolean().optional()}),zi=t.object({sources:t.array(t.string()).optional()}),Ci=t.object({network_access:t.boolean().optional(),block_progress:t.boolean().optional(),api_access:t.boolean().optional(),collect_buyer_consent:Ri.optional(),iframe:zi.optional(),bundle_size_exception:t.boolean().optional()}),Ui=t.object({runs_offline:t.boolean().optional()}),It=t.object({type:t.string().optional(),extensions:t.array(t.any()).optional()}),Ei=t.object({event:t.string(),blocking:t.boolean().default(!1),applies_to:t.array(t.string()).optional()}),Pi=t.object({allow_direct_linking:t.boolean().optional(),intercepts:t.array(Ei).optional()}),qi=t.object({module:t.string()}),Oi=t.object({target:t.string(),module:t.string(),should_render:qi.optional(),tools:t.string().optional(),instructions:t.string().optional(),intents:t.array(t.object({type:t.string(),action:t.string(),schema:t.string(),name:t.string().optional(),description:t.string().optional()})).optional(),metafields:t.array(xi).optional(),default_placement:t.string().optional(),urls:t.object({edit:t.string().optional()}).optional(),capabilities:Pi.optional(),preloads:t.object({chat:t.string().optional()}).optional(),assets:t.string().optional()}),xt=t.array(Oi),vn=t.string(),Li=t.object({key:t.string().optional(),name:t.string().optional(),description:t.string().optional(),required:t.boolean().optional(),default_value:t.any().optional(),type:t.string(),validations:t.array(t.any()).optional(),marketingActivityCreateUrl:t.string().optional(),marketingActivityDeleteUrl:t.string().optional()}),fn=t.object({fields:t.array(Li).optional()}),Nn=t.string().trim().nonempty("Handle can't be empty").max(pn,`Handle can't exceed ${pn} characters`).regex(/^[a-zA-Z0-9-]*$/,"Handle can only contain alphanumeric characters and hyphens").refine(e=>!e.startsWith("-")&&!e.endsWith("-"),"Handle can't start or end with a hyphen"),Mi=t.string().trim().nonempty("UID can't be empty").max(kn,`UID can't exceed ${kn} characters`).regex(/^[a-zA-Z0-9-${}.()_`]*$/,"UID can only contain alphanumeric characters and hyphens").refine(e=>!e.startsWith("-")&&!e.endsWith("-"),"UID can't start or end with a hyphen"),Y=t.object({name:t.string().optional(),type:t.string().optional(),handle:Nn.optional(),uid:Mi.optional(),description:t.string().optional(),api_version:vn.optional(),extension_points:t.any().optional(),capabilities:Ci.optional(),supported_features:Ui.optional(),settings:fn.optional()}),Rt=Y.extend({handle:Nn}),F=Y.omit({handle:!0}),zt=t.object({api_version:vn.optional(),description:t.string().optional(),extensions:t.array(t.any()),settings:fn.optional()});s();s();s();s();var $i=/^(https:\/\/)/,Hi=/^pubsub:\/\/(?<gcp_project_id>[^:]+):(?<gcp_topic>.+)$/,Bi=/^arn:aws:events:(?<aws_region>[a-z]{2}-[a-z]+-[0-9]+)::event-source\/aws\.partner\/shopify\.com(\.test)?\/(?<api_client_id>\d+)\/(?<event_source_name>.+)$/,ji=/^kafka:\/\/(?<kafka_topic>[a-zA-Z0-9_.-]+)$/;function I(e){return typeof e=="string"&&e.endsWith("/")?e.replace(/\/+$/,""):e}var _=t.string({invalid_type_error:"Value must be string"}).refine(e=>e.startsWith("/")?!0:$i.test(e)||Hi.test(e)||Bi.test(e)||ji.test(e),{message:"URI format isn't correct. Valid formats include: relative path starting with a slash, HTTPS URL, pubsub://{project-id}:{topic-id}, kafka://{topic-id} or Eventbridge ARN"});function J(e,n){return!n||!e.startsWith("/")?e:`${I(n)}${e}`}var Wi=(e,n,i,a)=>{if(i.startsWith("//"))throw new c(`${e} ${n} is invalid: a URL relative to the app URL must start with a single slash.`);if(rn.test(i))throw new c(`${e} ${n} is invalid: a URL must not contain control characters such as newlines or tabs.`);let o=J(i,a);if(o.startsWith("/"))throw new c(`${e} ${n} is a relative URL, but no application_url is configured. Set application_url in your app configuration or use an absolute HTTPS URL.`);if(!sn(o))throw new c(`${e} ${n} must resolve to an HTTPS URL. Set application_url to an HTTPS URL or use an absolute HTTPS URL.`);return o};function me(e,n,i,a){let o=i;for(let r of n){let l=o[r];typeof l=="string"&&l.startsWith("/")&&(o[r]=Wi(e,r,l,a))}}s();import{isUtf8 as Ki}from"node:buffer";import gn from"fs";async function Sn(e,n){let i=await Ce(Ie(e,"locales/*.json"));if(!i||i.length===0)return{};let a=Gi(i);if(a.length===0)throw new c(`Missing default language in ${n} configuration`,"Make sure to have a {locale}.default.json file in your locales directory");if(a.length>1)throw new c(`Error loading ${n}`,'There must be one (and only one) locale identified as the default locale: e.g. "en.default.json"');for(let o of i)if(gn.statSync(o).size===0)throw new c(`Error loading ${n}`,`Locale file ${o} can't be empty`);return{default_locale:a[0],translations:Yi(i,n)}}function Gi(e){return e.filter(i=>j(i).endsWith(".default.json")).map(i=>j(i).split(".")[0])}function Yi(e,n){let i={};for(let a of e){let o=Ji(j(a).split(".")[0],"Locale code is unset"),r=gn.readFileSync(a);if(!Ki(r))throw new c(`Error loading ${n}`,`Locale file ${a} contains invalid UTF-8 byte sequences. Re-save the file using UTF-8 encoding.`);i[o]=r.toString("base64")}return i}function Ji(e,n){if(e===void 0)throw new T(n);return e}function Zi(e){return e.experience==="configuration"}var hn;(function(e){e.ShouldRender="should_render",e.Main="main",e.Tools="tools",e.Instructions="instructions",e.Intents="intents"})(hn||(hn={}));function yn(e){let i={...{externalIdentifier:`${e.identifier}_external`,additionalIdentifiers:[],externalName:W(e.identifier.replace(/_/g," ")),surface:"test-surface",partnersWebIdentifier:e.identifier,schema:Y,registrationLimit:cn.extensions.defaultRegistrationLimit,transform:e.transformLocalToRemote,reverseTransform:e.transformRemoteToLocal,experience:e.experience??"extension",uidStrategy:e.uidStrategy??(e.experience==="configuration"?"single":"uuid"),getDevSessionUpdateMessages:e.getDevSessionUpdateMessages,clientSteps:e.clientSteps},...e};return{...i,contributeToAppConfigurationSchema:a=>{let o=Zi(i),r=i.schema._def.shape!==void 0,l=i.uidStrategy==="single";return o&&r&&l?a.merge(i.schema):a},parseConfigurationObject:a=>{let o=i.schema.safeParse(a);return o.success?{state:"ok",data:o.data,errors:void 0}:{state:"error",data:void 0,errors:o.error.errors}}}}function S(e){let n=e.appModuleFeatures??(()=>[]);return yn({identifier:e.identifier,schema:e.schema,appModuleFeatures:n,transformLocalToRemote:Qi(e.transformConfig),transformRemoteToLocal:Xi(e.schema,e.transformConfig),experience:"configuration",uidStrategy:e.uidStrategy??"single",expandConfig:e.expandConfig,getIdentity:e.getIdentity,getTarget:e.getTarget,clientSteps:e.clientSteps,getDevSessionUpdateMessages:e.getDevSessionUpdateMessages,patchWithAppDevURLs:e.patchWithAppDevURLs})}function so(e){let n=e.appRelativeUrlFields;return yn({identifier:e.identifier,schema:t.any({}),appModuleFeatures:e.appModuleFeatures,experience:e.experience,clientSteps:e.clientSteps,uidStrategy:e.uidStrategy,transformRemoteToLocal:e.transformRemoteToLocal,devSessionWatchConfig:e.devSessionWatchConfig,appRelativeUrlFields:n,patchWithAppDevURLs:n?.length?(i,a)=>{me(W(e.identifier.replace(/_/g," ")),n,i,a.applicationUrl)}:void 0,deployConfig:async(i,a,o,r,l)=>{let d=ea(i);if(n?.length){let m=l?.appConfiguration?.application_url,p=typeof m=="string"?m:void 0;me(W(e.identifier.replace(/_/g," ")),n,d,p)}if(e.appModuleFeatures().includes("localization")){let m=await Sn(a,e.identifier);d={...d,localization:m}}return d}})}function Qi(e){return Object.keys(e).includes("forward")?e.forward:n=>bn(n,e)}function Xi(e,n){return n?Object.keys(n).includes("reverse")?n.reverse:i=>bn(i,n,!0):i=>Fn(e,i)}function bn(e,n,i=!1){let a={};for(let[o,r]of Object.entries(n)){let l=i?o:r,d=i?r:o,m=E(e,l);m!==void 0&&je(a,d,m)}return a}function Fn(e,n){return Object.keys(e._def.shape()).reduce((i,a)=>{let o=e._def.shape()[a];return o instanceof t.ZodOptional&&(o=o._def.innerType),o instanceof t.ZodObject?i[a]=Fn(o,n):(n[a]!==void 0&&(i[a]=n[a]),delete n[a]),i},{})}function ea(e){let{type:n,handle:i,uid:a,path:o,extensions:r,...l}=e;return l}var na=F.extend({application_url:q(t.string({required_error:"Valid URL is required"})),embedded:t.boolean({required_error:"Boolean is required",invalid_type_error:"Value must be Boolean"}),app_preferences:t.object({url:q(t.string().max(255,{message:"String must be less than 255 characters"}))}).optional()}),ia={app_url:"application_url",embedded:"embedded",preferences_url:"app_preferences.url"},ue="app_home",aa=S({identifier:ue,schema:na,transformConfig:ia,patchWithAppDevURLs:(e,n)=>{e.application_url=n.applicationUrl},getDevSessionUpdateMessages:async e=>[`Using URL: ${e.application_url}`]}),vo=aa;s();var ta=F.extend({name:t.string({required_error:"String is required"}).max(30,{message:"String must be less than 30 characters"}),handle:t.string({required_error:"String is required"}).max(256,{message:"String must be less than 256 characters long"}).refine(e=>e&&/^\w*(?!-)[_a-z0-9-]+(?<!-)$/.test(e),{message:"String can't contain special characters"}).optional()}),oa={name:"name",app_handle:"handle"},ce="branding",ra=S({identifier:ce,schema:ta,transformConfig:oa}),yo=ra;s();var sa=t.object({scopes:t.string().transform(e=>xe(e)??"").optional(),required_scopes:t.array(t.string()).optional(),optional_scopes:t.array(t.string()).optional(),use_legacy_install_flow:t.boolean().optional()}),da=t.object({redirect_urls:t.array(q(t.string()))}),la=F.extend({access:t.object({admin:t.object({direct_api_mode:t.union([t.literal("online"),t.literal("offline")]).optional(),embedded_app_direct_api_access:t.boolean().optional()}).optional()}).optional(),access_scopes:sa.optional(),auth:da}),pe="app_access",ma={access:"access",scopes:"access_scopes.scopes",required_scopes:"access_scopes.required_scopes",optional_scopes:"access_scopes.optional_scopes",use_legacy_install_flow:"access_scopes.use_legacy_install_flow",redirect_url_allowlist:"auth.redirect_urls"},ua=S({identifier:pe,schema:la,transformConfig:ma,getDevSessionUpdateMessages:async e=>{let n=e.access_scopes!==void 0,i=e.access_scopes?.use_legacy_install_flow===!0,a=e.access_scopes?.scopes==null&&e.access_scopes?.required_scopes==null;if(i||n&&a)return["Using legacy install flow - access scopes are not auto-granted"];let o=e.access_scopes?.scopes?e.access_scopes.scopes.split(",").map(r=>r.trim()).join(", "):e.access_scopes?.required_scopes?.join(", ");return o?[`Access scopes auto-granted: ${o}`]:["App has been installed"]},patchWithAppDevURLs:(e,n)=>{n.redirectUrlWhitelist&&(e.auth={redirect_urls:n.redirectUrlWhitelist})}}),wo=ua;s();var _n={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"DevSessionCreate"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"appId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"assetsUrl"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"websocketUrl"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"unsafeValidation"}},type:{kind:"NamedType",name:{kind:"Name",value:"Boolean"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"devSessionCreate"},arguments:[{kind:"Argument",name:{kind:"Name",value:"appId"},value:{kind:"Variable",name:{kind:"Name",value:"appId"}}},{kind:"Argument",name:{kind:"Name",value:"assetsUrl"},value:{kind:"Variable",name:{kind:"Name",value:"assetsUrl"}}},{kind:"Argument",name:{kind:"Name",value:"websocketUrl"},value:{kind:"Variable",name:{kind:"Name",value:"websocketUrl"}}},{kind:"Argument",name:{kind:"Name",value:"isUnsafe"},value:{kind:"Variable",name:{kind:"Name",value:"unsafeValidation"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"devSession"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"websocketUrl"}},{kind:"Field",name:{kind:"Name",value:"updatedAt"}},{kind:"Field",name:{kind:"Name",value:"user"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"email"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"app"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"key"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"warnings"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"message"}},{kind:"Field",name:{kind:"Name",value:"code"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"userErrors"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"message"}},{kind:"Field",name:{kind:"Name",value:"on"}},{kind:"Field",name:{kind:"Name",value:"field"}},{kind:"Field",name:{kind:"Name",value:"category"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};s();var Dn={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"DevSessionUpdate"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"appId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"assetsUrl"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"manifest"}},type:{kind:"NamedType",name:{kind:"Name",value:"JSON"}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"inheritedModuleUids"}},type:{kind:"NonNullType",type:{kind:"ListType",type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"unsafeValidation"}},type:{kind:"NamedType",name:{kind:"Name",value:"Boolean"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"devSessionUpdate"},arguments:[{kind:"Argument",name:{kind:"Name",value:"appId"},value:{kind:"Variable",name:{kind:"Name",value:"appId"}}},{kind:"Argument",name:{kind:"Name",value:"assetsUrl"},value:{kind:"Variable",name:{kind:"Name",value:"assetsUrl"}}},{kind:"Argument",name:{kind:"Name",value:"manifest"},value:{kind:"Variable",name:{kind:"Name",value:"manifest"}}},{kind:"Argument",name:{kind:"Name",value:"inheritedModuleUids"},value:{kind:"Variable",name:{kind:"Name",value:"inheritedModuleUids"}}},{kind:"Argument",name:{kind:"Name",value:"isUnsafe"},value:{kind:"Variable",name:{kind:"Name",value:"unsafeValidation"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"devSession"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"websocketUrl"}},{kind:"Field",name:{kind:"Name",value:"updatedAt"}},{kind:"Field",name:{kind:"Name",value:"user"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"email"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"app"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"key"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"warnings"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"message"}},{kind:"Field",name:{kind:"Name",value:"code"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"userErrors"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"message"}},{kind:"Field",name:{kind:"Name",value:"on"}},{kind:"Field",name:{kind:"Name",value:"field"}},{kind:"Field",name:{kind:"Name",value:"category"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};s();var An={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"DevSessionDelete"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"appId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"devSessionDelete"},arguments:[{kind:"Argument",name:{kind:"Name",value:"appId"},value:{kind:"Variable",name:{kind:"Name",value:"appId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"userErrors"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"message"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};s();var Tn={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"FetchStoreByDomain"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"domain"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"filters"}},type:{kind:"ListType",type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"ShopFilterInput"}}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"organization"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"accessibleShops"},arguments:[{kind:"Argument",name:{kind:"Name",value:"filters"},value:{kind:"Variable",name:{kind:"Name",value:"filters"}}},{kind:"Argument",name:{kind:"Name",value:"search"},value:{kind:"Variable",name:{kind:"Name",value:"domain"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"edges"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"node"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"externalId"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"storeType"}},{kind:"Field",name:{kind:"Name",value:"primaryDomain"}},{kind:"Field",name:{kind:"Name",value:"shortName"}},{kind:"Field",name:{kind:"Name",value:"url"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"currentUser"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"organizationPermissions"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};s();var Vn={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"ListAppDevStores"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"searchTerm"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"organization"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"accessibleShops"},arguments:[{kind:"Argument",name:{kind:"Name",value:"filters"},value:{kind:"ListValue",values:[{kind:"ObjectValue",fields:[{kind:"ObjectField",name:{kind:"Name",value:"field"},value:{kind:"EnumValue",value:"STORE_TYPE"}},{kind:"ObjectField",name:{kind:"Name",value:"operator"},value:{kind:"EnumValue",value:"EQUALS"}},{kind:"ObjectField",name:{kind:"Name",value:"value"},value:{kind:"StringValue",value:"app_development",block:!1}}]},{kind:"ObjectValue",fields:[{kind:"ObjectField",name:{kind:"Name",value:"field"},value:{kind:"EnumValue",value:"STORE_STATUS"}},{kind:"ObjectField",name:{kind:"Name",value:"operator"},value:{kind:"EnumValue",value:"EQUALS"}},{kind:"ObjectField",name:{kind:"Name",value:"value"},value:{kind:"StringValue",value:"ACTIVE",block:!1}}]}]}},{kind:"Argument",name:{kind:"Name",value:"search"},value:{kind:"Variable",name:{kind:"Name",value:"searchTerm"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"edges"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"node"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"externalId"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"storeType"}},{kind:"Field",name:{kind:"Name",value:"primaryDomain"}},{kind:"Field",name:{kind:"Name",value:"shortName"}},{kind:"Field",name:{kind:"Name",value:"url"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"pageInfo"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"hasNextPage"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"currentUser"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"organizationPermissions"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};s();var wn={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"DevStoreCapReached"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"organization"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"devStoreCapReached"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};s();var In={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"ProvisionShopAccess"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"input"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"OrganizationUserProvisionShopAccessInput"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"organizationUserProvisionShopAccess"},arguments:[{kind:"Argument",name:{kind:"Name",value:"organizationUserProvisionShopAccessInput"},value:{kind:"Variable",name:{kind:"Name",value:"input"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"success"}},{kind:"Field",name:{kind:"Name",value:"userErrors"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"message"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};s();var xn={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"ActiveAppReleaseFromApiKey"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"apiKey"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",alias:{kind:"Name",value:"app"},name:{kind:"Name",value:"appByKey"},arguments:[{kind:"Argument",name:{kind:"Name",value:"key"},value:{kind:"Variable",name:{kind:"Name",value:"apiKey"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"AppVersionInfo"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}},{kind:"FragmentDefinition",name:{kind:"Name",value:"ReleasedAppModule"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"AppModule"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"uuid"}},{kind:"Field",name:{kind:"Name",value:"userIdentifier"}},{kind:"Field",name:{kind:"Name",value:"handle"}},{kind:"Field",name:{kind:"Name",value:"config"}},{kind:"Field",name:{kind:"Name",value:"target"}},{kind:"Field",name:{kind:"Name",value:"specification"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"identifier"}},{kind:"Field",name:{kind:"Name",value:"externalIdentifier"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"experience"}},{kind:"Field",name:{kind:"Name",value:"managementExperience"}}]}}]}},{kind:"FragmentDefinition",name:{kind:"Name",value:"AppVersionInfo"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"App"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"key"}},{kind:"Field",name:{kind:"Name",value:"organizationId"}},{kind:"Field",name:{kind:"Name",value:"activeRoot"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"clientCredentials"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"secrets"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"key"}}]}}]}},{kind:"Field",name:{kind:"Name",value:"grantedShopifyApprovalScopes"}}]}},{kind:"Field",name:{kind:"Name",value:"activeRelease"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"version"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"appModules"},selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"ReleasedAppModule"}}]}}]}}]}}]}}]};s();var ke={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"ReleaseVersion"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"appId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"ID"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"versionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"ID"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"appReleaseCreate"},arguments:[{kind:"Argument",name:{kind:"Name",value:"appId"},value:{kind:"Variable",name:{kind:"Name",value:"appId"}}},{kind:"Argument",name:{kind:"Name",value:"versionId"},value:{kind:"Variable",name:{kind:"Name",value:"versionId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"release"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"version"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"metadata"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"message"}},{kind:"Field",name:{kind:"Name",value:"versionTag"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"userErrors"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"field"}},{kind:"Field",name:{kind:"Name",value:"message"}},{kind:"Field",name:{kind:"Name",value:"category"}},{kind:"Field",name:{kind:"Name",value:"code"}},{kind:"Field",name:{kind:"Name",value:"on"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};s();var Rn={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateAppVersion"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"appId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"ID"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"version"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"AppVersionInput"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"metadata"}},type:{kind:"NamedType",name:{kind:"Name",value:"VersionMetadataInput"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"appVersionCreate"},arguments:[{kind:"Argument",name:{kind:"Name",value:"appId"},value:{kind:"Variable",name:{kind:"Name",value:"appId"}}},{kind:"Argument",name:{kind:"Name",value:"version"},value:{kind:"Variable",name:{kind:"Name",value:"version"}}},{kind:"Argument",name:{kind:"Name",value:"metadata"},value:{kind:"Variable",name:{kind:"Name",value:"metadata"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"version"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"appModules"},selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"ReleasedAppModule"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"metadata"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"versionTag"}},{kind:"Field",name:{kind:"Name",value:"message"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"userErrors"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"field"}},{kind:"Field",name:{kind:"Name",value:"message"}},{kind:"Field",name:{kind:"Name",value:"category"}},{kind:"Field",name:{kind:"Name",value:"code"}},{kind:"Field",name:{kind:"Name",value:"on"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}},{kind:"FragmentDefinition",name:{kind:"Name",value:"ReleasedAppModule"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"AppModule"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"uuid"}},{kind:"Field",name:{kind:"Name",value:"userIdentifier"}},{kind:"Field",name:{kind:"Name",value:"handle"}},{kind:"Field",name:{kind:"Name",value:"config"}},{kind:"Field",name:{kind:"Name",value:"target"}},{kind:"Field",name:{kind:"Name",value:"specification"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"identifier"}},{kind:"Field",name:{kind:"Name",value:"externalIdentifier"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"experience"}},{kind:"Field",name:{kind:"Name",value:"managementExperience"}}]}}]}}]};s();var zn={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateAssetURL"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"sourceExtension"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"SourceExtension"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"organizationId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"ID"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"appRequestSourceUploadUrl"},arguments:[{kind:"Argument",name:{kind:"Name",value:"sourceExtension"},value:{kind:"Variable",name:{kind:"Name",value:"sourceExtension"}}},{kind:"Argument",name:{kind:"Name",value:"organizationId"},value:{kind:"Variable",name:{kind:"Name",value:"organizationId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"sourceUploadUrl"}},{kind:"Field",name:{kind:"Name",value:"userErrors"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"field"}},{kind:"Field",name:{kind:"Name",value:"message"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};s();var Cn={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"AppVersionById"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"versionId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"ID"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"version"},arguments:[{kind:"Argument",name:{kind:"Name",value:"id"},value:{kind:"Variable",name:{kind:"Name",value:"versionId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"VersionInfo"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}},{kind:"FragmentDefinition",name:{kind:"Name",value:"ReleasedAppModule"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"AppModule"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"uuid"}},{kind:"Field",name:{kind:"Name",value:"userIdentifier"}},{kind:"Field",name:{kind:"Name",value:"handle"}},{kind:"Field",name:{kind:"Name",value:"config"}},{kind:"Field",name:{kind:"Name",value:"target"}},{kind:"Field",name:{kind:"Name",value:"specification"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"identifier"}},{kind:"Field",name:{kind:"Name",value:"externalIdentifier"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"experience"}},{kind:"Field",name:{kind:"Name",value:"managementExperience"}}]}}]}},{kind:"FragmentDefinition",name:{kind:"Name",value:"VersionInfo"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"Version"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"metadata"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"message"}},{kind:"Field",name:{kind:"Name",value:"versionTag"}}]}},{kind:"Field",name:{kind:"Name",value:"appModules"},selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"ReleasedAppModule"}}]}}]}}]};s();var Un={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"AppVersions"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"appId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"ID"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"app"},arguments:[{kind:"Argument",name:{kind:"Name",value:"id"},value:{kind:"Variable",name:{kind:"Name",value:"appId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"activeRelease"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"version"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"versions"},arguments:[{kind:"Argument",name:{kind:"Name",value:"first"},value:{kind:"IntValue",value:"20"}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"edges"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"node"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"createdAt"}},{kind:"Field",name:{kind:"Name",value:"createdBy"}},{kind:"Field",name:{kind:"Name",value:"metadata"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"message"}},{kind:"Field",name:{kind:"Name",value:"versionTag"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"versionsCount"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};s();var En={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"AppInstallCount"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"appId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"ID"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"app"},arguments:[{kind:"Argument",name:{kind:"Name",value:"id"},value:{kind:"Variable",name:{kind:"Name",value:"appId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"installCount"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};s();var Pn={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateApp"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"initialVersion"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"AppVersionInput"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"organizationId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"ID"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"appCreate"},arguments:[{kind:"Argument",name:{kind:"Name",value:"initialVersion"},value:{kind:"Variable",name:{kind:"Name",value:"initialVersion"}}},{kind:"Argument",name:{kind:"Name",value:"organizationId"},value:{kind:"Variable",name:{kind:"Name",value:"organizationId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"app"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"key"}},{kind:"Field",name:{kind:"Name",value:"activeRoot"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"clientCredentials"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"secrets"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"key"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"userErrors"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"category"}},{kind:"Field",name:{kind:"Name",value:"message"}},{kind:"Field",name:{kind:"Name",value:"on"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};s();var qn={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"fetchSpecifications"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"organizationId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"ID"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"specifications"},arguments:[{kind:"Argument",name:{kind:"Name",value:"organizationId"},value:{kind:"Variable",name:{kind:"Name",value:"organizationId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"identifier"}},{kind:"Field",name:{kind:"Name",value:"externalIdentifier"}},{kind:"Field",name:{kind:"Name",value:"experience"}},{kind:"Field",name:{kind:"Name",value:"features"}},{kind:"Field",name:{kind:"Name",value:"uidStrategy"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"__typename"}},{kind:"Field",name:{kind:"Name",value:"appModuleLimit"}},{kind:"Field",name:{kind:"Name",value:"isClientProvided"}}]}},{kind:"Field",name:{kind:"Name",value:"validationSchema"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"jsonSchema"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};s();var On={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"listApps"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"query"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"appsConnection"},arguments:[{kind:"Argument",name:{kind:"Name",value:"query"},value:{kind:"Variable",name:{kind:"Name",value:"query"}}},{kind:"Argument",name:{kind:"Name",value:"first"},value:{kind:"IntValue",value:"50"}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"edges"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"node"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"key"}},{kind:"Field",name:{kind:"Name",value:"activeRelease"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"version"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"pageInfo"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"hasNextPage"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};s();var Ln={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"UserInfo"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"currentUserAccount"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"uuid"}},{kind:"Field",name:{kind:"Name",value:"email"}},{kind:"Field",name:{kind:"Name",value:"organizations"},arguments:[{kind:"Argument",name:{kind:"Name",value:"first"},value:{kind:"IntValue",value:"2"}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"nodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};s();var Mn={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"availableTopics"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"apiVersion"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"availableTopics"},arguments:[{kind:"Argument",name:{kind:"Name",value:"apiVersion"},value:{kind:"Variable",name:{kind:"Name",value:"apiVersion"}}}]}]}}]};s();var $n={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CliTesting"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"address"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"apiKey"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"apiVersion"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"deliveryMethod"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"sharedSecret"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"topic"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"cliTesting"},arguments:[{kind:"Argument",name:{kind:"Name",value:"address"},value:{kind:"Variable",name:{kind:"Name",value:"address"}}},{kind:"Argument",name:{kind:"Name",value:"apiKey"},value:{kind:"Variable",name:{kind:"Name",value:"apiKey"}}},{kind:"Argument",name:{kind:"Name",value:"apiVersion"},value:{kind:"Variable",name:{kind:"Name",value:"apiVersion"}}},{kind:"Argument",name:{kind:"Name",value:"deliveryMethod"},value:{kind:"Variable",name:{kind:"Name",value:"deliveryMethod"}}},{kind:"Argument",name:{kind:"Name",value:"sharedSecret"},value:{kind:"Variable",name:{kind:"Name",value:"sharedSecret"}}},{kind:"Argument",name:{kind:"Name",value:"topic"},value:{kind:"Variable",name:{kind:"Name",value:"topic"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"headers"}},{kind:"Field",name:{kind:"Name",value:"samplePayload"}},{kind:"Field",name:{kind:"Name",value:"success"}},{kind:"Field",name:{kind:"Name",value:"errors"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};s();var Hn={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"publicApiVersions"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"publicApiVersions"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"handle"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};s();var Bn={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"SchemaDefinitionByTarget"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"handle"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"version"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"target"},arguments:[{kind:"Argument",name:{kind:"Name",value:"handle"},value:{kind:"Variable",name:{kind:"Name",value:"handle"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"api"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"schema"},arguments:[{kind:"Argument",name:{kind:"Name",value:"version"},value:{kind:"Variable",name:{kind:"Name",value:"version"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"definition"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};s();var jn={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"SchemaDefinitionByApiType"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"type"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"version"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"api"},arguments:[{kind:"Argument",name:{kind:"Name",value:"type"},value:{kind:"Variable",name:{kind:"Name",value:"type"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"schema"},arguments:[{kind:"Argument",name:{kind:"Name",value:"version"},value:{kind:"Variable",name:{kind:"Name",value:"version"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"definition"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};s();s();s();var O;(function(e){e.CustomersRedact="customers/redact",e.CustomersDataRequest="customers/data_request",e.ShopRedact="shop/redact"})(O||(O={}));var Wn=t.object({topics:t.array(t.string({invalid_type_error:"Values within array must be a string"}),{invalid_type_error:"Value must be string[]"}).optional(),actions:t.array(t.string({invalid_type_error:"Value must be a string"})).optional(),uri:t.preprocess(e=>I(e),_,{required_error:"Missing value at"}),include_fields:t.array(t.string({invalid_type_error:"Value must be a string"})).optional(),filter:t.string({invalid_type_error:"Value must be a string"}).optional(),payload_query:t.string({invalid_type_error:"Value must be a string"}).trim().min(1).optional(),name:t.string({invalid_type_error:"Value must be a string"}).trim().min(1).max(50).optional(),compliance_topics:t.array(t.enum([O.CustomersRedact,O.CustomersDataRequest,O.ShopRedact]),{invalid_type_error:"Value must be an array containing values: customers/redact, customers/data_request or shop/redact"}).optional()});s();function Kn(e,n){let i=ca(e);if(i)return n.addIssue(i),t.NEVER}function ca(e){let{subscriptions:n=[]}=e,i=new Set,a=[];if(!n.length)return;if(e.privacy_compliance&&e.subscriptions?.some(r=>r.compliance_topics))return{code:t.ZodIssueCode.custom,message:"The privacy_compliance section can't be used if there are subscriptions including compliance_topics"};let o=n.flatMap(r=>r.compliance_topics).filter(Boolean);if(C(o).length!==o.length)return{code:t.ZodIssueCode.custom,message:"You can\u2019t have multiple subscriptions with the same compliance topic",fatal:!0,path:["subscriptions"]};for(let[r,{uri:l,topics:d=[],compliance_topics:m=[],filter:p=""}]of n.entries()){let k=["subscriptions",r];if(!d.length&&!m.length)return{code:t.ZodIssueCode.custom,message:"Either topics or compliance_topics must be added to the webhook subscription",path:k};d.forEach(u=>{let v=`${u}::${l}::${p}`;if(i.has(v)){let N=p?re.dim(`
|
|
10
|
-
|
|
11
|
-
topic: ${u}
|
|
12
|
-
uri: ${l}
|
|
13
|
-
filter: ${p}`):re.dim(`
|
|
14
|
-
|
|
15
|
-
topic: ${u}
|
|
16
|
-
uri: ${l}`);a.push(N)}i.add(v)})}if(a.length>0){let r=a.join("");return{code:t.ZodIssueCode.custom,message:`Multiple subscriptions with the exact same topic, uri, and filter. To resolve, remove or edit the duplicates ${r}`,path:["subscriptions"]}}}s();function Yn(e){let n=E(e,"webhooks");if(!n)return e;let{api_version:i}=n;return{api_version:i}}function Jn(e){let n={},i=E(e,"api_version");return n={...i?{webhooks:{api_version:i}}:{}},n}function Zn(e){if(e.length===0)return;let n=e.filter(r=>r.topics!==void 0).flatMap(({compliance_topics:r,topics:l,...d})=>Qn(l)?.map(p=>({topics:[p],...d}))??[]),i=e.filter(r=>r.topics===void 0||r.compliance_topics!==void 0).map(({compliance_topics:r,topics:l,...d})=>({compliance_topics:r,...d})),a=va(i,"compliance_topics"),o=pa(a);return[...Gn(o),...Gn(n)]}function Qn(e){return e?.sort((n,i)=>n.localeCompare(i))}function Gn(e){return e.sort((n,i)=>n.uri.localeCompare(i.uri))}function pa(e){return e.forEach(n=>n.compliance_topics=Qn(n.compliance_topics)),e}function ka(e,n){return e.find(i=>i.uri===n.uri&&Be(i.include_fields??[],n.include_fields??[])&&i.filter===n.filter)}function va(e,n){return e.reduce((i,a)=>{let o=ka(i,a);return o?n&&a?.[n]?.length?o[n]?.push(...a[n]):(a.topics&&(o.topics??=[],o.topics.push(...a.topics)),a.compliance_topics&&(o.compliance_topics??=[],o.compliance_topics.push(...a.compliance_topics))):i.push(a),i},[])}var fa=t.object({api_version:t.string({required_error:"String is required"}),privacy_compliance:t.object({customer_deletion_url:_.optional(),customer_data_request_url:_.optional(),shop_deletion_url:_.optional()}).optional(),subscriptions:t.array(Wn).optional().transform(e=>Zn(e??[]))}),Xn=F.extend({webhooks:fa.superRefine(Kn)});var ve="webhooks",Na={forward:Yn,reverse:e=>Jn(e)},ga=S({identifier:ve,schema:Xn,transformConfig:Na}),Kr=ga;s();var ei={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"AppVersionByTag"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"versionTag"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"versionByTag"},arguments:[{kind:"Argument",name:{kind:"Name",value:"tag"},value:{kind:"Variable",name:{kind:"Name",value:"versionTag"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"VersionInfo"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}},{kind:"FragmentDefinition",name:{kind:"Name",value:"ReleasedAppModule"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"AppModule"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"uuid"}},{kind:"Field",name:{kind:"Name",value:"userIdentifier"}},{kind:"Field",name:{kind:"Name",value:"handle"}},{kind:"Field",name:{kind:"Name",value:"config"}},{kind:"Field",name:{kind:"Name",value:"target"}},{kind:"Field",name:{kind:"Name",value:"specification"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"identifier"}},{kind:"Field",name:{kind:"Name",value:"externalIdentifier"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"experience"}},{kind:"Field",name:{kind:"Name",value:"managementExperience"}}]}}]}},{kind:"FragmentDefinition",name:{kind:"Name",value:"VersionInfo"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"Version"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"metadata"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"message"}},{kind:"Field",name:{kind:"Name",value:"versionTag"}}]}},{kind:"Field",name:{kind:"Name",value:"appModules"},selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"ReleasedAppModule"}}]}}]}}]};s();var ni={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"AppLogsSubscribe"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"shopIds"}},type:{kind:"NonNullType",type:{kind:"ListType",type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"Int"}}}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"apiKey"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"appLogsSubscribe"},arguments:[{kind:"Argument",name:{kind:"Name",value:"shopIds"},value:{kind:"Variable",name:{kind:"Name",value:"shopIds"}}},{kind:"Argument",name:{kind:"Name",value:"apiKey"},value:{kind:"Variable",name:{kind:"Name",value:"apiKey"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"jwtToken"}},{kind:"Field",name:{kind:"Name",value:"success"}},{kind:"Field",name:{kind:"Name",value:"errors"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};s();var fe="webhook_subscription",Sa=t.object({topic:t.string(),actions:t.array(t.string({invalid_type_error:"Value must be a string"})).optional(),api_version:t.string(),uri:t.preprocess(I,_,{required_error:"Missing value at"}),include_fields:t.array(t.string({invalid_type_error:"Value must be a string"})).optional(),filter:t.string({invalid_type_error:"Value must be a string"}).optional(),payload_query:t.string({invalid_type_error:"Value must be a string"}).trim().min(1).optional(),name:t.string({invalid_type_error:"Value must be a string"}).trim().min(1).max(50).optional()});function ha(e){let{api_version:n,topic:i,...a}=e;return{webhooks:{subscriptions:[{topics:[i],...a}]}}}var ya={forward:(e,n)=>{let i=e,a;return"application_url"in n&&(a=n?.application_url),{...i,uri:J(i.uri,a)}},reverse:ha},ba=S({identifier:fe,schema:Sa,transformConfig:ya,uidStrategy:"dynamic"}),ts=ba;s();s();s();function x(e={}){return{type:"token_refresh",handler:async()=>({token:await D([],{noPrompt:e.noPrompt})})}}s();var ii={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"FindOrganization"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"organizationId"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"OrganizationID"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"currentUserAccount"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"organization"},arguments:[{kind:"Argument",name:{kind:"Name",value:"id"},value:{kind:"Variable",name:{kind:"Name",value:"organizationId"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};s();var ai={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"ListOrganizations"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"currentUserAccount"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"uuid"}},{kind:"Field",name:{kind:"Name",value:"organizationsWithAccessToDestination"},arguments:[{kind:"Argument",name:{kind:"Name",value:"destination"},value:{kind:"EnumValue",value:"APPS_CLI"}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"nodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"status"}},{kind:"Field",name:{kind:"Name",value:"shopCount"}},{kind:"Field",name:{kind:"Name",value:"url"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};s();function R(e){let n=e.match(/\/(\d+)$/);return n?n[1]:void 0}function Z(e){return R(Buffer.from(e,"base64").toString("utf8"))}function L(e){return Buffer.from(e).toString("base64")}async function M(){return(await ti()).organizations}async function Fa(e){return ti(e)}async function Ne(e,n,i){let a=n??await D(),r=(await V({query:ii,token:a,variables:{organizationId:_a(e)},unauthorizedHandler:i??x(),cacheOptions:{cacheTTL:{hours:6},cacheExtraKey:Ue(a)}})).currentUserAccount?.organization;if(r)return{id:e,businessName:r.name}}function _a(e){let n=e.startsWith("gid://")?R(e):e;if(n===void 0||!/^\d+$/.test(n))throw new c(`Invalid organization ID: ${e}`);return L(`gid://organization/Organization/${n}`)}async function ti(e){let n=e??await D(),i=await V({query:ai,token:n,unauthorizedHandler:x()});return i.currentUserAccount?{organizations:i.currentUserAccount.organizationsWithAccessToDestination.nodes.map(o=>{let r=Z(o.id);if(r===void 0)throw new c(`Failed to decode organization ID from: ${o.id}`);return{id:r,businessName:o.name,status:o.status,shopCount:o.shopCount??null,url:o.url}}),currentUserResolved:!0}:{organizations:[],currentUserResolved:!1}}s();s();async function ge(e){if(e.length===1)return e[0];let i=new Set(e.map(o=>o.businessName)).size<e.length,a=await Qe({message:"Which organization do you want to use?",choices:e.map(o=>({label:i?`${o.businessName} (${o.id})`:o.businessName,value:o.id}))});return e.find(o=>o.id===a)}async function Da(e){let n=await M();if(n.length===0)throw new c("No organizations found.","Make sure you have access to a Shopify organization.");if(e){let i=n.find(a=>a.id===e);if(!i)throw new c(`Organization with ID ${e} not found.`,`Available organizations: ${n.map(a=>`${a.businessName} (${a.id})`).join(", ")}`);return i}return ge(n)}s();var Aa=["ACTIVE","LOCKED"];s();s();var Se={basic:"BASIC_APP_DEVELOPMENT",grow:"PROFESSIONAL_APP_DEVELOPMENT",advanced:"UNLIMITED_APP_DEVELOPMENT",plus:"SHOPIFY_PLUS_APP_DEVELOPMENT"},z=Object.keys(Se);s();s();var $=t.object({id:t.string(),name:t.string(),subdomain:t.string(),country:t.string().optional(),type:t.string().optional(),authScopes:t.array(t.string()).optional(),plan:t.string().optional(),organizationId:t.string(),organizationName:t.string()}),Q=t.object({id:t.string(),name:t.string()});var oi=$.pick({name:!0}).extend({domain:$.shape.subdomain,adminUrl:t.string().nullish(),plan:t.enum(z),featurePreview:t.string().optional(),country:$.shape.country,demoData:t.boolean()}),he=we({name:"CreateDevStoreResult",schema:t.object({store:oi,organization:Q}),definitions:{CreatedDevStore:oi,StoreOrganization:Q}});s();var ri={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"mutation",name:{kind:"Name",value:"CreateAppDevelopmentStore"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"shopName"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"priceLookupKey"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"prepopulateTestData"}},type:{kind:"NamedType",name:{kind:"Name",value:"Boolean"}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"developerPreviewHandle"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"country"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"createAppDevelopmentStore"},arguments:[{kind:"Argument",name:{kind:"Name",value:"shopName"},value:{kind:"Variable",name:{kind:"Name",value:"shopName"}}},{kind:"Argument",name:{kind:"Name",value:"priceLookupKey"},value:{kind:"Variable",name:{kind:"Name",value:"priceLookupKey"}}},{kind:"Argument",name:{kind:"Name",value:"prepopulateTestData"},value:{kind:"Variable",name:{kind:"Name",value:"prepopulateTestData"}}},{kind:"Argument",name:{kind:"Name",value:"developerPreviewHandle"},value:{kind:"Variable",name:{kind:"Name",value:"developerPreviewHandle"}}},{kind:"Argument",name:{kind:"Name",value:"country"},value:{kind:"Variable",name:{kind:"Name",value:"country"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"shopAdminUrl"}},{kind:"Field",name:{kind:"Name",value:"shopDomain"}},{kind:"Field",name:{kind:"Name",value:"userErrors"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"code"}},{kind:"Field",name:{kind:"Name",value:"field"}},{kind:"Field",name:{kind:"Name",value:"message"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};s();var si={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"PollStoreCreation"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"shopDomain"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"organization"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"id"}},{kind:"Field",name:{kind:"Name",value:"storeCreation"},arguments:[{kind:"Argument",name:{kind:"Name",value:"shopDomain"},value:{kind:"Variable",name:{kind:"Name",value:"shopDomain"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"status"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}}]};var Ta=2,Va=300*1e3;function wa(e){switch(e){case"CALLING_CORE":return"Initiating store creation";case"AWAITING_CORE_STORE_READY":return"Waiting for store to be ready";case"FINALIZING":return"Finalizing store setup";case"COMPLETE":return"Store creation complete!";case"FAILED":return"Store creation failed.";case"TIMED_OUT":return"Store creation timed out.";case"USER_ERROR":return"Store creation encountered a user error.";default:return`Store creation status: ${e}`}}async function Ia(e){let{organization:n,name:i,plan:a}=e,o=await D(),r=x(),d=(await A({query:ri,token:o,organizationId:n.id,variables:{shopName:i,priceLookupKey:Se[a],prepopulateTestData:e.withDemoData??!1,developerPreviewHandle:e.featurePreview,country:e.country},unauthorizedHandler:r})).createAppDevelopmentStore;if(!d)throw new c("Store creation failed: unexpected empty response.");let m=d.userErrors;if(m&&m.length>0){let u=m.map(v=>v.message).join(", ");throw new c(`Failed to create dev store: ${u}`)}let{shopDomain:p,shopAdminUrl:k}=d;if(!p)throw new c("Store creation succeeded but no shop domain was returned.");if(await Xe({title:P`Waiting for store to be ready`,task:async u=>{let v=Date.now();for(;;){if(Date.now()-v>Va)throw new c("Store creation timed out after 5 minutes.");let g=(await A({query:si,token:o,organizationId:n.id,variables:{shopDomain:p},unauthorizedHandler:r})).organization?.storeCreation?.status;if(!g)throw new c("Unable to determine store creation status.");if(g==="COMPLETE")return;if(g==="FAILED"||g==="TIMED_OUT"||g==="USER_ERROR")throw new c(`Store creation failed with status: ${g}`);u(P`${wa(g)}`),await nn(Ta)}},renderOptions:{stdout:process.stderr}}),e.json)on(he.encode({store:{name:i,domain:p,adminUrl:k,plan:a,...e.featurePreview?{featurePreview:e.featurePreview}:{},...e.country?{country:e.country}:{},demoData:e.withDemoData??!1},organization:{id:n.id,name:n.businessName}}));else if(e.summary!==!1){let u=[];H(u,"Domain",p),u.push(["Admin",k?{link:{label:k,url:k}}:"N/A"]),H(u,"Plan",a),H(u,"Feature preview",e.featurePreview),H(u,"Country",e.country),H(u,"Demo data",e.withDemoData?"enabled":"disabled"),Ye({headline:`Dev store "${i}" created successfully.`,customSections:[{body:{tabularData:u,firstColumnSubdued:!0}}]})}return p}function H(e,n,i){i!=null&&i!==""&&e.push([n,i])}s();var xa={basic:"Basic",grow:"Grow",advanced:"Advanced",plus:"Plus"};function Ra(){return en({message:"Name for the new dev store"})}function za(){return Je({message:"Which Shopify plan do you want to use?",choices:z.map(e=>({label:xa[e],value:e}))})}function Ca(){return Ze({message:"Populate the store with demo data?",confirmationMessage:"Yes, add demo data",cancellationMessage:"No, start with an empty store",defaultValue:!0})}s();s();var di=(e,n,i)=>{let a=new URL(e);return n&&a.searchParams.append("cursor",n),i?.status&&a.searchParams.append("status",i.status),i?.source&&a.searchParams.append("source",i.source),a.toString()};var li=B(K()),Ua=new li.default({minTime:150,maxConcurrent:10});async function Ea(e){let n="App Management",a=`https://${await y()}/app_management/unstable/graphql.json`;return{token:e,api:n,url:a,responseOptions:{onResponse:be}}}var ye=e=>Pe(e),mi=async(e,n,i)=>{let o=`https://${await y()}/app_management/unstable/organizations/${e}/app_logs/poll`;return di(o,n,i)},ui=async(e,n)=>`https://${await y()}/app_management/unstable/organizations/${encodeURIComponent(e)}/apps/${encodeURIComponent(n)}/channel_spec_export.json`;async function ci(e){let n=e.cacheOptions?.cacheExtraKey??"",i=e.cacheOptions?{...e.cacheOptions,cacheExtraKey:n}:void 0;return Ua.schedule(async()=>b({...await Ea(e.token),query:e.query,variables:e.variables,cacheOptions:i,preferredBehaviour:e.requestOptions?.requestMode,unauthorizedHandler:e.unauthorizedHandler}))}function be(e){if(!e.extensions)return;let n=[];for(let i of e.extensions.deprecations)i.supportedUntilDate&&n.push(new Date(i.supportedUntilDate));We(n)}s();var pi=B(K()),Pa=new pi.default({minTime:150,maxConcurrent:10});async function ki(e){let n="App Dev",i=U(e.shopFqdn),o=`https://${await Me(i)}/app_dev/unstable/graphql.json`,r=Le()==="local"?{"x-forwarded-host":i}:void 0;return Pa.schedule(()=>b({query:e.query,api:n,url:o,token:e.token,addedHeaders:r,variables:e.variables,unauthorizedHandler:e.unauthorizedHandler,preferredBehaviour:e.requestOptions?.requestMode}))}s();var vi=B(K()),qa=new vi.default({minTime:150,maxConcurrent:10});async function Oa(e,n,i){let a="Functions",r=`https://${await y()}/functions/unstable/organizations/${e}/${i}/graphql`;return{token:n,api:a,url:r,responseOptions:{onResponse:be}}}async function fi(e){return await qa.schedule(async()=>b({...await Oa(e.organizationId,e.token,e.appId),query:e.query,variables:e.variables,unauthorizedHandler:e.unauthorizedHandler}))}s();var Ni=B(K()),La=new Ni.default({minTime:150,maxConcurrent:10});async function gi(e){let n="Webhooks",a=`https://${await y()}/webhooks/unstable/organizations/${e.organizationId}/graphql.json`;return La.schedule(()=>b({query:e.query,api:n,url:a,token:e.token,variables:e.variables,unauthorizedHandler:e.unauthorizedHandler}))}import{randomUUID as Ma}from"crypto";var Si="https://cdn.shopify.com/static/cli/extensions/templates.json",$a=Ma(),ee=class e{static instance;static getInstance(n){return e.instance??=new e(n),e.instance}static resetInstance(){e.instance=void 0}clientName=ne.AppManagement;webUiName="Developer Dashboard";organizationSource=G.BusinessPlatform;bundleFormat="br";_session;constructor(n){this._session=n}async subscribeToAppLogs(n,i){return this.appManagementRequest({query:ni,variables:{shopIds:n.shopIds,apiKey:n.apiKey}})}async appLogs(n,i){let a=await Xa({organizationId:i,jwtToken:n.jwtToken,cursor:n.cursor,filters:n.filters});try{let o=await a.json();return a.ok?{app_logs:o.app_logs??[],cursor:o.cursor,status:a.status}:{errors:o.errors??[`Request failed with status ${a.status}`],status:a.status}}catch(o){return{errors:[`Failed to parse response: ${o}`],status:a.status}}}async channelSpecExport(n){let i=R(n.id)??n.id,a=await ui(n.organizationId,i),o=await ie(a,{method:"GET",headers:ye(await this.token())}),r;try{r=await o.json()}catch{r=void 0}let l=typeof r=="object"&&r!==null&&!Array.isArray(r)?r:void 0;return o.ok&&l?{ok:!0,status:o.status,body:l}:{ok:!1,status:o.status,body:l}}async session(){if(!this._session){if(an())throw new Error("AppManagementClient.session() should not be invoked dynamically in a unit test");let n=await te(),{appManagementToken:i,businessPlatformToken:a,userId:o}=n,r=await V({query:Ln,cacheOptions:{cacheTTL:{hours:6},cacheExtraKey:o},token:a,unauthorizedHandler:this.createUnauthorizedHandler("businessPlatform")});if(Ee()&&r.currentUserAccount){let l=r.currentUserAccount.organizations.nodes.map(d=>({name:d.name}));if(l.length>1)throw new T("Multiple organizations found for the CLI token");this._session={token:i,businessPlatformToken:a,accountInfo:{type:"ServiceAccount",orgName:l[0]?.name??"Unknown organization"},userId:o}}else r.currentUserAccount?this._session={token:i,businessPlatformToken:a,accountInfo:{type:"UserAccount",email:r.currentUserAccount.email},userId:o}:this._session={token:i,businessPlatformToken:a,accountInfo:{type:"UnknownAccount"},userId:o}}return this._session}async token(){return(await this.session()).token}async businessPlatformToken(){return(await this.session()).businessPlatformToken}async unsafeRefreshToken(){let n=await te({noPrompt:!0,forceRefresh:!0}),i=await this.session();return i.token=n.appManagementToken,i.businessPlatformToken=n.businessPlatformToken,i.token}async accountInfo(){return(await this.session()).accountInfo}async appFromIdentifiers(n){let{app:i}=await this.activeAppVersionRawResult(n);if(!i)return;let{name:a,appModules:o}=i.activeRelease.version,r=o.find(d=>d.specification.externalIdentifier==="app_home"),l=i.activeRoot.clientCredentials.secrets.map(d=>({secret:d.key}));return{id:i.id,title:a,apiKey:i.key,apiSecretKeys:l,organizationId:String(f(i.organizationId)),grantedScopes:i.activeRoot.grantedShopifyApprovalScopes,applicationUrl:r?.config?.app_url,embedded:r?.config?.embedded,flags:[],developerPlatformClient:this}}async organizations(){return(await M()).map(i=>({...i,source:this.organizationSource}))}async orgFromId(n){let i=await Ne(n,await this.businessPlatformToken(),this.createUnauthorizedHandler("businessPlatform"));if(i)return{...i,source:this.organizationSource}}async orgAndApps(n){let[i,{apps:a,hasMorePages:o}]=await Promise.all([this.orgFromId(n),this.appsForOrg(n)]);if(!i){let{accountInfo:r}=await this.session();throw new w(r,n)}return{organization:i,apps:a,hasMorePages:o}}async appsForOrg(n,i=""){let a=On,o={query:i.split(" ").filter(d=>d).map(d=>`title:${d}`).join(" "),organizationId:n},r=await this.appManagementRequest({query:a,variables:o});if(!r.appsConnection)throw new T("Server failed to retrieve apps");return{apps:r.appsConnection.edges.map(d=>{let m=d.node;return{id:m.id,apiKey:m.key,title:m.activeRelease.version.name,organizationId:n}}),hasMorePages:r.appsConnection.pageInfo.hasNextPage}}async specifications({organizationId:n}){let i=qn,a={organizationId:Fe(n)};return(await this.appManagementRequest({query:i,variables:a})).specifications.map(r=>({name:r.name,externalName:r.name,identifier:r.identifier,externalIdentifier:r.externalIdentifier,gated:!1,managementExperience:"cli",registrationLimit:r.uidStrategy.appModuleLimit,uidStrategy:Qa(r.uidStrategy.__typename),experience:_e(r.experience,r.identifier),validationSchema:r.validationSchema}))}async templateSpecifications({organizationId:n},i={}){let a,{templatesJsonPath:o}=un,r=process.env[o];if(r){if(!await ze(r))throw new c("There is no file at the path specified for template specifications");let u=await Re(r);a=JSON.parse(u)}else try{a=await(await Oe(Si)).json()}catch{throw new c(["Failed to fetch extension templates from",{link:{url:Si}},{char:"."},"This likely means a problem with your internet connection."])}let l=0,d=i.requestedTemplate?a.filter(u=>u.identifier===i.requestedTemplate):void 0,m=d&&d.length>0?d:a,p=(await Za(m,async u=>this.organizationBetaFlags(n,u),async u=>this.organizationExpFlags(n,u))).map(u=>({...u,sortPriority:l++})),k=[];for(let u of a)u.group&&!k.includes(u.group)&&k.push(u.group);return{templates:p,groupOrder:k}}async createApp(n,i){let o=(await this.apiVersions(n.id)).publicApiVersions.filter(u=>u!=="unstable").sort().at(-1)??"unstable",r=ja(i,n.id,o),l=Pn,d=await this.appManagementRequest({query:l,variables:r});if(!d.appCreate.app||d.appCreate.userErrors?.length>0){let u=d.appCreate.userErrors.map(v=>v.message).join(", ");throw new c(u)}let m=Di([]),p=d.appCreate.app,k=p.activeRoot.clientCredentials.secrets.map(u=>({secret:u.key}));return{...p,title:i.name,apiKey:p.key,apiSecretKeys:k,grantedScopes:i?.scopesArray??[],organizationId:n.id,newApp:!0,flags:m,developerPlatformClient:this}}async devStoresForOrg(n,i){let a=await this.businessPlatformOrganizationsRequest({query:Vn,organizationId:String(f(n)),variables:{searchTerm:i}}),o=a.organization;if(!o)throw new c("No organization found");let r=o.accessibleShops?.edges.map(d=>d.node)??[],l=_i(o.currentUser?.organizationPermissions??[]);return{stores:yi(r,l),hasMorePages:a.organization?.accessibleShops?.pageInfo.hasNextPage??!1}}async devStoreCapReached(n){return(await this.businessPlatformOrganizationsRequest({query:wn,organizationId:String(f(n)),variables:{}})).organization?.devStoreCapReached??!1}async appExtensionRegistrations(n,i){let a=i??await this.activeAppVersion(n),o=[],r=[],l=[];return a.appModuleVersions.forEach(d=>{let m={id:d.registrationId,uuid:d.registrationUuid,title:d.registrationTitle,type:d.type,activeVersion:d.config?{config:JSON.stringify(d.config),...d.target&&{context:d.target}}:void 0};d.specification?.experience==="configuration"?o.push(m):d.specification?.options?.managementExperience==="dashboard"?l.push(m):r.push(m)}),{app:{dashboardManagedExtensionRegistrations:l,configurationRegistrations:o,extensionRegistrations:r}}}async appVersions({id:n,organizationId:i,title:a}){let o=Un,r={appId:n},l=await this.appManagementRequest({query:o,variables:r});return l.app?{app:{id:l.app.id,organizationId:i,title:a,appVersions:{nodes:l.app.versions?.edges.map(d=>{let m=d.node;return{createdAt:m.createdAt,createdBy:{displayName:m.createdBy},versionTag:m.metadata.versionTag,status:m.id===l.app.activeRelease.version.id?"active":"inactive",versionId:m.id,message:m.metadata.message}})??[],pageInfo:{totalResults:l.app.versionsCount}}}}:{app:null}}async appInstallCount({id:n}){let i=En,a={appId:n};return(await this.appManagementRequest({query:i,variables:a})).app.installCount??0}async appVersionByTag({id:n,organizationId:i},a){let o=ei,r={versionTag:a},d=(await this.appManagementRequest({query:o,variables:r})).versionByTag;if(!d)throw new c(`Version not found for tag: ${a}`);return{id:parseInt(d.id,10),uuid:d.id,versionTag:d.metadata.versionTag,location:[await X({organizationId:i,id:n}),"versions",f(d.id)].join("/"),message:d.metadata.message??"",appModuleVersions:d.appModules.map(bi)}}async appVersionsDiff(n,{versionId:i}){let a={versionId:i},[o,r]=await Promise.all([this.activeAppVersionRawResult(n.apiKey),this.appManagementRequest({query:Cn,variables:a})]),l=o.app.activeRelease.version.appModules,d=r.version.appModules,{added:m,removed:p,updated:k}=Ja({currentModules:l,selectedVersionModules:d});function u(v){return{uuid:v.uuid,registrationTitle:v.handle,specification:{identifier:v.specification.identifier,experience:_e(v.specification.experience,v.specification.identifier),options:{managementExperience:"cli"}}}}return{app:{versionsDiff:{added:m.map(u),updated:k.map(u),removed:p.map(u)}}}}async activeAppVersion(n){let i=await this.activeAppVersionRawResult(n.apiKey);return{appModuleVersions:i.app.activeRelease.version.appModules.map(bi),...i.app.activeRelease}}async generateSignedUploadUrl({apiKey:n,organizationId:i}){let a={sourceExtension:"BR",organizationId:Fe(i)},o=await this.appManagementRequest({query:zn,variables:a,cacheOptions:{cacheTTL:{minutes:59},cacheExtraKey:`${n}-${$a}`}});return{assetUrl:o.appRequestSourceUploadUrl.sourceUploadUrl,userErrors:o.appRequestSourceUploadUrl.userErrors}}async deploy({appManifest:n,appId:i,organizationId:a,versionTag:o,message:r,commitReference:l,bundleUrl:d,skipPublish:m}){let u={appId:i,version:d?{sourceUrl:d}:{source:n},metadata:{versionTag:o,message:r,sourceControlUrl:l}},v=await this.appManagementRequest({query:Rn,variables:u,requestOptions:{requestMode:"slow-request"}}),{version:N}=v.appVersionCreate,g=v.appVersionCreate.userErrors.map(Fi)??[];if(!N)return{appDeploy:{userErrors:g}};let h={appDeploy:{appVersion:{uuid:N.id,id:parseInt(N.id,10),versionTag:N.metadata.versionTag,location:await Ya(a,i,N.id),appModuleVersions:N.appModules.map(Te=>({uuid:Te.uuid,registrationUuid:Te.uuid,validationErrors:[]})),message:N.metadata.message},userErrors:g}};if(m)return h;let Vi={appId:i,versionId:N.id},Ae=await this.appManagementRequest({query:ke,variables:Vi});return Ae.appReleaseCreate.userErrors&&(h.appDeploy.userErrors=(h.appDeploy.userErrors??[]).concat(Ae.appReleaseCreate.userErrors.map(Fi))),h}async release({app:{id:n,organizationId:i},version:{versionId:a}}){let o={appId:n,versionId:a},r=await this.appManagementRequest({query:ke,variables:o});return r.appReleaseCreate.release?{appRelease:{appVersion:{versionTag:r.appReleaseCreate.release.version.metadata.versionTag,message:r.appReleaseCreate.release.version.metadata.message,location:[await X({organizationId:i,id:n}),"versions",f(r.appReleaseCreate.release.version.id).toString()].join("/")}}}:{appRelease:{userErrors:r.appReleaseCreate.userErrors?.map(l=>({field:l.field,message:l.message,category:l.category,details:[],on:l.on}))??[]}}}async storeByDomain(n,i,a){let r=(await Promise.all(a.map(m=>this.businessPlatformOrganizationsRequest({query:Tn,organizationId:String(f(n)),variables:{domain:i,filters:et(m)}})))).map(m=>m.organization).filter(m=>m!=null);if(r.length===0)throw new c("No organization found");let l=r.flatMap(m=>{let p=m.accessibleShops?.edges.map(u=>u.node)??[],k=_i(m.currentUser?.organizationPermissions??[]);return yi(p,k)}),d=U(i);return l.find(m=>m.shopDomain===d)}async ensureUserAccessToStore(n,i){if(!i.provisionable)return;let o={input:{shopifyShopId:Ka(i.shopId)}},l=(await A({query:In,token:await this.businessPlatformToken(),organizationId:String(f(n)),variables:o,unauthorizedHandler:this.createUnauthorizedHandler()})).organizationUserProvisionShopAccess;if(!l.success){let d=l.userErrors?.map(m=>m.message).join(", ")??"";throw new T(`Failed to provision user access to store: ${d}`)}}async sendSampleWebhook(n,i){let a=$n,o={address:n.address,apiKey:n.api_key,apiVersion:n.api_version,deliveryMethod:n.delivery_method,sharedSecret:n.shared_secret,topic:n.topic},r=await this.webhooksRequest({organizationId:i,query:a,variables:o}),l={samplePayload:"{}",headers:"{}",success:!1,userErrors:[]},d=r.cliTesting;return d&&(l={samplePayload:d.samplePayload??"{}",headers:d.headers??"{}",success:d.success,userErrors:d.errors.map(m=>({message:m,fields:[]}))}),{sendSampleWebhook:l}}async apiVersions(n){return{publicApiVersions:(await this.webhooksRequest({organizationId:n,query:Hn,variables:{}})).publicApiVersions.map(a=>a.handle)}}async topics({api_version:n},i){let a=Mn,o={apiVersion:n};return{webhookTopics:(await this.webhooksRequest({organizationId:i,query:a,variables:o})).availableTopics??[]}}async updateURLs(n){return se("\u26A0\uFE0F updateURLs is not implemented"),{appUpdate:{userErrors:[]}}}async targetSchemaDefinition(n,i,a){try{let{app:o}=await this.activeAppVersionRawResult(i),r=String(f(o.id));return(await this.functionsRequest({organizationId:a,query:Bn,appId:r,variables:{handle:n.handle,version:n.version}}))?.target?.api?.schema?.definition??null}catch(o){throw new c(`Failed to fetch schema definition: ${o}`)}}async apiSchemaDefinition(n,i,a){try{let{app:o}=await this.activeAppVersionRawResult(i),r=String(f(o.id));return(await this.functionsRequest({organizationId:a,query:jn,appId:r,variables:n}))?.api?.schema?.definition??null}catch(o){throw new c(`Failed to fetch schema definition: ${o}`)}}toExtensionGraphQLType(n){return n.toLowerCase()}async appDeepLink({id:n,organizationId:i}){return X({id:n,organizationId:i})}async devSessionCreate({appId:n,assetsUrl:i,shopFqdn:a,websocketUrl:o,unsafeValidation:r}){let l=String(f(n));return this.appDevRequest({query:_n,shopFqdn:a,variables:{appId:l,assetsUrl:i??"",websocketUrl:o,unsafeValidation:r??!1},requestOptions:{requestMode:"slow-request"}})}async devSessionUpdate({appId:n,assetsUrl:i,shopFqdn:a,manifest:o,inheritedModuleUids:r,unsafeValidation:l}){let m={appId:String(f(n)),assetsUrl:i,manifest:JSON.stringify(o),inheritedModuleUids:r,unsafeValidation:l??!1};return this.appDevRequest({query:Dn,shopFqdn:a,variables:m})}async devSessionDelete({appId:n,shopFqdn:i}){let a=String(f(n));return this.appDevRequest({query:An,shopFqdn:i,variables:{appId:a}})}async getCreateDevStoreLink(n){let i=`https://${await ae()}/dashboard/${n.id}/stores`;return[`Looks like you don't have any dev stores associated with ${n.businessName}'s Dev Dashboard.`,{link:{url:i,label:"Create a store in Dev Dashboard"}}]}async activeAppVersionRawResult(n){return this.appManagementRequest({query:xn,variables:{apiKey:n}})}async organizationBetaFlags(n,i){let a={organizationId:hi(n)},o=await Ke({query:dn(i),token:await this.businessPlatformToken(),organizationId:n,variables:a,unauthorizedHandler:this.createUnauthorizedHandler()}),r={};return i.forEach(l=>{r[l]=!!o.organization[`flag_${l}`]}),r}async organizationExpFlags(n,i){let a={organizationId:hi(n),flagHandles:i},o=await A({query:ln,token:await this.businessPlatformToken(),organizationId:n,variables:a,unauthorizedHandler:this.createUnauthorizedHandler()}),r={},l=o.organization?.enabledFlags??[];return i.forEach((d,m)=>{r[d]=!!l[m]}),r}async appManagementRequest(n){return ci({...n,token:await this.token(),unauthorizedHandler:this.createUnauthorizedHandler()})}async appDevRequest(n){return ki({...n,token:await this.token(),unauthorizedHandler:this.createUnauthorizedHandler()})}async businessPlatformRequest(n){return V({...n,token:await this.businessPlatformToken(),unauthorizedHandler:this.createUnauthorizedHandler("businessPlatform")})}async businessPlatformOrganizationsRequest(n){return A({...n,token:await this.businessPlatformToken(),unauthorizedHandler:this.createUnauthorizedHandler("businessPlatform")})}async functionsRequest(n){return fi({...n,token:await this.token(),unauthorizedHandler:this.createUnauthorizedHandler()})}async webhooksRequest(n){return gi({...n,token:await this.token(),unauthorizedHandler:this.createUnauthorizedHandler()})}createUnauthorizedHandler(n="default"){return Ai(this,n)}},Ha="https://shopify.dev/apps/default-app-home",Ba="https://shopify.dev/apps/default-app-home/api/auth";function ja(e,n,i){let{isLaunchable:a,scopesArray:o,name:r}=e;return{initialVersion:{source:{source:{name:r,modules:[{type:ue,config:{app_url:a?"https://example.com":Ha,embedded:!0}},{type:ce,config:{name:r}},{type:ve,config:{api_version:i}},{type:pe,config:{redirect_url_allowlist:[a?"https://example.com/api/auth":Ba],...o&&{scopes:o.map(p=>p.trim()).join(",")}}}]}}.source},organizationId:Fe(n)}}function Wa(e){let n=e.startsWith("gid://")?f(e):Number(e);if(Number.isNaN(n))throw new Error(`Invalid organization ID: ${e}`);return`gid://organization/Organization/${n}`}function hi(e){return L(Wa(e))}function Fe(e){return`gid://shopify/Organization/${e.startsWith("gid://")?f(e):Number(e)}`}function Ka(e){return L(`gid://organization/ShopifyShop/${e}`)}function Ga(e){let n=Z(e);if(n===void 0)throw new Error(`Invalid encoded GID: ${e}`);return n}function f(e){if(e.startsWith("gid://")){let n=R(e);if(n===void 0)throw new Error(`Invalid GID: ${e}`);return Number(n)}return Number(e)}async function X({id:e,organizationId:n}){let i=f(n).toString();return`https://${await ae()}/dashboard/${i}/apps/${f(e)}`}async function Ya(e,n,i){return`${await X({organizationId:e,id:n})}/versions/${f(i)}`}function Ja({currentModules:e,selectedVersionModules:n}){let i=e.map(m=>m.userIdentifier),a=n.map(m=>m.userIdentifier),o=n.filter(m=>!i.includes(m.userIdentifier)),r=e.filter(m=>!a.includes(m.userIdentifier)),l=r.map(m=>m.userIdentifier),d=e.filter(m=>!l.includes(m.userIdentifier));return{added:o,removed:r,updated:d}}async function Za(e,n,i,a=Ve){let o=C(e.flatMap(m=>m.organizationBetaFlags??[])),r=C(e.flatMap(m=>m.organizationExpFlags??[])),[l,d]=await Promise.all([o.length>0?n(o):Promise.resolve({}),r.length>0?i(r):Promise.resolve({})]);return e.filter(m=>{let p=!m.organizationBetaFlags||m.organizationBetaFlags.every(h=>l[h]),k=!m.organizationExpFlags||m.organizationExpFlags.every(h=>d[h]),u=!m.minimumCliVersion||oe(a,`>=${m.minimumCliVersion}`),v=!m.deprecatedFromCliVersion||oe(a,`<${m.deprecatedFromCliVersion}`),N=u&&v,g=Ge(a)&&m.deprecatedFromCliVersion===void 0;return p&&k&&(N||g)})}function _e(e,n){if(n===fe)return"configuration";switch(e){case"extension":case"configuration":case"deprecated":return e;default:return se(`Unknown specification experience value "${e}", defaulting to "extension"`),"extension"}}function Qa(e){switch(e){case"UidStrategiesDynamic":return"dynamic";case"UidStrategiesStatic":return"single";case"UidStrategiesClientProvided":return"uuid";default:return"uuid"}}function yi(e,n){return e.map(i=>{let{externalId:a,primaryDomain:o,name:r,url:l,storeType:d}=i,m=l??o;if(!m)throw new T("The selected store does not have a valid URL");return{shopId:a?Ga(a):void 0,link:o,shopDomain:U(m),shopName:r,transferDisabled:!0,convertableToPartnerTest:!0,provisionable:n,storeType:d}})}function bi(e){return{registrationId:e.userIdentifier===e.uuid?"":e.userIdentifier,registrationUuid:e.uuid,registrationTitle:e.handle,type:e.specification.externalIdentifier,config:e.config,target:e.target??"",specification:{...e.specification,identifier:e.specification.identifier,options:{managementExperience:e.specification.managementExperience},experience:_e(e.specification.experience,e.specification.externalIdentifier)}}}var Xa=async({organizationId:e,jwtToken:n,cursor:i,filters:a})=>{let o=await mi(e,i,a),r=ye(n);return ie(o,{method:"GET",headers:r})};function Fi(e){let n=[],i=e.on[0]?.user_identifier;return i&&n.push({extension_id:i}),{...e,details:n}}function et(e){return[{field:"STORE_TYPE",operator:"EQUALS",value:e.toLowerCase()},{field:"STORE_STATUS",operator:"EQUALS",value:"ACTIVE"}]}function _i(e){return e.includes("ondemand_access_to_stores")}var ne;(function(e){e.AppManagement="app-management",e.Partners="partners"})(ne||(ne={}));function mn(){return ee.getInstance()}var Ti;Ti||(Ti={});var nt={};function Di(e=[]){let n=[],i=e.map(a=>nt[a]);return n.filter(a=>!i.includes(a))}var De=new WeakMap;function Ai(e,n="default"){return{type:"token_refresh",handler:async()=>{let i=De.get(e);if(i)await i;else try{i=e.unsafeRefreshToken(),De.set(e,i),await i}finally{De.delete(e)}let a=await e.session();return{token:n==="businessPlatform"?a.businessPlatformToken:a.token}}}}export{x as a,Z as b,Fa as c,Ne as d,ge as e,Da as f,Aa as g,z as h,$ as i,Q as j,he as k,Ia as l,Ra as m,za as n,Ca as o,un as p,Ii as q,yt as r,bt as s,cn as t,Ft as u,_t as v,it as w,rn as x,at as y,wi as z,tt as A,pn as B,kn as C,xi as D,It as E,xt as F,Li as G,Y as H,Rt as I,F as J,zt as K,I as L,J as M,Wi as N,Sn as O,Zi as P,hn as Q,yn as R,S,so as T,fe as U,ts as V,O as W,Wn as X,Zn as Y,va as Z,Xn as _,G as $,ue as aa,vo as ba,ce as ca,yo as da,sa as ea,da as fa,pe as ga,wo as ha,ve as ia,Kr as ja,Wa as ka,ne as la,mn as ma,Ai as na,le as oa,w as pa,ft as qa,Nt as ra,gt as sa};
|
package/dist/chunk-YBSX53QP.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{b as o,c as l,f as m}from"./chunk-UNHT4ZFP.js";import{A as a,S as h}from"./chunk-47IQIIFX.js";import{Xa as f,ra as c}from"./chunk-UWI76E2L.js";import{c as s}from"./chunk-6IDEDOXW.js";import{g as u}from"./chunk-VKWPEFWQ.js";u();async function d(n){if(n.features.includes("function")&&n.isJavaScript){let e=await m(n);return o(e.functionRunner)}return o()}function p(n){return n.configuration.build?.path?s(n.directory,n.configuration.build.path):n.outputPath}async function y(n,e){try{if(!await f(e))return;let i=c(e);if(!WebAssembly.validate(i))return;let t=new WebAssembly.Module(i);if(WebAssembly.Module.customSections(t,"name").length>0)return;if(n.isJavaScript){a({headline:"The profile won't contain names for your function.",body:"JavaScript functions built with Javy don't include a WebAssembly function name section, regardless of the wasm_opt setting. Function names will appear as <unknown> in the profile."});return}a({headline:"The profile won't contain names for your function.",body:["The built WebAssembly module doesn't contain a function name section. The default wasm-opt step removes this section, and the function compiler can also omit it. To preserve function names, set ",{userInput:"wasm_opt = false"}," under ",{userInput:"[extensions.build]"}," in shopify.extension.toml, configure the compiler to emit function names, and rebuild the function."]})}catch{}}async function W(n){let e=n.functionExtension,i=await d(e);await l(i);let t=[];n.inputPath&&t.push("--input",n.inputPath),n.export&&t.push("--export",n.export),n.json&&t.push("--json"),n.profile&&t.push("--profile"),n.schemaPath&&n.queryPath&&(t.push("--schema-path",n.schemaPath),t.push("--query-path",n.queryPath));let r=p(e);return n.profile&&await y(e,r),h(i.path,["-f",r,...t],{cwd:n.functionExtension.directory,stdin:n.stdin,stdout:n.stdout??"inherit",stderr:n.stderr??"inherit",input:n.input})}export{W as a};
|
package/dist/chunk-YHCP326A.js
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import{b as N,c as S,d as A}from"./chunk-YYA5VGDW.js";import{a as T}from"./chunk-GN66BRYF.js";import{a as g}from"./chunk-PO5T44H3.js";import{Ia as x,b as P,c as y}from"./chunk-UNHT4ZFP.js";import{b as d,c as b}from"./chunk-NU5WLZ6Y.js";import{y as f}from"./chunk-47IQIIFX.js";import{Cb as h,Eb as l,Ib as m}from"./chunk-UWI76E2L.js";import{c as p}from"./chunk-6IDEDOXW.js";import{g as s}from"./chunk-VKWPEFWQ.js";s();s();function C(n,t){let o={};return n.targeting?.forEach(e=>{e.target&&(o[e.target]={...e.input_query&&{inputQueryPath:`${t}/${e.input_query}`},...e.export&&{export:e.export}})}),o}function I(n,t,o,e,r,i){return JSON.stringify({handle:t.handle,name:n.name,apiVersion:t.api_version,targeting:o,schemaPath:i,wasmPath:r,functionRunnerPath:e},null,2)}function w(n,t){return{title:`CONFIGURATION
|
|
2
|
-
`,body:{tabularData:[["Handle",n.handle??"N/A"],["Name",t??"N/A"],["API Version",n.api_version??"N/A"]],firstColumnSubdued:!0}}}function j(n){if(Object.keys(n).length===0)return null;let t=[];return Object.entries(n).forEach(([o,e])=>{t.push([l`${h.cyan(o)}`.value,""]),e.inputQueryPath&&t.push([{subdued:" Input Query Path"},{filePath:e.inputQueryPath}]),e.export&&t.push([{subdued:" Export"},e.export])}),{title:`
|
|
3
|
-
TARGETING
|
|
4
|
-
`,body:{tabularData:t}}}function O(n,t){return{title:`
|
|
5
|
-
BUILD
|
|
6
|
-
`,body:{tabularData:[["Schema Path",{filePath:t??"N/A"}],["Wasm Path",{filePath:n}]],firstColumnSubdued:!0}}}function D(n){return{title:`
|
|
7
|
-
FUNCTION RUNNER
|
|
8
|
-
`,body:{tabularData:[["Path",{filePath:n}]],firstColumnSubdued:!0}}}function v(n,t,o,e,r,i){let a=[w(t,n.name)],u=j(o);return u&&a.push(u),a.push(O(r,i),D(e)),a}function R(n,t){let{format:o,functionRunnerPath:e,schemaPath:r}=t,i=n.configuration,a=C(i,n.directory),u=p(n.directory,i.build?.path??n.outputRelativePath);return o==="json"?I(n,i,a,e,u,r):v(n,i,a,e,u,r)}var c=class n extends T{static summary="Print basic information about your function.";static descriptionWithMarkdown=`The information returned includes the following:
|
|
9
|
-
|
|
10
|
-
- The function handle
|
|
11
|
-
- The function name
|
|
12
|
-
- The function API version
|
|
13
|
-
- The targeting configuration
|
|
14
|
-
- The schema path
|
|
15
|
-
- The WASM path
|
|
16
|
-
- The function runner path`;static description=this.descriptionForHelp();static flags={...d,...g,...N,...b};async run(){let{flags:t}=await this.parse(n),{app:o}=await x({directory:t.path,userProvidedConfigName:t.config}),e=await S(o,t.path),r=P();await y(r);let i=await A(e,t.path,t["client-id"],t.reset,t.config),a=R(e,{format:t.json?"json":"text",functionRunnerPath:r.path,schemaPath:i});return t.json?m(a):f({customSections:a}),{app:o}}};export{c as a};
|
package/dist/chunk-YHESTFMZ.js
DELETED
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import{b as A}from"./chunk-NU5WLZ6Y.js";import{b as w}from"./chunk-4ZNBEMRT.js";import{j as g}from"./chunk-3V4VL3SD.js";import{i as a}from"./chunk-Q37WAD6F.js";import{Aa as m,Ib as y,Kb as v,ya as u}from"./chunk-UWI76E2L.js";import{b as L}from"./chunk-I3J63RFV.js";import{e as h,h as f}from"./chunk-6IDEDOXW.js";import{e as x,g as s}from"./chunk-VKWPEFWQ.js";s();s();var U="text/markdown",b="X-Shopify-Surface",R="cli",F=["shopify.dev"];async function S(t,e,p){let c;try{c=new URL(t)}catch{throw new a(`Invalid URL: ${t}`)}let{hostname:d}=c;if(!F.some(o=>d===o||d.endsWith(`.${o}`)))throw new a(`Only documents from the following hosts can be fetched: ${F.join(", ")}.`);let i=await g(t,{headers:{Accept:U,[b]:R,...p?{"Accept-Language":p}:{}}});if(!i.ok)throw new a(`Failed to fetch ${t}: ${i.status} ${i.statusText}`);let l=await i.text();if(e){let o=h(e);await m(f(o)),await u(o,l),v(`Saved ${t} to ${o}`);return}y(l)}var n=x(L(),1),r=class t extends w{static description="Download a complete document from shopify.dev. Every page on shopify.dev has a Markdown version, and that is what this tool returns. Use this to pull an entire document verbatim \u2014 for example, a set of instructions an agent follows like a centrally-served skill. Pass `--language` for the language of the app you are building so code examples match your stack. For finding the relevant pieces of content across shopify.dev instead, use `doc search`.";static examples=[`# fetch the Markdown version of a Shopify.dev page
|
|
2
|
-
shopify doc fetch --url https://shopify.dev/docs/api/shopify-cli`,`# filter code examples to the language of the app you are building
|
|
3
|
-
shopify doc fetch --url https://shopify.dev/docs/api/shopify-cli --language ruby`,`# save the document to a file instead of printing it
|
|
4
|
-
shopify doc fetch --url https://shopify.dev/docs/api/shopify-cli --output docs/shopify-cli.md`];static flags={...A,url:n.Flags.string({description:"The shopify.dev URL to fetch.",env:"SHOPIFY_FLAG_URL",required:!0}),language:n.Flags.string({description:"Filter code examples in the returned Markdown to this language. Supply the language of the app you are building so examples match your stack. Optional \u2014 if omitted, or if shopify.dev does not recognize the language for a given page, the document includes examples in every language.",env:"SHOPIFY_FLAG_LANGUAGE",options:["javascript","typescript","python","ruby","php","rust","curl","liquid","graphql","html"]}),output:n.Flags.string({description:"Write the document to this file path instead of printing it to stdout.",env:"SHOPIFY_FLAG_OUTPUT"})};async run(){let{flags:e}=await this.parse(t);await S(e.url,e.output,e.language)}};export{r as a};
|