Skip to content

Allow theme profile with Theme Access tokens#7633

Closed
gonzaloriestra wants to merge 1 commit into
cli-interactivity/app-dev-flagsfrom
cli-interactivity/theme-profile-token
Closed

Allow theme profile with Theme Access tokens#7633
gonzaloriestra wants to merge 1 commit into
cli-interactivity/app-dev-flagsfrom
cli-interactivity/theme-profile-token

Conversation

@gonzaloriestra
Copy link
Copy Markdown
Contributor

@gonzaloriestra gonzaloriestra commented May 25, 2026

WHY are these changes introduced?

The interactivity audit found that theme profile required browser OAuth even when a Theme Access token was available for non-interactive runs.

WHAT is this pull request doing?

  • Allows theme profile to use Theme Access tokens.
  • Keeps the existing rejection for raw Admin API tokens with clearer guidance.

How to test your changes?

  • pnpm vitest run packages/theme/src/cli/services/profile.test.ts

Checklist

  • I've considered possible cross-platform impacts (Mac, Linux, Windows)
  • I've considered possible documentation changes
  • I've considered analytics changes to measure impact
  • The change is user-facing, so I've added a changelog entry with pnpm changeset add

Copy link
Copy Markdown
Contributor Author

gonzaloriestra commented May 25, 2026

@github-actions github-actions Bot added the no-changelog This PR doesn't include a changeset entry. Is an internal only change not relevant to end users. label May 25, 2026
@gonzaloriestra gonzaloriestra force-pushed the cli-interactivity/app-dev-flags branch from 970e05e to ea50335 Compare May 26, 2026 14:53
@gonzaloriestra gonzaloriestra force-pushed the cli-interactivity/theme-profile-token branch 2 times, most recently from b73773b to 8f6ca1c Compare May 26, 2026 15:22
@gonzaloriestra gonzaloriestra force-pushed the cli-interactivity/app-dev-flags branch from ea50335 to 3948ce1 Compare May 26, 2026 15:22
@gonzaloriestra gonzaloriestra force-pushed the cli-interactivity/theme-profile-token branch from 8f6ca1c to fee06e6 Compare June 1, 2026 11:43
@gonzaloriestra gonzaloriestra force-pushed the cli-interactivity/app-dev-flags branch from 3948ce1 to 2014ea3 Compare June 1, 2026 11:43
@gonzaloriestra gonzaloriestra force-pushed the cli-interactivity/theme-profile-token branch from fee06e6 to ad55535 Compare June 1, 2026 11:58
@gonzaloriestra gonzaloriestra force-pushed the cli-interactivity/app-dev-flags branch from 2014ea3 to 59259d8 Compare June 1, 2026 11:58
@gonzaloriestra gonzaloriestra force-pushed the cli-interactivity/theme-profile-token branch from ad55535 to 8d70823 Compare June 1, 2026 12:20
@gonzaloriestra gonzaloriestra force-pushed the cli-interactivity/app-dev-flags branch from 59259d8 to 1f26176 Compare June 1, 2026 12:20
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jun 1, 2026

Differences in type declarations

We detected differences in the type declarations generated by Typescript for this branch compared to the baseline ('main' branch). Please, review them to ensure they are backward-compatible. Here are some important things to keep in mind:

  • Some seemingly private modules might be re-exported through public modules.
  • If the branch is behind main you might see odd diffs, rebase main into this branch.

New type declarations

We found no new type declarations in this PR

Existing type declarations

packages/cli-kit/dist/public/common/version.d.ts
@@ -1 +1 @@
-export declare const CLI_KIT_VERSION = "4.1.0";
\ No newline at end of file
+export declare const CLI_KIT_VERSION = "4.0.0";
\ No newline at end of file
packages/cli-kit/dist/private/node/constants.d.ts
@@ -7,6 +7,7 @@ export declare const environmentVariables: {
     enableCliRedirect: string;
     env: string;
     firstPartyDev: string;
+    hostedApps: string;
     noAnalytics: string;
     optOutInstrumentation: string;
     appAutomationToken: string;
packages/cli-kit/dist/public/node/context/local.d.ts
@@ -42,6 +42,13 @@ export declare function isShopify(env?: NodeJS.ProcessEnv): Promise<boolean>;
  * @returns True if the SHOPIFY_UNIT_TEST environment variable is truthy.
  */
 export declare function isUnitTest(env?: NodeJS.ProcessEnv): boolean;
+/**
+ * Returns true if the CLI is running in hosted apps mode.
+ *
+ * @param env - The environment variables from the environment of the current process.
+ * @returns True if the HOSTED_APPS environment variable is truthy.
+ */
+export declare function isHostedAppsMode(env?: NodeJS.ProcessEnv): boolean;
 /**
  * Returns true if reporting analytics is enabled.
  *

@gonzaloriestra gonzaloriestra force-pushed the cli-interactivity/app-dev-flags branch from 1f26176 to b0606fb Compare June 1, 2026 12:45
@gonzaloriestra gonzaloriestra force-pushed the cli-interactivity/theme-profile-token branch from 8d70823 to 1202d52 Compare June 1, 2026 12:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

no-changelog This PR doesn't include a changeset entry. Is an internal only change not relevant to end users.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant