--- title: app webhook trigger description: |2- Triggers the delivery of a sample Admin API event topic payload to a designated address. 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. 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. To learn more about using webhooks in a Shopify app, refer to [Webhooks overview](/docs/apps/webhooks). ### Limitations - 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. - Webhooks triggered using this method aren't retried when they fail. - Trigger requests are rate-limited using the [Partner API rate limit](/docs/api/partner#rate_limits). - You can't use this method to validate your API webhook subscriptions. api_name: shopify-cli source_url: html: 'https://shopify.dev/docs/api/shopify-cli/app/app-webhook-trigger' md: 'https://shopify.dev/docs/api/shopify-cli/app/app-webhook-trigger.md' --- # app webhook triggercommand Triggers the delivery of a sample Admin API event topic payload to a designated address. 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. 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. To learn more about using webhooks in a Shopify app, refer to [Webhooks overview](https://shopify.dev/docs/apps/webhooks). ### Limitations * 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. * Webhooks triggered using this method aren't retried when they fail. * Trigger requests are rate-limited using the [Partner API rate limit](https://shopify.dev/docs/api/partner#rate_limits). * You can't use this method to validate your API webhook subscriptions. ## Flags The following flags are available for the `app webhook trigger` command: * \--address \ string env: SHOPIFY\_FLAG\_ADDRESS The URL where the webhook payload should be sent. You will need a different address type for each delivery-method: · For remote HTTP testing, use a URL that starts with https\:// · For local HTTP testing, use [http://localhost:{port}/{url-path}](http://localhost:%7Bport%7D/%7Burl-path%7D) · For Google Pub/Sub, use pubsub://{project-id}:{topic-id} · For Amazon EventBridge, use an Amazon Resource Name (ARN) starting with arn:aws:events: * \--api-version \ string env: SHOPIFY\_FLAG\_API\_VERSION The API Version of the webhook topic. * \--client-id \ string env: SHOPIFY\_FLAG\_CLIENT\_ID The Client ID of your app. * \--client-secret \ string env: SHOPIFY\_FLAG\_CLIENT\_SECRET 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. * \--delivery-method \ string env: SHOPIFY\_FLAG\_DELIVERY\_METHOD Method chosen to deliver the topic payload. If not passed, it's inferred from the address. * \--help env: SHOPIFY\_FLAG\_HELP This help. When you run the trigger command the CLI will prompt you for any information that isn't passed using flags. * \--path \ string env: SHOPIFY\_FLAG\_PATH The path to your app directory. * \--reset env: SHOPIFY\_FLAG\_RESET Reset all your settings. * \--shared-secret \ string env: SHOPIFY\_FLAG\_SHARED\_SECRET Deprecated. Please use client-secret. * \--topic \ string env: SHOPIFY\_FLAG\_TOPIC The requested webhook topic. * -c, --config \ string env: SHOPIFY\_FLAG\_APP\_CONFIG The name of the app configuration. ### Examples * #### app webhook trigger ##### app webhook trigger ```bash shopify app webhook trigger [flags] ```