Skip to content

Normalize subscription migration list JSON - #8586

Merged
gonzaloriestra merged 4 commits into
donald/subscription-migrations-cancel-json-schemafrom
gonzalo/json-subscription-migrations-list
Oct 9, 2026
Merged

gonzaloriestra merged 4 commits into
donald/subscription-migrations-cancel-json-schemafrom
gonzalo/json-subscription-migrations-list

Conversation

@gonzaloriestra

@gonzaloriestra gonzaloriestra commented Sep 18, 2026 •

Copy link
Copy Markdown
Contributor

WHY are these changes introduced?

Subscription migration JSON must follow the shared CLI conventions and expose a discoverable contract.

WHAT is this pull request doing?

Rename shopId to shopGid, validate an explicit subscription projection, and normalize instants to whole-second UTC while preserving calendar dates. Remove schemaVersion; result contracts follow CLI release versions. Update the schema, tests, and generated help together. These existing JSON contract changes include a major changeset.

How to manually test your changes?

shopify app subscription-migrations list --json
shopify app subscription-migrations list --json-schema

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 and includes a major changeset

@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 Sep 18, 2026
@gonzaloriestra
gonzaloriestra added this pull request to stack #8590 September 18, 2026 12:23
@gonzaloriestra
gonzaloriestra force-pushed the gonzalo/json-subscription-migrations-list branch from 6257876 to f1fc0cd Compare September 21, 2026 12:17
@gonzaloriestra
gonzaloriestra force-pushed the gonzalo/json-subscription-migrations-list branch 2 times, most recently from a7c90b8 to fd56011 Compare September 24, 2026 10:32
@gonzaloriestra
gonzaloriestra force-pushed the gonzalo/json-subscription-migrations-list branch from fd56011 to 6e3553b Compare September 24, 2026 10:41
@gonzaloriestra
gonzaloriestra marked this pull request as ready for review September 24, 2026 10:46
@gonzaloriestra
gonzaloriestra requested review from a team as code owners September 24, 2026 10:46
@gonzaloriestra gonzaloriestra changed the title Add JSON Schema for subscription migration listing Normalize subscription migration list JSON Oct 6, 2026
@gonzaloriestra
gonzaloriestra marked this pull request as draft October 6, 2026 12:00
@gonzaloriestra
gonzaloriestra force-pushed the gonzalo/json-subscription-migrations-list branch from 6e3553b to eb6e01a Compare October 6, 2026 12:05
@github-actions github-actions Bot added Area: @shopify/cli @shopify/cli package issues and removed no-changelog This PR doesn't include a changeset entry. Is an internal only change not relevant to end users. labels Oct 6, 2026
@gonzaloriestra
gonzaloriestra force-pushed the gonzalo/json-subscription-migrations-list branch from eb6e01a to 9eb9f32 Compare October 6, 2026 12:26
@gonzaloriestra
gonzaloriestra marked this pull request as ready for review October 8, 2026 08:57
Comment thread packages/app/src/cli/services/subscription-migrations/types.ts
@gonzaloriestra
gonzaloriestra force-pushed the gonzalo/json-subscription-migrations-list branch from 9eb9f32 to d6232fd Compare October 8, 2026 11:40
@gonzaloriestra
gonzaloriestra force-pushed the gonzalo/json-subscription-migrations-list branch from d6232fd to c5b0d76 Compare October 9, 2026 07:45
@gonzaloriestra
gonzaloriestra force-pushed the gonzalo/json-subscription-migrations-list branch from c5b0d76 to c988c4f Compare October 9, 2026 08:12
@github-actions

github-actions Bot commented Oct 9, 2026

Copy link
Copy Markdown
Contributor

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

packages/cli-kit/dist/public/node/error/serialization.d.ts
import type { JsonError } from './types.js';
/**
 * Projects an error into the shared JSON error contract, retaining only allowlisted fields.
 *
 * @param source - Error to project.
 * @returns The error classification, message, and available recovery information.
 */
export declare function errorToJson(source: unknown): JsonError;

Existing type declarations

packages/cli-kit/dist/private/node/json-error.d.ts
@@ -1,16 +1,3 @@
-interface FatalErrorLike {
-    type?: number;
-    message?: unknown;
-    formattedMessage?: unknown;
-    tryMessage?: unknown;
-    nextSteps?: unknown;
-    customSections?: unknown;
-    stack?: unknown;
-    command?: unknown;
-    args?: unknown;
-    details?: unknown;
-    code?: unknown;
-}
 /**
  * Writes the public JSON representation of a fatal error to stdout.
  *
@@ -19,5 +6,4 @@ interface FatalErrorLike {
  *
  * @param error - Fatal error to serialize.
  */
-export declare function renderFatalErrorAsJson(error: FatalErrorLike): void;
-export {};
\ No newline at end of file
+export declare function renderFatalErrorAsJson(error: unknown): void;
\ No newline at end of file

@github-actions

github-actions Bot commented Oct 9, 2026

Copy link
Copy Markdown
Contributor

⚠️ Potential Breaking Changes Detected

This PR contains changes that may break the existing contract.

@shopify/dev_experience — this PR contains breaking changes that require coordination for the next major release.

📦 Major Version Changesets

The following changesets request a major version bump:

Changeset Package
normalize-migration-subscription-list-json.md "@shopify/cli": major
normalize-subscription-migration-json.md "@shopify/cli": major

@gonzaloriestra
gonzaloriestra added this pull request to the merge queue Oct 9, 2026
Merged via the queue into main with commit 8f616bb Oct 9, 2026
44 of 81 checks passed
@gonzaloriestra
gonzaloriestra deleted the gonzalo/json-subscription-migrations-list branch October 9, 2026 09:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Area: @shopify/cli @shopify/cli package issues

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants