From 9121d600c8f8e8c9f45174933ce952a5fe720494 Mon Sep 17 00:00:00 2001 From: Eric Lee Date: Thu, 22 Jan 2026 17:24:41 -0800 Subject: [PATCH 1/6] additional ui feedback --- .../execute-bulk-operation.test.ts | 16 +++++++-- .../bulk-operations/execute-bulk-operation.ts | 27 ++++++++++---- .../app/src/cli/services/execute-operation.ts | 36 ++++++------------- 3 files changed, 45 insertions(+), 34 deletions(-) diff --git a/packages/app/src/cli/services/bulk-operations/execute-bulk-operation.test.ts b/packages/app/src/cli/services/bulk-operations/execute-bulk-operation.test.ts index 1d603b537da..815d934fd34 100644 --- a/packages/app/src/cli/services/bulk-operations/execute-bulk-operation.test.ts +++ b/packages/app/src/cli/services/bulk-operations/execute-bulk-operation.test.ts @@ -4,7 +4,7 @@ import {runBulkOperationMutation} from './run-mutation.js' import {watchBulkOperation, shortBulkOperationPoll} from './watch-bulk-operation.js' import {downloadBulkOperationResults} from './download-bulk-operation-results.js' import {BULK_OPERATIONS_MIN_API_VERSION} from './constants.js' -import {resolveApiVersion} from '../graphql/common.js' +import {resolveApiVersion, createAdminSessionAsApp} from '../graphql/common.js' import {BulkOperationRunQueryMutation} from '../../api/graphql/bulk-operations/generated/bulk-operation-run-query.js' import {BulkOperationRunMutationMutation} from '../../api/graphql/bulk-operations/generated/bulk-operation-run-mutation.js' import {OrganizationApp, OrganizationSource, OrganizationStore} from '../../models/organization.js' @@ -23,11 +23,22 @@ vi.mock('../graphql/common.js', async () => { const actual = await vi.importActual('../graphql/common.js') return { ...actual, + createAdminSessionAsApp: vi.fn(), resolveApiVersion: vi.fn(), validateMutationStore: vi.fn(), } }) -vi.mock('@shopify/cli-kit/node/ui') +vi.mock('@shopify/cli-kit/node/ui', async () => { + const actual = await vi.importActual('@shopify/cli-kit/node/ui') + return { + ...actual, + renderSingleTask: vi.fn(async ({task}) => task()), + renderSuccess: vi.fn(), + renderWarning: vi.fn(), + renderError: vi.fn(), + renderInfo: vi.fn(), + } +}) vi.mock('@shopify/cli-kit/node/fs') vi.mock('@shopify/cli-kit/node/session', async () => { const actual = await vi.importActual('@shopify/cli-kit/node/session') @@ -77,6 +88,7 @@ describe('executeBulkOperation', () => { } beforeEach(() => { + vi.mocked(createAdminSessionAsApp).mockResolvedValue(mockAdminSession) vi.mocked(ensureAuthenticatedAdminAsApp).mockResolvedValue(mockAdminSession) vi.mocked(shortBulkOperationPoll).mockResolvedValue(createdBulkOperation) vi.mocked(resolveApiVersion).mockResolvedValue(BULK_OPERATIONS_MIN_API_VERSION) diff --git a/packages/app/src/cli/services/bulk-operations/execute-bulk-operation.ts b/packages/app/src/cli/services/bulk-operations/execute-bulk-operation.ts index 50887563a14..bc7d9747e80 100644 --- a/packages/app/src/cli/services/bulk-operations/execute-bulk-operation.ts +++ b/packages/app/src/cli/services/bulk-operations/execute-bulk-operation.ts @@ -13,7 +13,14 @@ import { isMutation, } from '../graphql/common.js' import {OrganizationApp, Organization, OrganizationStore} from '../../models/organization.js' -import {renderSuccess, renderInfo, renderError, renderWarning, TokenItem} from '@shopify/cli-kit/node/ui' +import { + renderSuccess, + renderInfo, + renderError, + renderWarning, + renderSingleTask, + TokenItem, +} from '@shopify/cli-kit/node/ui' import {outputContent, outputToken, outputResult} from '@shopify/cli-kit/node/output' import {AbortError, BugError} from '@shopify/cli-kit/node/error' import {AbortController} from '@shopify/cli-kit/node/abort' @@ -61,12 +68,18 @@ export async function executeBulkOperation(input: ExecuteBulkOperationInput): Pr version: userSpecifiedVersion, } = input - const adminSession = await createAdminSessionAsApp(remoteApp, store.shopDomain) - - const version = await resolveApiVersion({ - adminSession, - userSpecifiedVersion, - minimumDefaultVersion: BULK_OPERATIONS_MIN_API_VERSION, + const {adminSession, version} = await renderSingleTask({ + title: outputContent`Authenticating`, + task: async () => { + const adminSession = await createAdminSessionAsApp(remoteApp, store.shopDomain) + const version = await resolveApiVersion({ + adminSession, + userSpecifiedVersion, + minimumDefaultVersion: BULK_OPERATIONS_MIN_API_VERSION, + }) + return {adminSession, version} + }, + renderOptions: {stdout: process.stderr}, }) const variablesJsonl = await parseVariablesToJsonl(variables, variableFile) diff --git a/packages/app/src/cli/services/execute-operation.ts b/packages/app/src/cli/services/execute-operation.ts index 01bd946a4d4..00807b16071 100644 --- a/packages/app/src/cli/services/execute-operation.ts +++ b/packages/app/src/cli/services/execute-operation.ts @@ -2,11 +2,11 @@ import { createAdminSessionAsApp, validateSingleOperation, resolveApiVersion, - formatOperationInfo, validateMutationStore, } from './graphql/common.js' import {OrganizationApp, Organization, OrganizationStore} from '../models/organization.js' -import {renderSuccess, renderError, renderInfo, renderSingleTask} from '@shopify/cli-kit/node/ui' +import {renderSuccess, renderError, renderSingleTask} from '@shopify/cli-kit/node/ui' +import {AdminSession} from '@shopify/cli-kit/node/session' import {outputContent, outputToken, outputResult} from '@shopify/cli-kit/node/output' import {AbortError} from '@shopify/cli-kit/node/error' import {adminRequestDoc} from '@shopify/cli-kit/node/api/admin' @@ -62,30 +62,16 @@ async function parseVariables( } export async function executeOperation(input: ExecuteOperationInput): Promise { - const { - organization, - remoteApp, - store, - query, - variables, - variableFile, - version: userSpecifiedVersion, - outputFile, - } = input + const {remoteApp, store, query, variables, variableFile, version: userSpecifiedVersion, outputFile} = input - const adminSession = await createAdminSessionAsApp(remoteApp, store.shopDomain) - - const version = await resolveApiVersion({adminSession, userSpecifiedVersion}) - - renderInfo({ - headline: 'Executing GraphQL operation.', - body: [ - { - list: { - items: formatOperationInfo({organization, remoteApp, storeFqdn: store.shopDomain, version}), - }, - }, - ], + const {adminSession, version} = await renderSingleTask({ + title: outputContent`Authenticating`, + task: async (): Promise<{adminSession: AdminSession; version: string}> => { + const adminSession = await createAdminSessionAsApp(remoteApp, store.shopDomain) + const version = await resolveApiVersion({adminSession, userSpecifiedVersion}) + return {adminSession, version} + }, + renderOptions: {stdout: process.stderr}, }) const parsedVariables = await parseVariables(variables, variableFile) From 9670213c8dd3cce37d930515b912126f51a1f0fd Mon Sep 17 00:00:00 2001 From: Jordan Verasamy Date: Mon, 2 Feb 2026 13:33:12 -0800 Subject: [PATCH 2/6] remove `reverse: true` in `listBulkOperations` --- .../bulk-operations/generated/list-bulk-operations.ts | 11 ----------- .../queries/list-bulk-operations.graphql | 4 ++-- .../services/bulk-operations/bulk-operation-status.ts | 1 - 3 files changed, 2 insertions(+), 14 deletions(-) diff --git a/packages/app/src/cli/api/graphql/bulk-operations/generated/list-bulk-operations.ts b/packages/app/src/cli/api/graphql/bulk-operations/generated/list-bulk-operations.ts index 416720528e6..d4cd1cef7a1 100644 --- a/packages/app/src/cli/api/graphql/bulk-operations/generated/list-bulk-operations.ts +++ b/packages/app/src/cli/api/graphql/bulk-operations/generated/list-bulk-operations.ts @@ -7,7 +7,6 @@ export type ListBulkOperationsQueryVariables = Types.Exact<{ query?: Types.InputMaybe first: Types.Scalars['Int']['input'] sortKey: Types.BulkOperationsSortKeys - reverse: Types.Scalars['Boolean']['input'] }> export type ListBulkOperationsQuery = { @@ -48,11 +47,6 @@ export const ListBulkOperations = { variable: {kind: 'Variable', name: {kind: 'Name', value: 'sortKey'}}, type: {kind: 'NonNullType', type: {kind: 'NamedType', name: {kind: 'Name', value: 'BulkOperationsSortKeys'}}}, }, - { - kind: 'VariableDefinition', - variable: {kind: 'Variable', name: {kind: 'Name', value: 'reverse'}}, - type: {kind: 'NonNullType', type: {kind: 'NamedType', name: {kind: 'Name', value: 'Boolean'}}}, - }, ], selectionSet: { kind: 'SelectionSet', @@ -76,11 +70,6 @@ export const ListBulkOperations = { name: {kind: 'Name', value: 'sortKey'}, value: {kind: 'Variable', name: {kind: 'Name', value: 'sortKey'}}, }, - { - kind: 'Argument', - name: {kind: 'Name', value: 'reverse'}, - value: {kind: 'Variable', name: {kind: 'Name', value: 'reverse'}}, - }, ], selectionSet: { kind: 'SelectionSet', diff --git a/packages/app/src/cli/api/graphql/bulk-operations/queries/list-bulk-operations.graphql b/packages/app/src/cli/api/graphql/bulk-operations/queries/list-bulk-operations.graphql index 0342db3e319..fc56c75c846 100644 --- a/packages/app/src/cli/api/graphql/bulk-operations/queries/list-bulk-operations.graphql +++ b/packages/app/src/cli/api/graphql/bulk-operations/queries/list-bulk-operations.graphql @@ -1,5 +1,5 @@ -query ListBulkOperations($query: String, $first: Int!, $sortKey: BulkOperationsSortKeys!, $reverse: Boolean!) { - bulkOperations(first: $first, query: $query, sortKey: $sortKey, reverse: $reverse) { +query ListBulkOperations($query: String, $first: Int!, $sortKey: BulkOperationsSortKeys!) { + bulkOperations(first: $first, query: $query, sortKey: $sortKey) { nodes { id status diff --git a/packages/app/src/cli/services/bulk-operations/bulk-operation-status.ts b/packages/app/src/cli/services/bulk-operations/bulk-operation-status.ts index 54b8c8aa3f0..6162909f37f 100644 --- a/packages/app/src/cli/services/bulk-operations/bulk-operation-status.ts +++ b/packages/app/src/cli/services/bulk-operations/bulk-operation-status.ts @@ -121,7 +121,6 @@ export async function listBulkOperations(options: ListBulkOperationsOptions): Pr query: `created_at:>=${sevenDaysAgo}`, first: 100, sortKey: 'CREATED_AT', - reverse: true, }, version: await resolveApiVersion({ adminSession, From a3ff57c443905f0f71ed4c90138fde818ffe0ca0 Mon Sep 17 00:00:00 2001 From: Jordan Verasamy Date: Tue, 9 Dec 2025 13:39:49 -0800 Subject: [PATCH 3/6] Release the `app execute` and `app bulk execute` commands --- .../commands/app-bulk-execute.doc.ts | 38 ++ .../commands/app-bulk-status.doc.ts | 38 ++ docs-shopify.dev/commands/app-execute.doc.ts | 36 ++ .../examples/app-bulk-execute.example.sh | 1 + .../examples/app-bulk-status.example.sh | 1 + .../commands/examples/app-execute.example.sh | 1 + .../interfaces/app-bulk-execute.interface.ts | 86 ++++ .../interfaces/app-bulk-status.interface.ts | 50 ++ .../interfaces/app-execute.interface.ts | 80 ++++ .../generated/generated_docs_data.json | 429 ++++++++++++++++++ .../app/src/cli/commands/app/bulk/execute.ts | 9 +- .../app/src/cli/commands/app/bulk/status.ts | 11 +- packages/app/src/cli/commands/app/execute.ts | 6 +- packages/cli/README.md | 116 +++++ packages/cli/oclif.manifest.json | 14 +- packages/features/snapshots/commands.txt | 4 + 16 files changed, 904 insertions(+), 16 deletions(-) create mode 100644 docs-shopify.dev/commands/app-bulk-execute.doc.ts create mode 100644 docs-shopify.dev/commands/app-bulk-status.doc.ts create mode 100644 docs-shopify.dev/commands/app-execute.doc.ts create mode 100644 docs-shopify.dev/commands/examples/app-bulk-execute.example.sh create mode 100644 docs-shopify.dev/commands/examples/app-bulk-status.example.sh create mode 100644 docs-shopify.dev/commands/examples/app-execute.example.sh create mode 100644 docs-shopify.dev/commands/interfaces/app-bulk-execute.interface.ts create mode 100644 docs-shopify.dev/commands/interfaces/app-bulk-status.interface.ts create mode 100644 docs-shopify.dev/commands/interfaces/app-execute.interface.ts diff --git a/docs-shopify.dev/commands/app-bulk-execute.doc.ts b/docs-shopify.dev/commands/app-bulk-execute.doc.ts new file mode 100644 index 00000000000..0e87c9afa31 --- /dev/null +++ b/docs-shopify.dev/commands/app-bulk-execute.doc.ts @@ -0,0 +1,38 @@ +// This is an autogenerated file. Don't edit this file manually. +import {ReferenceEntityTemplateSchema} from '@shopify/generate-docs' + +const data: ReferenceEntityTemplateSchema = { + name: 'app bulk execute', + description: `Executes an Admin API GraphQL query or mutation on the specified store, as a bulk operation. Mutations are only allowed on dev stores. + + Bulk operations allow you to process large amounts of data asynchronously. Learn more about [bulk query operations](/docs/api/usage/bulk-operations/queries) and [bulk mutation operations](/docs/api/usage/bulk-operations/imports). + + Use [\`bulk status\`](/docs/api/shopify-cli/app/app-bulk-status) to check the status of your bulk operations.`, + overviewPreviewDescription: `Execute bulk operations.`, + type: 'command', + isVisualComponent: false, + defaultExample: { + codeblock: { + tabs: [ + { + title: 'app bulk execute', + code: './examples/app-bulk-execute.example.sh', + language: 'bash', + }, + ], + title: 'app bulk execute', + }, + }, + definitions: [ + { + title: 'Flags', + description: 'The following flags are available for the `app bulk execute` command:', + type: 'appbulkexecute', + }, + ], + category: 'app', + related: [ + ], +} + +export default data \ No newline at end of file diff --git a/docs-shopify.dev/commands/app-bulk-status.doc.ts b/docs-shopify.dev/commands/app-bulk-status.doc.ts new file mode 100644 index 00000000000..410da037721 --- /dev/null +++ b/docs-shopify.dev/commands/app-bulk-status.doc.ts @@ -0,0 +1,38 @@ +// This is an autogenerated file. Don't edit this file manually. +import {ReferenceEntityTemplateSchema} from '@shopify/generate-docs' + +const data: ReferenceEntityTemplateSchema = { + name: 'app bulk status', + description: `Check the status of a specific bulk operation by ID, or list all bulk operations belonging to this app on this store in the last 7 days. + + Bulk operations allow you to process large amounts of data asynchronously. Learn more about [bulk query operations](/docs/api/usage/bulk-operations/queries) and [bulk mutation operations](/docs/api/usage/bulk-operations/imports). + + Use [\`bulk execute\`](/docs/api/shopify-cli/app/app-bulk-execute) to start a new bulk operation.`, + overviewPreviewDescription: `Check the status of bulk operations.`, + type: 'command', + isVisualComponent: false, + defaultExample: { + codeblock: { + tabs: [ + { + title: 'app bulk status', + code: './examples/app-bulk-status.example.sh', + language: 'bash', + }, + ], + title: 'app bulk status', + }, + }, + definitions: [ + { + title: 'Flags', + description: 'The following flags are available for the `app bulk status` command:', + type: 'appbulkstatus', + }, + ], + category: 'app', + related: [ + ], +} + +export default data \ No newline at end of file diff --git a/docs-shopify.dev/commands/app-execute.doc.ts b/docs-shopify.dev/commands/app-execute.doc.ts new file mode 100644 index 00000000000..78b2334de54 --- /dev/null +++ b/docs-shopify.dev/commands/app-execute.doc.ts @@ -0,0 +1,36 @@ +// This is an autogenerated file. Don't edit this file manually. +import {ReferenceEntityTemplateSchema} from '@shopify/generate-docs' + +const data: ReferenceEntityTemplateSchema = { + name: 'app execute', + description: `Executes an Admin API GraphQL query or mutation on the specified store. Mutations are only allowed on dev stores. + + For operations that process large amounts of data, use [\`bulk execute\`](/docs/api/shopify-cli/app/app-bulk-execute) instead.`, + overviewPreviewDescription: `Execute GraphQL queries and mutations.`, + type: 'command', + isVisualComponent: false, + defaultExample: { + codeblock: { + tabs: [ + { + title: 'app execute', + code: './examples/app-execute.example.sh', + language: 'bash', + }, + ], + title: 'app execute', + }, + }, + definitions: [ + { + title: 'Flags', + description: 'The following flags are available for the `app execute` command:', + type: 'appexecute', + }, + ], + category: 'app', + related: [ + ], +} + +export default data \ No newline at end of file diff --git a/docs-shopify.dev/commands/examples/app-bulk-execute.example.sh b/docs-shopify.dev/commands/examples/app-bulk-execute.example.sh new file mode 100644 index 00000000000..96bdb985b20 --- /dev/null +++ b/docs-shopify.dev/commands/examples/app-bulk-execute.example.sh @@ -0,0 +1 @@ +shopify app bulk execute [flags] \ No newline at end of file diff --git a/docs-shopify.dev/commands/examples/app-bulk-status.example.sh b/docs-shopify.dev/commands/examples/app-bulk-status.example.sh new file mode 100644 index 00000000000..94caa5e7782 --- /dev/null +++ b/docs-shopify.dev/commands/examples/app-bulk-status.example.sh @@ -0,0 +1 @@ +shopify app bulk status [flags] \ No newline at end of file diff --git a/docs-shopify.dev/commands/examples/app-execute.example.sh b/docs-shopify.dev/commands/examples/app-execute.example.sh new file mode 100644 index 00000000000..5139767a4c7 --- /dev/null +++ b/docs-shopify.dev/commands/examples/app-execute.example.sh @@ -0,0 +1 @@ +shopify app execute [flags] \ No newline at end of file diff --git a/docs-shopify.dev/commands/interfaces/app-bulk-execute.interface.ts b/docs-shopify.dev/commands/interfaces/app-bulk-execute.interface.ts new file mode 100644 index 00000000000..5836d541822 --- /dev/null +++ b/docs-shopify.dev/commands/interfaces/app-bulk-execute.interface.ts @@ -0,0 +1,86 @@ +// This is an autogenerated file. Don't edit this file manually. +export interface appbulkexecute { + /** + * The Client ID of your app. + * @environment SHOPIFY_FLAG_CLIENT_ID + */ + '--client-id '?: string + + /** + * The name of the app configuration. + * @environment SHOPIFY_FLAG_APP_CONFIG + */ + '-c, --config '?: string + + /** + * Disable color output. + * @environment SHOPIFY_FLAG_NO_COLOR + */ + '--no-color'?: '' + + /** + * The file path where results should be written if --watch is specified. If not specified, results will be written to STDOUT. + * @environment SHOPIFY_FLAG_OUTPUT_FILE + */ + '--output-file '?: string + + /** + * The path to your app directory. + * @environment SHOPIFY_FLAG_PATH + */ + '--path '?: string + + /** + * The GraphQL query or mutation to run as a bulk operation. + * @environment SHOPIFY_FLAG_QUERY + */ + '-q, --query '?: string + + /** + * Path to a file containing the GraphQL query or mutation. Can't be used with --query. + * @environment SHOPIFY_FLAG_QUERY_FILE + */ + '--query-file '?: string + + /** + * Reset all your settings. + * @environment SHOPIFY_FLAG_RESET + */ + '--reset'?: '' + + /** + * The store domain. Must be an existing dev store. + * @environment SHOPIFY_FLAG_STORE + */ + '-s, --store '?: string + + /** + * Path to a file containing GraphQL variables in JSONL format (one JSON object per line). Can't be used with --variables. + * @environment SHOPIFY_FLAG_VARIABLE_FILE + */ + '--variable-file '?: string + + /** + * The values for any GraphQL variables in your mutation, in JSON format. Can be specified multiple times. + * @environment SHOPIFY_FLAG_VARIABLES + */ + '-v, --variables '?: string + + /** + * Increase the verbosity of the output. + * @environment SHOPIFY_FLAG_VERBOSE + */ + '--verbose'?: '' + + /** + * The API version to use for the bulk operation. If not specified, uses the latest stable version. + * @environment SHOPIFY_FLAG_VERSION + */ + '--version '?: string + + /** + * Wait for bulk operation results before exiting. Defaults to false. + * @environment SHOPIFY_FLAG_WATCH + */ + '--watch'?: '' +} diff --git a/docs-shopify.dev/commands/interfaces/app-bulk-status.interface.ts b/docs-shopify.dev/commands/interfaces/app-bulk-status.interface.ts new file mode 100644 index 00000000000..1afe74ecc80 --- /dev/null +++ b/docs-shopify.dev/commands/interfaces/app-bulk-status.interface.ts @@ -0,0 +1,50 @@ +// This is an autogenerated file. Don't edit this file manually. +export interface appbulkstatus { + /** + * The Client ID of your app. + * @environment SHOPIFY_FLAG_CLIENT_ID + */ + '--client-id '?: string + + /** + * The name of the app configuration. + * @environment SHOPIFY_FLAG_APP_CONFIG + */ + '-c, --config '?: string + + /** + * The bulk operation ID (numeric ID or full GID). If not provided, lists all bulk operations belonging to this app on this store in the last 7 days. + * @environment SHOPIFY_FLAG_ID + */ + '--id '?: string + + /** + * Disable color output. + * @environment SHOPIFY_FLAG_NO_COLOR + */ + '--no-color'?: '' + + /** + * The path to your app directory. + * @environment SHOPIFY_FLAG_PATH + */ + '--path '?: string + + /** + * Reset all your settings. + * @environment SHOPIFY_FLAG_RESET + */ + '--reset'?: '' + + /** + * The store domain. Must be an existing dev store. + * @environment SHOPIFY_FLAG_STORE + */ + '-s, --store '?: string + + /** + * Increase the verbosity of the output. + * @environment SHOPIFY_FLAG_VERBOSE + */ + '--verbose'?: '' +} diff --git a/docs-shopify.dev/commands/interfaces/app-execute.interface.ts b/docs-shopify.dev/commands/interfaces/app-execute.interface.ts new file mode 100644 index 00000000000..ef1e8cb1afd --- /dev/null +++ b/docs-shopify.dev/commands/interfaces/app-execute.interface.ts @@ -0,0 +1,80 @@ +// This is an autogenerated file. Don't edit this file manually. +export interface appexecute { + /** + * The Client ID of your app. + * @environment SHOPIFY_FLAG_CLIENT_ID + */ + '--client-id '?: string + + /** + * The name of the app configuration. + * @environment SHOPIFY_FLAG_APP_CONFIG + */ + '-c, --config '?: string + + /** + * Disable color output. + * @environment SHOPIFY_FLAG_NO_COLOR + */ + '--no-color'?: '' + + /** + * The file name where results should be written, instead of STDOUT. + * @environment SHOPIFY_FLAG_OUTPUT_FILE + */ + '--output-file '?: string + + /** + * The path to your app directory. + * @environment SHOPIFY_FLAG_PATH + */ + '--path '?: string + + /** + * The GraphQL query or mutation, as a string. + * @environment SHOPIFY_FLAG_QUERY + */ + '-q, --query '?: string + + /** + * Path to a file containing the GraphQL query or mutation. Can't be used with --query. + * @environment SHOPIFY_FLAG_QUERY_FILE + */ + '--query-file '?: string + + /** + * Reset all your settings. + * @environment SHOPIFY_FLAG_RESET + */ + '--reset'?: '' + + /** + * The myshopify.com domain of the store to execute against. The app must be installed on the store. If not specified, you will be prompted to select a store. + * @environment SHOPIFY_FLAG_STORE + */ + '-s, --store '?: string + + /** + * Path to a file containing GraphQL variables in JSON format. Can't be used with --variables. + * @environment SHOPIFY_FLAG_VARIABLE_FILE + */ + '--variable-file '?: string + + /** + * The values for any GraphQL variables in your query or mutation, in JSON format. + * @environment SHOPIFY_FLAG_VARIABLES + */ + '-v, --variables '?: string + + /** + * Increase the verbosity of the output. + * @environment SHOPIFY_FLAG_VERBOSE + */ + '--verbose'?: '' + + /** + * The API version to use for the query or mutation. Defaults to the latest stable version. + * @environment SHOPIFY_FLAG_VERSION + */ + '--version '?: string +} diff --git a/docs-shopify.dev/generated/generated_docs_data.json b/docs-shopify.dev/generated/generated_docs_data.json index eb04908faa7..d1eff7f7415 100644 --- a/docs-shopify.dev/generated/generated_docs_data.json +++ b/docs-shopify.dev/generated/generated_docs_data.json @@ -100,6 +100,280 @@ "category": "app", "related": [] }, + { + "name": "app bulk execute", + "description": "Executes an Admin API GraphQL query or mutation on the specified store, as a bulk operation. Mutations are only allowed on dev stores.\n\n Bulk operations allow you to process large amounts of data asynchronously. Learn more about [bulk query operations](/docs/api/usage/bulk-operations/queries) and [bulk mutation operations](/docs/api/usage/bulk-operations/imports).\n\n Use [`bulk status`](/docs/api/shopify-cli/app/app-bulk-status) to check the status of your bulk operations.", + "overviewPreviewDescription": "Execute bulk operations.", + "type": "command", + "isVisualComponent": false, + "defaultExample": { + "codeblock": { + "tabs": [ + { + "title": "app bulk execute", + "code": "shopify app bulk execute [flags]", + "language": "bash" + } + ], + "title": "app bulk execute" + } + }, + "definitions": [ + { + "title": "Flags", + "description": "The following flags are available for the `app bulk execute` command:", + "type": "appbulkexecute", + "typeDefinitions": { + "appbulkexecute": { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-execute.interface.ts", + "name": "appbulkexecute", + "description": "", + "members": [ + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--client-id ", + "value": "string", + "description": "The Client ID of your app.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_CLIENT_ID" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--no-color", + "value": "\"\"", + "description": "Disable color output.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_NO_COLOR" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--output-file ", + "value": "string", + "description": "The file path where results should be written if --watch is specified. If not specified, results will be written to STDOUT.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_OUTPUT_FILE" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--path ", + "value": "string", + "description": "The path to your app directory.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_PATH" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--query-file ", + "value": "string", + "description": "Path to a file containing the GraphQL query or mutation. Can't be used with --query.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_QUERY_FILE" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--reset", + "value": "\"\"", + "description": "Reset all your settings.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_RESET" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--variable-file ", + "value": "string", + "description": "Path to a file containing GraphQL variables in JSONL format (one JSON object per line). Can't be used with --variables.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_VARIABLE_FILE" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--verbose", + "value": "\"\"", + "description": "Increase the verbosity of the output.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_VERBOSE" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--version ", + "value": "string", + "description": "The API version to use for the bulk operation. If not specified, uses the latest stable version.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_VERSION" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--watch", + "value": "\"\"", + "description": "Wait for bulk operation results before exiting. Defaults to false.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_WATCH" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "-c, --config ", + "value": "string", + "description": "The name of the app configuration.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_APP_CONFIG" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "-q, --query ", + "value": "string", + "description": "The GraphQL query or mutation to run as a bulk operation.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_QUERY" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "-s, --store ", + "value": "string", + "description": "The store domain. Must be an existing dev store.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_STORE" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "-v, --variables ", + "value": "string", + "description": "The values for any GraphQL variables in your mutation, in JSON format. Can be specified multiple times.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_VARIABLES" + } + ], + "value": "export interface appbulkexecute {\n /**\n * The Client ID of your app.\n * @environment SHOPIFY_FLAG_CLIENT_ID\n */\n '--client-id '?: string\n\n /**\n * The name of the app configuration.\n * @environment SHOPIFY_FLAG_APP_CONFIG\n */\n '-c, --config '?: string\n\n /**\n * Disable color output.\n * @environment SHOPIFY_FLAG_NO_COLOR\n */\n '--no-color'?: ''\n\n /**\n * The file path where results should be written if --watch is specified. If not specified, results will be written to STDOUT.\n * @environment SHOPIFY_FLAG_OUTPUT_FILE\n */\n '--output-file '?: string\n\n /**\n * The path to your app directory.\n * @environment SHOPIFY_FLAG_PATH\n */\n '--path '?: string\n\n /**\n * The GraphQL query or mutation to run as a bulk operation.\n * @environment SHOPIFY_FLAG_QUERY\n */\n '-q, --query '?: string\n\n /**\n * Path to a file containing the GraphQL query or mutation. Can't be used with --query.\n * @environment SHOPIFY_FLAG_QUERY_FILE\n */\n '--query-file '?: string\n\n /**\n * Reset all your settings.\n * @environment SHOPIFY_FLAG_RESET\n */\n '--reset'?: ''\n\n /**\n * The store domain. Must be an existing dev store.\n * @environment SHOPIFY_FLAG_STORE\n */\n '-s, --store '?: string\n\n /**\n * Path to a file containing GraphQL variables in JSONL format (one JSON object per line). Can't be used with --variables.\n * @environment SHOPIFY_FLAG_VARIABLE_FILE\n */\n '--variable-file '?: string\n\n /**\n * The values for any GraphQL variables in your mutation, in JSON format. Can be specified multiple times.\n * @environment SHOPIFY_FLAG_VARIABLES\n */\n '-v, --variables '?: string\n\n /**\n * Increase the verbosity of the output.\n * @environment SHOPIFY_FLAG_VERBOSE\n */\n '--verbose'?: ''\n\n /**\n * The API version to use for the bulk operation. If not specified, uses the latest stable version.\n * @environment SHOPIFY_FLAG_VERSION\n */\n '--version '?: string\n\n /**\n * Wait for bulk operation results before exiting. Defaults to false.\n * @environment SHOPIFY_FLAG_WATCH\n */\n '--watch'?: ''\n}" + } + } + } + ], + "category": "app", + "related": [] + }, + { + "name": "app bulk status", + "description": "Check the status of a specific bulk operation by ID, or list all bulk operations belonging to this app on this store in the last 7 days.\n\n Bulk operations allow you to process large amounts of data asynchronously. Learn more about [bulk query operations](/docs/api/usage/bulk-operations/queries) and [bulk mutation operations](/docs/api/usage/bulk-operations/imports).\n\n Use [`bulk execute`](/docs/api/shopify-cli/app/app-bulk-execute) to start a new bulk operation.", + "overviewPreviewDescription": "Check the status of bulk operations.", + "type": "command", + "isVisualComponent": false, + "defaultExample": { + "codeblock": { + "tabs": [ + { + "title": "app bulk status", + "code": "shopify app bulk status [flags]", + "language": "bash" + } + ], + "title": "app bulk status" + } + }, + "definitions": [ + { + "title": "Flags", + "description": "The following flags are available for the `app bulk status` command:", + "type": "appbulkstatus", + "typeDefinitions": { + "appbulkstatus": { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-status.interface.ts", + "name": "appbulkstatus", + "description": "", + "members": [ + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-status.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--client-id ", + "value": "string", + "description": "The Client ID of your app.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_CLIENT_ID" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-status.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--id ", + "value": "string", + "description": "The bulk operation ID (numeric ID or full GID). If not provided, lists all bulk operations belonging to this app on this store in the last 7 days.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_ID" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-status.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--no-color", + "value": "\"\"", + "description": "Disable color output.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_NO_COLOR" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-status.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--path ", + "value": "string", + "description": "The path to your app directory.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_PATH" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-status.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--reset", + "value": "\"\"", + "description": "Reset all your settings.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_RESET" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-status.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--verbose", + "value": "\"\"", + "description": "Increase the verbosity of the output.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_VERBOSE" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-status.interface.ts", + "syntaxKind": "PropertySignature", + "name": "-c, --config ", + "value": "string", + "description": "The name of the app configuration.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_APP_CONFIG" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-status.interface.ts", + "syntaxKind": "PropertySignature", + "name": "-s, --store ", + "value": "string", + "description": "The store domain. Must be an existing dev store.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_STORE" + } + ], + "value": "export interface appbulkstatus {\n /**\n * The Client ID of your app.\n * @environment SHOPIFY_FLAG_CLIENT_ID\n */\n '--client-id '?: string\n\n /**\n * The name of the app configuration.\n * @environment SHOPIFY_FLAG_APP_CONFIG\n */\n '-c, --config '?: string\n\n /**\n * The bulk operation ID (numeric ID or full GID). If not provided, lists all bulk operations belonging to this app on this store in the last 7 days.\n * @environment SHOPIFY_FLAG_ID\n */\n '--id '?: string\n\n /**\n * Disable color output.\n * @environment SHOPIFY_FLAG_NO_COLOR\n */\n '--no-color'?: ''\n\n /**\n * The path to your app directory.\n * @environment SHOPIFY_FLAG_PATH\n */\n '--path '?: string\n\n /**\n * Reset all your settings.\n * @environment SHOPIFY_FLAG_RESET\n */\n '--reset'?: ''\n\n /**\n * The store domain. Must be an existing dev store.\n * @environment SHOPIFY_FLAG_STORE\n */\n '-s, --store '?: string\n\n /**\n * Increase the verbosity of the output.\n * @environment SHOPIFY_FLAG_VERBOSE\n */\n '--verbose'?: ''\n}" + } + } + } + ], + "category": "app", + "related": [] + }, { "name": "app config link", "description": "Pulls app configuration from the Developer Dashboard and creates or overwrites a configuration file. You can create a new app with this command to start with a default configuration file.\n\n For more information on the format of the created TOML configuration file, refer to the [App configuration](/docs/apps/tools/cli/configuration) page.\n ", @@ -1016,6 +1290,161 @@ "category": "app", "related": [] }, + { + "name": "app execute", + "description": "Executes an Admin API GraphQL query or mutation on the specified store. Mutations are only allowed on dev stores.\n\n For operations that process large amounts of data, use [`bulk execute`](/docs/api/shopify-cli/app/app-bulk-execute) instead.", + "overviewPreviewDescription": "Execute GraphQL queries and mutations.", + "type": "command", + "isVisualComponent": false, + "defaultExample": { + "codeblock": { + "tabs": [ + { + "title": "app execute", + "code": "shopify app execute [flags]", + "language": "bash" + } + ], + "title": "app execute" + } + }, + "definitions": [ + { + "title": "Flags", + "description": "The following flags are available for the `app execute` command:", + "type": "appexecute", + "typeDefinitions": { + "appexecute": { + "filePath": "docs-shopify.dev/commands/interfaces/app-execute.interface.ts", + "name": "appexecute", + "description": "", + "members": [ + { + "filePath": "docs-shopify.dev/commands/interfaces/app-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--client-id ", + "value": "string", + "description": "The Client ID of your app.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_CLIENT_ID" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--no-color", + "value": "\"\"", + "description": "Disable color output.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_NO_COLOR" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--output-file ", + "value": "string", + "description": "The file name where results should be written, instead of STDOUT.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_OUTPUT_FILE" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--path ", + "value": "string", + "description": "The path to your app directory.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_PATH" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--query-file ", + "value": "string", + "description": "Path to a file containing the GraphQL query or mutation. Can't be used with --query.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_QUERY_FILE" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--reset", + "value": "\"\"", + "description": "Reset all your settings.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_RESET" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--variable-file ", + "value": "string", + "description": "Path to a file containing GraphQL variables in JSON format. Can't be used with --variables.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_VARIABLE_FILE" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--verbose", + "value": "\"\"", + "description": "Increase the verbosity of the output.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_VERBOSE" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--version ", + "value": "string", + "description": "The API version to use for the query or mutation. Defaults to the latest stable version.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_VERSION" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "-c, --config ", + "value": "string", + "description": "The name of the app configuration.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_APP_CONFIG" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "-q, --query ", + "value": "string", + "description": "The GraphQL query or mutation, as a string.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_QUERY" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "-s, --store ", + "value": "string", + "description": "The myshopify.com domain of the store to execute against. The app must be installed on the store. If not specified, you will be prompted to select a store.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_STORE" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-execute.interface.ts", + "syntaxKind": "PropertySignature", + "name": "-v, --variables ", + "value": "string", + "description": "The values for any GraphQL variables in your query or mutation, in JSON format.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_VARIABLES" + } + ], + "value": "export interface appexecute {\n /**\n * The Client ID of your app.\n * @environment SHOPIFY_FLAG_CLIENT_ID\n */\n '--client-id '?: string\n\n /**\n * The name of the app configuration.\n * @environment SHOPIFY_FLAG_APP_CONFIG\n */\n '-c, --config '?: string\n\n /**\n * Disable color output.\n * @environment SHOPIFY_FLAG_NO_COLOR\n */\n '--no-color'?: ''\n\n /**\n * The file name where results should be written, instead of STDOUT.\n * @environment SHOPIFY_FLAG_OUTPUT_FILE\n */\n '--output-file '?: string\n\n /**\n * The path to your app directory.\n * @environment SHOPIFY_FLAG_PATH\n */\n '--path '?: string\n\n /**\n * The GraphQL query or mutation, as a string.\n * @environment SHOPIFY_FLAG_QUERY\n */\n '-q, --query '?: string\n\n /**\n * Path to a file containing the GraphQL query or mutation. Can't be used with --query.\n * @environment SHOPIFY_FLAG_QUERY_FILE\n */\n '--query-file '?: string\n\n /**\n * Reset all your settings.\n * @environment SHOPIFY_FLAG_RESET\n */\n '--reset'?: ''\n\n /**\n * The myshopify.com domain of the store to execute against. The app must be installed on the store. If not specified, you will be prompted to select a store.\n * @environment SHOPIFY_FLAG_STORE\n */\n '-s, --store '?: string\n\n /**\n * Path to a file containing GraphQL variables in JSON format. Can't be used with --variables.\n * @environment SHOPIFY_FLAG_VARIABLE_FILE\n */\n '--variable-file '?: string\n\n /**\n * The values for any GraphQL variables in your query or mutation, in JSON format.\n * @environment SHOPIFY_FLAG_VARIABLES\n */\n '-v, --variables '?: string\n\n /**\n * Increase the verbosity of the output.\n * @environment SHOPIFY_FLAG_VERBOSE\n */\n '--verbose'?: ''\n\n /**\n * The API version to use for the query or mutation. Defaults to the latest stable version.\n * @environment SHOPIFY_FLAG_VERSION\n */\n '--version '?: string\n}" + } + } + } + ], + "category": "app", + "related": [] + }, { "name": "app function build", "description": "Compiles the function in your current directory to WebAssembly (Wasm) for testing purposes.", diff --git a/packages/app/src/cli/commands/app/bulk/execute.ts b/packages/app/src/cli/commands/app/bulk/execute.ts index 6b7be8a28ad..8c06f1ddeea 100644 --- a/packages/app/src/cli/commands/app/bulk/execute.ts +++ b/packages/app/src/cli/commands/app/bulk/execute.ts @@ -7,10 +7,13 @@ import {globalFlags} from '@shopify/cli-kit/node/cli' export default class BulkExecute extends AppLinkedCommand { static summary = 'Execute bulk operations.' - static description = - 'Executes an Admin API GraphQL query or mutation on the specified dev store, as a bulk operation.' + static descriptionWithMarkdown = `Executes an Admin API GraphQL query or mutation on the specified store, as a bulk operation. Mutations are only allowed on dev stores. - static hidden = true + Bulk operations allow you to process large amounts of data asynchronously. Learn more about [bulk query operations](https://shopify.dev/docs/api/usage/bulk-operations/queries) and [bulk mutation operations](https://shopify.dev/docs/api/usage/bulk-operations/imports). + + Use [\`bulk status\`](https://shopify.dev/docs/api/shopify-cli/app/app-bulk-status) to check the status of your bulk operations.` + + static description = this.descriptionWithoutMarkdown() static flags = { ...globalFlags, diff --git a/packages/app/src/cli/commands/app/bulk/status.ts b/packages/app/src/cli/commands/app/bulk/status.ts index 4b2e28951a8..73ba683c98e 100644 --- a/packages/app/src/cli/commands/app/bulk/status.ts +++ b/packages/app/src/cli/commands/app/bulk/status.ts @@ -13,17 +13,20 @@ import {normalizeStoreFqdn} from '@shopify/cli-kit/node/context/fqdn' export default class BulkStatus extends AppLinkedCommand { static summary = 'Check the status of bulk operations.' - static description = - 'Check the status of a specific bulk operation by ID, or list all bulk operations in the last 7 days.' + static descriptionWithMarkdown = `Check the status of a specific bulk operation by ID, or list all bulk operations belonging to this app on this store in the last 7 days. - static hidden = true + Bulk operations allow you to process large amounts of data asynchronously. Learn more about [bulk query operations](https://shopify.dev/docs/api/usage/bulk-operations/queries) and [bulk mutation operations](https://shopify.dev/docs/api/usage/bulk-operations/imports). + + Use [\`bulk execute\`](https://shopify.dev/docs/api/shopify-cli/app/app-bulk-execute) to start a new bulk operation.` + + static description = this.descriptionWithoutMarkdown() static flags = { ...globalFlags, ...appFlags, id: Flags.string({ description: - 'The bulk operation ID (numeric ID or full GID). If not provided, lists all bulk operations in the last 7 days.', + 'The bulk operation ID (numeric ID or full GID). If not provided, lists all bulk operations belonging to this app on this store in the last 7 days.', env: 'SHOPIFY_FLAG_ID', }), store: Flags.string({ diff --git a/packages/app/src/cli/commands/app/execute.ts b/packages/app/src/cli/commands/app/execute.ts index 79b3e89a261..656543bd40e 100644 --- a/packages/app/src/cli/commands/app/execute.ts +++ b/packages/app/src/cli/commands/app/execute.ts @@ -7,9 +7,11 @@ import {globalFlags} from '@shopify/cli-kit/node/cli' export default class Execute extends AppLinkedCommand { static summary = 'Execute GraphQL queries and mutations.' - static hidden = true + static descriptionWithMarkdown = `Executes an Admin API GraphQL query or mutation on the specified store. Mutations are only allowed on dev stores. - static description = 'Executes an Admin API GraphQL query or mutation on the specified dev store.' + For operations that process large amounts of data, use [\`bulk execute\`](https://shopify.dev/docs/api/shopify-cli/app/app-bulk-execute) instead.` + + static description = this.descriptionWithoutMarkdown() static flags = { ...globalFlags, diff --git a/packages/cli/README.md b/packages/cli/README.md index 0b10237df25..2a5dc34f7e3 100644 --- a/packages/cli/README.md +++ b/packages/cli/README.md @@ -1,6 +1,8 @@ # Commands * [`shopify app build`](#shopify-app-build) +* [`shopify app bulk execute`](#shopify-app-bulk-execute) +* [`shopify app bulk status`](#shopify-app-bulk-status) * [`shopify app config link`](#shopify-app-config-link) * [`shopify app config pull`](#shopify-app-config-pull) * [`shopify app config use [config] [flags]`](#shopify-app-config-use-config-flags) @@ -9,6 +11,7 @@ * [`shopify app dev clean`](#shopify-app-dev-clean) * [`shopify app env pull`](#shopify-app-env-pull) * [`shopify app env show`](#shopify-app-env-show) +* [`shopify app execute`](#shopify-app-execute) * [`shopify app function build`](#shopify-app-function-build) * [`shopify app function info`](#shopify-app-function-info) * [`shopify app function replay`](#shopify-app-function-replay) @@ -118,6 +121,83 @@ DESCRIPTION extension to ensure that it's valid. ``` +## `shopify app bulk execute` + +Execute bulk operations. + +``` +USAGE + $ shopify app bulk execute [--client-id | -c ] [--no-color] [--output-file --watch] [--path + ] [-q ] [--query-file ] [--reset | ] [-s ] [--variable-file | -v ...] + [--verbose] [--version ] + +FLAGS + -c, --config= The name of the app configuration. + -q, --query= The GraphQL query or mutation to run as a bulk operation. + -s, --store= The store domain. Must be an existing dev store. + -v, --variables=... The values for any GraphQL variables in your mutation, in JSON format. Can be specified + multiple times. + --client-id= The Client ID of your app. + --no-color Disable color output. + --output-file= The file path where results should be written if --watch is specified. If not specified, + results will be written to STDOUT. + --path= The path to your app directory. + --query-file= Path to a file containing the GraphQL query or mutation. Can't be used with --query. + --reset Reset all your settings. + --variable-file= Path to a file containing GraphQL variables in JSONL format (one JSON object per line). + Can't be used with --variables. + --verbose Increase the verbosity of the output. + --version= The API version to use for the bulk operation. If not specified, uses the latest stable + version. + --watch Wait for bulk operation results before exiting. Defaults to false. + +DESCRIPTION + Execute bulk operations. + + Executes an Admin API GraphQL query or mutation on the specified store, as a bulk operation. Mutations are only + allowed on dev stores. + + Bulk operations allow you to process large amounts of data asynchronously. Learn more about "bulk query operations" + (https://shopify.dev/docs/api/usage/bulk-operations/queries) and "bulk mutation operations" + (https://shopify.dev/docs/api/usage/bulk-operations/imports). + + Use "`bulk status`" (https://shopify.dev/docs/api/shopify-cli/app/app-bulk-status) to check the status of your bulk + operations. +``` + +## `shopify app bulk status` + +Check the status of bulk operations. + +``` +USAGE + $ shopify app bulk status [--client-id | -c ] [--id ] [--no-color] [--path ] [--reset + | ] [-s ] [--verbose] + +FLAGS + -c, --config= The name of the app configuration. + -s, --store= The store domain. Must be an existing dev store. + --client-id= The Client ID of your app. + --id= The bulk operation ID (numeric ID or full GID). If not provided, lists all bulk operations + belonging to this app on this store in the last 7 days. + --no-color Disable color output. + --path= The path to your app directory. + --reset Reset all your settings. + --verbose Increase the verbosity of the output. + +DESCRIPTION + Check the status of bulk operations. + + Check the status of a specific bulk operation by ID, or list all bulk operations belonging to this app on this store + in the last 7 days. + + Bulk operations allow you to process large amounts of data asynchronously. Learn more about "bulk query operations" + (https://shopify.dev/docs/api/usage/bulk-operations/queries) and "bulk mutation operations" + (https://shopify.dev/docs/api/usage/bulk-operations/imports). + + Use "`bulk execute`" (https://shopify.dev/docs/api/shopify-cli/app/app-bulk-execute) to start a new bulk operation. +``` + ## `shopify app config link` Fetch your app configuration from the Developer Dashboard. @@ -359,6 +439,42 @@ DESCRIPTION Displays environment variables that can be used to deploy apps and app extensions. ``` +## `shopify app execute` + +Execute GraphQL queries and mutations. + +``` +USAGE + $ shopify app execute [--client-id | -c ] [--no-color] [--output-file ] [--path ] + [-q ] [--query-file ] [--reset | ] [-s ] [--variable-file | -v ] [--verbose] + [--version ] + +FLAGS + -c, --config= The name of the app configuration. + -q, --query= The GraphQL query or mutation, as a string. + -s, --store= The myshopify.com domain of the store to execute against. The app must be installed on + the store. If not specified, you will be prompted to select a store. + -v, --variables= The values for any GraphQL variables in your query or mutation, in JSON format. + --client-id= The Client ID of your app. + --no-color Disable color output. + --output-file= The file name where results should be written, instead of STDOUT. + --path= The path to your app directory. + --query-file= Path to a file containing the GraphQL query or mutation. Can't be used with --query. + --reset Reset all your settings. + --variable-file= Path to a file containing GraphQL variables in JSON format. Can't be used with + --variables. + --verbose Increase the verbosity of the output. + --version= The API version to use for the query or mutation. Defaults to the latest stable version. + +DESCRIPTION + Execute GraphQL queries and mutations. + + Executes an Admin API GraphQL query or mutation on the specified store. Mutations are only allowed on dev stores. + + For operations that process large amounts of data, use "`bulk execute`" + (https://shopify.dev/docs/api/shopify-cli/app/app-bulk-execute) instead. +``` + ## `shopify app function build` Compile a function to wasm. diff --git a/packages/cli/oclif.manifest.json b/packages/cli/oclif.manifest.json index e9eeceff6d9..324ca141c6d 100644 --- a/packages/cli/oclif.manifest.json +++ b/packages/cli/oclif.manifest.json @@ -188,7 +188,8 @@ "args": { }, "customPluginName": "@shopify/app", - "description": "Executes an Admin API GraphQL query or mutation on the specified dev store, as a bulk operation.", + "description": "Executes an Admin API GraphQL query or mutation on the specified store, as a bulk operation. Mutations are only allowed on dev stores.\n\n Bulk operations allow you to process large amounts of data asynchronously. Learn more about \"bulk query operations\" (https://shopify.dev/docs/api/usage/bulk-operations/queries) and \"bulk mutation operations\" (https://shopify.dev/docs/api/usage/bulk-operations/imports).\n\n Use \"`bulk status`\" (https://shopify.dev/docs/api/shopify-cli/app/app-bulk-status) to check the status of your bulk operations.", + "descriptionWithMarkdown": "Executes an Admin API GraphQL query or mutation on the specified store, as a bulk operation. Mutations are only allowed on dev stores.\n\n Bulk operations allow you to process large amounts of data asynchronously. Learn more about [bulk query operations](https://shopify.dev/docs/api/usage/bulk-operations/queries) and [bulk mutation operations](https://shopify.dev/docs/api/usage/bulk-operations/imports).\n\n Use [`bulk status`](https://shopify.dev/docs/api/shopify-cli/app/app-bulk-status) to check the status of your bulk operations.", "flags": { "client-id": { "description": "The Client ID of your app.", @@ -326,7 +327,6 @@ } }, "hasDynamicHelp": false, - "hidden": true, "hiddenAliases": [ ], "id": "app:bulk:execute", @@ -342,7 +342,8 @@ "args": { }, "customPluginName": "@shopify/app", - "description": "Check the status of a specific bulk operation by ID, or list all bulk operations in the last 7 days.", + "description": "Check the status of a specific bulk operation by ID, or list all bulk operations belonging to this app on this store in the last 7 days.\n\n Bulk operations allow you to process large amounts of data asynchronously. Learn more about \"bulk query operations\" (https://shopify.dev/docs/api/usage/bulk-operations/queries) and \"bulk mutation operations\" (https://shopify.dev/docs/api/usage/bulk-operations/imports).\n\n Use \"`bulk execute`\" (https://shopify.dev/docs/api/shopify-cli/app/app-bulk-execute) to start a new bulk operation.", + "descriptionWithMarkdown": "Check the status of a specific bulk operation by ID, or list all bulk operations belonging to this app on this store in the last 7 days.\n\n Bulk operations allow you to process large amounts of data asynchronously. Learn more about [bulk query operations](https://shopify.dev/docs/api/usage/bulk-operations/queries) and [bulk mutation operations](https://shopify.dev/docs/api/usage/bulk-operations/imports).\n\n Use [`bulk execute`](https://shopify.dev/docs/api/shopify-cli/app/app-bulk-execute) to start a new bulk operation.", "flags": { "client-id": { "description": "The Client ID of your app.", @@ -367,7 +368,7 @@ "type": "option" }, "id": { - "description": "The bulk operation ID (numeric ID or full GID). If not provided, lists all bulk operations in the last 7 days.", + "description": "The bulk operation ID (numeric ID or full GID). If not provided, lists all bulk operations belonging to this app on this store in the last 7 days.", "env": "SHOPIFY_FLAG_ID", "hasDynamicHelp": false, "multiple": false, @@ -421,7 +422,6 @@ } }, "hasDynamicHelp": false, - "hidden": true, "hiddenAliases": [ ], "id": "app:bulk:status", @@ -1257,7 +1257,8 @@ "args": { }, "customPluginName": "@shopify/app", - "description": "Executes an Admin API GraphQL query or mutation on the specified dev store.", + "description": "Executes an Admin API GraphQL query or mutation on the specified store. Mutations are only allowed on dev stores.\n\n For operations that process large amounts of data, use \"`bulk execute`\" (https://shopify.dev/docs/api/shopify-cli/app/app-bulk-execute) instead.", + "descriptionWithMarkdown": "Executes an Admin API GraphQL query or mutation on the specified store. Mutations are only allowed on dev stores.\n\n For operations that process large amounts of data, use [`bulk execute`](https://shopify.dev/docs/api/shopify-cli/app/app-bulk-execute) instead.", "flags": { "client-id": { "description": "The Client ID of your app.", @@ -1385,7 +1386,6 @@ } }, "hasDynamicHelp": false, - "hidden": true, "hiddenAliases": [ ], "id": "app:execute", diff --git a/packages/features/snapshots/commands.txt b/packages/features/snapshots/commands.txt index c3e97bdf2ab..3a960471837 100644 --- a/packages/features/snapshots/commands.txt +++ b/packages/features/snapshots/commands.txt @@ -1,5 +1,8 @@ ├─ app │ ├─ build +│ ├─ bulk +│ │ ├─ execute +│ │ └─ status │ ├─ config │ │ ├─ link │ │ ├─ pull @@ -10,6 +13,7 @@ │ ├─ env │ │ ├─ pull │ │ └─ show +│ ├─ execute │ ├─ function │ │ ├─ build │ │ ├─ info From 3250750bdf9189e0dfdab5cb45964278cfc7d278 Mon Sep 17 00:00:00 2001 From: Jordan Verasamy Date: Mon, 2 Feb 2026 13:21:04 -0800 Subject: [PATCH 4/6] Release `app bulk cancel` command --- .../commands/app-bulk-cancel.doc.ts | 34 ++++++ .../examples/app-bulk-cancel.example.sh | 1 + .../interfaces/app-bulk-cancel.interface.ts | 50 ++++++++ .../generated/generated_docs_data.json | 109 ++++++++++++++++++ .../app/src/cli/commands/app/bulk/cancel.ts | 2 - packages/cli/README.md | 26 +++++ packages/cli/oclif.manifest.json | 1 - packages/features/snapshots/commands.txt | 1 + 8 files changed, 221 insertions(+), 3 deletions(-) create mode 100644 docs-shopify.dev/commands/app-bulk-cancel.doc.ts create mode 100644 docs-shopify.dev/commands/examples/app-bulk-cancel.example.sh create mode 100644 docs-shopify.dev/commands/interfaces/app-bulk-cancel.interface.ts diff --git a/docs-shopify.dev/commands/app-bulk-cancel.doc.ts b/docs-shopify.dev/commands/app-bulk-cancel.doc.ts new file mode 100644 index 00000000000..184427c825e --- /dev/null +++ b/docs-shopify.dev/commands/app-bulk-cancel.doc.ts @@ -0,0 +1,34 @@ +// This is an autogenerated file. Don't edit this file manually. +import {ReferenceEntityTemplateSchema} from '@shopify/generate-docs' + +const data: ReferenceEntityTemplateSchema = { + name: 'app bulk cancel', + description: `Cancels a running bulk operation by ID.`, + overviewPreviewDescription: `Cancel a bulk operation.`, + type: 'command', + isVisualComponent: false, + defaultExample: { + codeblock: { + tabs: [ + { + title: 'app bulk cancel', + code: './examples/app-bulk-cancel.example.sh', + language: 'bash', + }, + ], + title: 'app bulk cancel', + }, + }, + definitions: [ + { + title: 'Flags', + description: 'The following flags are available for the `app bulk cancel` command:', + type: 'appbulkcancel', + }, + ], + category: 'app', + related: [ + ], +} + +export default data \ No newline at end of file diff --git a/docs-shopify.dev/commands/examples/app-bulk-cancel.example.sh b/docs-shopify.dev/commands/examples/app-bulk-cancel.example.sh new file mode 100644 index 00000000000..1feb4eaef61 --- /dev/null +++ b/docs-shopify.dev/commands/examples/app-bulk-cancel.example.sh @@ -0,0 +1 @@ +shopify app bulk cancel [flags] \ No newline at end of file diff --git a/docs-shopify.dev/commands/interfaces/app-bulk-cancel.interface.ts b/docs-shopify.dev/commands/interfaces/app-bulk-cancel.interface.ts new file mode 100644 index 00000000000..5bb81f2b196 --- /dev/null +++ b/docs-shopify.dev/commands/interfaces/app-bulk-cancel.interface.ts @@ -0,0 +1,50 @@ +// This is an autogenerated file. Don't edit this file manually. +export interface appbulkcancel { + /** + * The Client ID of your app. + * @environment SHOPIFY_FLAG_CLIENT_ID + */ + '--client-id '?: string + + /** + * The name of the app configuration. + * @environment SHOPIFY_FLAG_APP_CONFIG + */ + '-c, --config '?: string + + /** + * The bulk operation ID to cancel (numeric ID or full GID). + * @environment SHOPIFY_FLAG_ID + */ + '--id ': string + + /** + * Disable color output. + * @environment SHOPIFY_FLAG_NO_COLOR + */ + '--no-color'?: '' + + /** + * The path to your app directory. + * @environment SHOPIFY_FLAG_PATH + */ + '--path '?: string + + /** + * Reset all your settings. + * @environment SHOPIFY_FLAG_RESET + */ + '--reset'?: '' + + /** + * The store domain. Must be an existing dev store. + * @environment SHOPIFY_FLAG_STORE + */ + '-s, --store '?: string + + /** + * Increase the verbosity of the output. + * @environment SHOPIFY_FLAG_VERBOSE + */ + '--verbose'?: '' +} diff --git a/docs-shopify.dev/generated/generated_docs_data.json b/docs-shopify.dev/generated/generated_docs_data.json index d1eff7f7415..8545d070688 100644 --- a/docs-shopify.dev/generated/generated_docs_data.json +++ b/docs-shopify.dev/generated/generated_docs_data.json @@ -100,6 +100,115 @@ "category": "app", "related": [] }, + { + "name": "app bulk cancel", + "description": "Cancels a running bulk operation by ID.", + "overviewPreviewDescription": "Cancel a bulk operation.", + "type": "command", + "isVisualComponent": false, + "defaultExample": { + "codeblock": { + "tabs": [ + { + "title": "app bulk cancel", + "code": "shopify app bulk cancel [flags]", + "language": "bash" + } + ], + "title": "app bulk cancel" + } + }, + "definitions": [ + { + "title": "Flags", + "description": "The following flags are available for the `app bulk cancel` command:", + "type": "appbulkcancel", + "typeDefinitions": { + "appbulkcancel": { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-cancel.interface.ts", + "name": "appbulkcancel", + "description": "", + "members": [ + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-cancel.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--client-id ", + "value": "string", + "description": "The Client ID of your app.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_CLIENT_ID" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-cancel.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--id ", + "value": "string", + "description": "The bulk operation ID to cancel (numeric ID or full GID).", + "environmentValue": "SHOPIFY_FLAG_ID" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-cancel.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--no-color", + "value": "\"\"", + "description": "Disable color output.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_NO_COLOR" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-cancel.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--path ", + "value": "string", + "description": "The path to your app directory.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_PATH" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-cancel.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--reset", + "value": "\"\"", + "description": "Reset all your settings.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_RESET" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-cancel.interface.ts", + "syntaxKind": "PropertySignature", + "name": "--verbose", + "value": "\"\"", + "description": "Increase the verbosity of the output.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_VERBOSE" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-cancel.interface.ts", + "syntaxKind": "PropertySignature", + "name": "-c, --config ", + "value": "string", + "description": "The name of the app configuration.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_APP_CONFIG" + }, + { + "filePath": "docs-shopify.dev/commands/interfaces/app-bulk-cancel.interface.ts", + "syntaxKind": "PropertySignature", + "name": "-s, --store ", + "value": "string", + "description": "The store domain. Must be an existing dev store.", + "isOptional": true, + "environmentValue": "SHOPIFY_FLAG_STORE" + } + ], + "value": "export interface appbulkcancel {\n /**\n * The Client ID of your app.\n * @environment SHOPIFY_FLAG_CLIENT_ID\n */\n '--client-id '?: string\n\n /**\n * The name of the app configuration.\n * @environment SHOPIFY_FLAG_APP_CONFIG\n */\n '-c, --config '?: string\n\n /**\n * The bulk operation ID to cancel (numeric ID or full GID).\n * @environment SHOPIFY_FLAG_ID\n */\n '--id ': string\n\n /**\n * Disable color output.\n * @environment SHOPIFY_FLAG_NO_COLOR\n */\n '--no-color'?: ''\n\n /**\n * The path to your app directory.\n * @environment SHOPIFY_FLAG_PATH\n */\n '--path '?: string\n\n /**\n * Reset all your settings.\n * @environment SHOPIFY_FLAG_RESET\n */\n '--reset'?: ''\n\n /**\n * The store domain. Must be an existing dev store.\n * @environment SHOPIFY_FLAG_STORE\n */\n '-s, --store '?: string\n\n /**\n * Increase the verbosity of the output.\n * @environment SHOPIFY_FLAG_VERBOSE\n */\n '--verbose'?: ''\n}" + } + } + } + ], + "category": "app", + "related": [] + }, { "name": "app bulk execute", "description": "Executes an Admin API GraphQL query or mutation on the specified store, as a bulk operation. Mutations are only allowed on dev stores.\n\n Bulk operations allow you to process large amounts of data asynchronously. Learn more about [bulk query operations](/docs/api/usage/bulk-operations/queries) and [bulk mutation operations](/docs/api/usage/bulk-operations/imports).\n\n Use [`bulk status`](/docs/api/shopify-cli/app/app-bulk-status) to check the status of your bulk operations.", diff --git a/packages/app/src/cli/commands/app/bulk/cancel.ts b/packages/app/src/cli/commands/app/bulk/cancel.ts index 2b39e9ef898..23f1cceb19f 100644 --- a/packages/app/src/cli/commands/app/bulk/cancel.ts +++ b/packages/app/src/cli/commands/app/bulk/cancel.ts @@ -12,8 +12,6 @@ export default class BulkCancel extends AppLinkedCommand { static description = 'Cancels a running bulk operation by ID.' - static hidden = true - static flags = { ...globalFlags, ...appFlags, diff --git a/packages/cli/README.md b/packages/cli/README.md index 2a5dc34f7e3..a1f41bcf4ea 100644 --- a/packages/cli/README.md +++ b/packages/cli/README.md @@ -1,6 +1,7 @@ # Commands * [`shopify app build`](#shopify-app-build) +* [`shopify app bulk cancel`](#shopify-app-bulk-cancel) * [`shopify app bulk execute`](#shopify-app-bulk-execute) * [`shopify app bulk status`](#shopify-app-bulk-status) * [`shopify app config link`](#shopify-app-config-link) @@ -121,6 +122,31 @@ DESCRIPTION extension to ensure that it's valid. ``` +## `shopify app bulk cancel` + +Cancel a bulk operation. + +``` +USAGE + $ shopify app bulk cancel --id [--client-id | -c ] [--no-color] [--path ] [--reset | + ] [-s ] [--verbose] + +FLAGS + -c, --config= The name of the app configuration. + -s, --store= The store domain. Must be an existing dev store. + --client-id= The Client ID of your app. + --id= (required) The bulk operation ID to cancel (numeric ID or full GID). + --no-color Disable color output. + --path= The path to your app directory. + --reset Reset all your settings. + --verbose Increase the verbosity of the output. + +DESCRIPTION + Cancel a bulk operation. + + Cancels a running bulk operation by ID. +``` + ## `shopify app bulk execute` Execute bulk operations. diff --git a/packages/cli/oclif.manifest.json b/packages/cli/oclif.manifest.json index 324ca141c6d..2c2bbdc0d90 100644 --- a/packages/cli/oclif.manifest.json +++ b/packages/cli/oclif.manifest.json @@ -172,7 +172,6 @@ } }, "hasDynamicHelp": false, - "hidden": true, "hiddenAliases": [ ], "id": "app:bulk:cancel", diff --git a/packages/features/snapshots/commands.txt b/packages/features/snapshots/commands.txt index 3a960471837..5a978dfe6ba 100644 --- a/packages/features/snapshots/commands.txt +++ b/packages/features/snapshots/commands.txt @@ -1,6 +1,7 @@ ├─ app │ ├─ build │ ├─ bulk +│ │ ├─ cancel │ │ ├─ execute │ │ └─ status │ ├─ config From 5556dc5317dd4b591dd42c8a9a9653052f7e12db Mon Sep 17 00:00:00 2001 From: Jordan Verasamy Date: Mon, 2 Feb 2026 13:29:32 -0800 Subject: [PATCH 5/6] Slightly adjust bulk cancel failure copy text --- .../cli/services/bulk-operations/cancel-bulk-operation.test.ts | 2 +- .../src/cli/services/bulk-operations/cancel-bulk-operation.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/app/src/cli/services/bulk-operations/cancel-bulk-operation.test.ts b/packages/app/src/cli/services/bulk-operations/cancel-bulk-operation.test.ts index aae1203e4da..efee9318fe7 100644 --- a/packages/app/src/cli/services/bulk-operations/cancel-bulk-operation.test.ts +++ b/packages/app/src/cli/services/bulk-operations/cancel-bulk-operation.test.ts @@ -140,7 +140,7 @@ describe('cancelBulkOperation', () => { await cancelBulkOperation({organization: mockOrganization, storeFqdn, operationId, remoteApp: mockRemoteApp}) expect(renderError).toHaveBeenCalledWith({ - headline: 'Bulk operation cancellation errors.', + headline: 'Failed to cancel bulk operation.', body: 'id: Operation not found', }) }) diff --git a/packages/app/src/cli/services/bulk-operations/cancel-bulk-operation.ts b/packages/app/src/cli/services/bulk-operations/cancel-bulk-operation.ts index dab844a03f0..6badc0d5f26 100644 --- a/packages/app/src/cli/services/bulk-operations/cancel-bulk-operation.ts +++ b/packages/app/src/cli/services/bulk-operations/cancel-bulk-operation.ts @@ -43,7 +43,7 @@ export async function cancelBulkOperation(options: CancelBulkOperationOptions): }) if (response.bulkOperationCancel?.userErrors?.length) { - renderBulkOperationUserErrors(response.bulkOperationCancel.userErrors, 'Bulk operation cancellation errors.') + renderBulkOperationUserErrors(response.bulkOperationCancel.userErrors, 'Failed to cancel bulk operation.') return } From fab497a409b152041056ce2e195b6138203f49d9 Mon Sep 17 00:00:00 2001 From: Jordan Verasamy Date: Wed, 4 Feb 2026 16:28:04 -0800 Subject: [PATCH 6/6] Add changeset for bulk operations CLI backport Co-Authored-By: Claude Opus 4.5 --- .changeset/five-boxes-teach.md | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 .changeset/five-boxes-teach.md diff --git a/.changeset/five-boxes-teach.md b/.changeset/five-boxes-teach.md new file mode 100644 index 00000000000..1e85aaa2dca --- /dev/null +++ b/.changeset/five-boxes-teach.md @@ -0,0 +1,10 @@ +--- +'@shopify/app': patch +--- + +Release bulk operations CLI commands: + +- `app execute` +- `app bulk execute` +- `app bulk status` +- `app bulk cancel`