diff --git a/.changeset/remove-top-level-webhook-trigger-alias.md b/.changeset/remove-top-level-webhook-trigger-alias.md new file mode 100644 index 00000000000..81dafba5c22 --- /dev/null +++ b/.changeset/remove-top-level-webhook-trigger-alias.md @@ -0,0 +1,5 @@ +--- +'@shopify/app': major +--- + +Remove the deprecated top-level `shopify webhook trigger` alias. Use `shopify app webhook trigger` instead. diff --git a/packages/app/src/cli/commands/webhook/trigger.ts b/packages/app/src/cli/commands/webhook/trigger.ts deleted file mode 100644 index 1d380fa79a1..00000000000 --- a/packages/app/src/cli/commands/webhook/trigger.ts +++ /dev/null @@ -1,19 +0,0 @@ -import WebhookTrigger from '../app/webhook/trigger.js' -import {renderWarning} from '@shopify/cli-kit/node/ui' - -export default class WebhookTriggerDeprecated extends WebhookTrigger { - static hidden = true - - async run() { - renderWarning({ - body: [ - {command: 'webhook trigger'}, - 'is now under the "app" topic. Use', - {command: 'app webhook trigger'}, - 'instead.', - 'This alias will be removed in a future release.', - ], - }) - return super.run() - } -} diff --git a/packages/app/src/cli/index.ts b/packages/app/src/cli/index.ts index 8ae694ad4b6..f9d51c1261c 100644 --- a/packages/app/src/cli/index.ts +++ b/packages/app/src/cli/index.ts @@ -26,7 +26,6 @@ import ConfigValidate from './commands/app/config/validate.js' import Release from './commands/app/release.js' import VersionsList from './commands/app/versions/list.js' import WebhookTrigger from './commands/app/webhook/trigger.js' -import WebhookTriggerDeprecated from './commands/webhook/trigger.js' import init from './hooks/clear_command_cache.js' import gatherPublicMetadata from './hooks/public_metadata.js' import gatherSensitiveMetadata from './hooks/sensitive_metadata.js' @@ -73,7 +72,6 @@ export const commands: {[key: string]: typeof AppLinkedCommand | typeof AppUnlin 'app:generate:extension': AppGenerateExtension, 'app:versions:list': VersionsList, 'app:webhook:trigger': WebhookTrigger, - 'webhook:trigger': WebhookTriggerDeprecated, 'demo:watcher': DemoWatcher, 'organization:list': OrganizationList, } diff --git a/packages/cli/oclif.manifest.json b/packages/cli/oclif.manifest.json index ad9cfd500c8..1b72ee8d48e 100644 --- a/packages/cli/oclif.manifest.json +++ b/packages/cli/oclif.manifest.json @@ -8197,132 +8197,6 @@ "pluginName": "@shopify/cli", "pluginType": "core", "strict": true - }, - "webhook:trigger": { - "aliases": [ - ], - "args": { - }, - "customPluginName": "@shopify/app", - "description": "\n Triggers the delivery of a sample Admin API event topic payload to a designated address.\n\n You should use this command to experiment with webhooks, to initially test your webhook configuration, or for unit testing. However, to test your webhook configuration from end to end, you should always trigger webhooks by performing the related action in Shopify.\n\n Because most webhook deliveries use remote endpoints, you can trigger the command from any directory where you can use Shopify CLI, and send the webhook to any of the supported endpoint types. For example, you can run the command from your app's local directory, but send the webhook to a staging environment endpoint.\n\n To learn more about using webhooks in a Shopify app, refer to \"Webhooks overview\" (https://shopify.dev/docs/apps/webhooks).\n\n ### Limitations\n\n - Webhooks triggered using this method always have the same payload, so they can't be used to test scenarios that differ based on the payload contents.\n - Webhooks triggered using this method aren't retried when they fail.\n - Trigger requests are rate-limited using the \"Partner API rate limit\" (https://shopify.dev/docs/api/partner#rate_limits).\n - You can't use this method to validate your API webhook subscriptions.\n ", - "descriptionWithMarkdown": "\n Triggers the delivery of a sample Admin API event topic payload to a designated address.\n\n You should use this command to experiment with webhooks, to initially test your webhook configuration, or for unit testing. However, to test your webhook configuration from end to end, you should always trigger webhooks by performing the related action in Shopify.\n\n Because most webhook deliveries use remote endpoints, you can trigger the command from any directory where you can use Shopify CLI, and send the webhook to any of the supported endpoint types. For example, you can run the command from your app's local directory, but send the webhook to a staging environment endpoint.\n\n To learn more about using webhooks in a Shopify app, refer to [Webhooks overview](https://shopify.dev/docs/apps/webhooks).\n\n ### Limitations\n\n - Webhooks triggered using this method always have the same payload, so they can't be used to test scenarios that differ based on the payload contents.\n - Webhooks triggered using this method aren't retried when they fail.\n - Trigger requests are rate-limited using the [Partner API rate limit](https://shopify.dev/docs/api/partner#rate_limits).\n - You can't use this method to validate your API webhook subscriptions.\n ", - "flags": { - "address": { - "description": "The URL where the webhook payload should be sent.\n You will need a different address type for each delivery-method:\n · For remote HTTP testing, use a URL that starts with https://\n · For local HTTP testing, use http://localhost:{port}/{url-path}\n · For Google Pub/Sub, use pubsub://{project-id}:{topic-id}\n · For Amazon EventBridge, use an Amazon Resource Name (ARN) starting with arn:aws:events:", - "env": "SHOPIFY_FLAG_ADDRESS", - "hasDynamicHelp": false, - "hidden": false, - "multiple": false, - "name": "address", - "required": false, - "type": "option" - }, - "api-version": { - "description": "The API Version of the webhook topic.", - "env": "SHOPIFY_FLAG_API_VERSION", - "hasDynamicHelp": false, - "hidden": false, - "multiple": false, - "name": "api-version", - "required": false, - "type": "option" - }, - "client-id": { - "description": "The Client ID of your app.", - "env": "SHOPIFY_FLAG_CLIENT_ID", - "exclusive": [ - "config" - ], - "hasDynamicHelp": false, - "hidden": false, - "multiple": false, - "name": "client-id", - "type": "option" - }, - "client-secret": { - "description": "Your app's client secret. This secret allows us to return the X-Shopify-Hmac-SHA256 header that lets you validate the origin of the response that you receive.", - "env": "SHOPIFY_FLAG_CLIENT_SECRET", - "hasDynamicHelp": false, - "hidden": false, - "multiple": false, - "name": "client-secret", - "required": false, - "type": "option" - }, - "config": { - "char": "c", - "description": "The name of the app configuration.", - "env": "SHOPIFY_FLAG_APP_CONFIG", - "hasDynamicHelp": false, - "hidden": false, - "multiple": false, - "name": "config", - "type": "option" - }, - "delivery-method": { - "description": "Method chosen to deliver the topic payload. If not passed, it's inferred from the address.", - "env": "SHOPIFY_FLAG_DELIVERY_METHOD", - "hasDynamicHelp": false, - "hidden": false, - "multiple": false, - "name": "delivery-method", - "options": [ - "http", - "google-pub-sub", - "event-bridge" - ], - "required": false, - "type": "option" - }, - "help": { - "allowNo": false, - "description": "This help. When you run the trigger command the CLI will prompt you for any information that isn't passed using flags.", - "env": "SHOPIFY_FLAG_HELP", - "hidden": false, - "name": "help", - "required": false, - "type": "boolean" - }, - "path": { - "description": "The path to your app directory.", - "env": "SHOPIFY_FLAG_PATH", - "hasDynamicHelp": false, - "multiple": false, - "name": "path", - "noCacheDefault": true, - "type": "option" - }, - "reset": { - "allowNo": false, - "description": "Reset all your settings.", - "env": "SHOPIFY_FLAG_RESET", - "exclusive": [ - "config" - ], - "hidden": false, - "name": "reset", - "type": "boolean" - }, - "topic": { - "description": "The requested webhook topic.", - "env": "SHOPIFY_FLAG_TOPIC", - "hasDynamicHelp": false, - "hidden": false, - "multiple": false, - "name": "topic", - "required": false, - "type": "option" - } - }, - "hasDynamicHelp": false, - "hidden": true, - "hiddenAliases": [ - ], - "id": "webhook:trigger", - "pluginAlias": "@shopify/cli", - "pluginName": "@shopify/cli", - "pluginType": "core", - "summary": "Trigger delivery of a sample webhook topic payload to a designated address." } }, "version": "3.94.0"