See all services → Shopify Plus Partner
Tools Developer

Use Relative URLs in Flow Trigger Lifecycle Callbacks

Flow trigger lifecycle callback extensions now accept relative URL paths, so custom triggers resolve against your dev tunnel locally and your application_url on deploy. No hosted endpoint required to test.

Executive summary

What changed

A Flow trigger lifecycle callback is how your app learns that a merchant enabled or disabled a workflow using one of your custom triggers. If that endpoint does not answer promptly with a 2xx status, the merchant cannot enable the workflow at all. Until now it had to be an absolute HTTPS URL pointing at a running web server.

Relative paths are now supported. During local development, running the app in dev mode resolves the relative path against your development tunnel URL. On deploy, it resolves against the app's application_url. This is the same resolution model that Flow action extensions have used, so the two extension types now behave consistently.

Two constraints are worth noting. Protocol-relative URLs, the kind that begin with a double slash and no scheme, are not supported. And your app configuration must already declare an HTTPS application_url before you deploy with relative paths. Absolute HTTPS URLs remain the correct choice when the endpoint lives outside your app, or when you deliberately want Flow to call one fixed URL in every environment.

Why it matters

For Shopify Plus merchants, the benefit is indirect but real. Custom triggers are how operational events from outside Shopify enter Flow: an ERP marking a purchase order received, a PIM finishing a publish, a 3PL confirming a shipment. These triggers are usually built and maintained by an agency or an internal team working across several environments.

The old requirement produced a specific, recurring failure. A developer rebuilt a tunnel, the callback URL went stale, and the next person to touch a workflow in a staging or sandbox store found they could not enable it. The cause sat two layers away from the symptom, which made it expensive to diagnose. Removing per-environment URL values removes that class of drift, so triggers ship faster and non-production stores fail less mysteriously. If you are weighing how much operational logic to move into Flow, our notes on automating enterprise operations with Shopify Flow and Scripts cover where the line usually sits.

Role-specific impact

Use-case example

Real-world scenario

An industrial distributor runs a custom trigger that fires when their ERP marks a purchase order as received, which starts a Flow workflow to retag inventory and notify the buying team. Under the old model, every tunnel rebuild meant editing two values, the extension configuration and the app's application_url, then redeploying before anyone could enable the workflow in the sandbox store. At five to ten minutes per rebuild, several rebuilds a day across a two-week build, that is most of a day spent on configuration bookkeeping plus the tickets it generated. With a relative path, per-environment edits go to zero.

Implementation checklist

  1. Inventory the trigger lifecycle callback extensions in your app and note which ones use absolute URLs today.
  2. Confirm your app configuration declares an HTTPS application_url, since deploys with relative paths depend on it.
  3. Switch the callback URL to a relative path for any endpoint hosted inside the app itself.
  4. Keep absolute HTTPS for endpoints hosted elsewhere, or where Flow should call the same URL in every environment.
  5. Run the app in dev mode and confirm the callback resolves against your tunnel and returns a 2xx response.
  6. Deploy, then verify end to end that a merchant can enable a workflow using the trigger.
  7. Remove environment-specific URL substitution from your CI pipeline and deployment notes.
  8. Recreate any legacy trigger discovery webhook extensions from the Partner Dashboard with the CLI before editing them.

FAQ

Q: Do protocol-relative URLs such as a double slash followed by a hostname work?

A: No. Use either a relative path or a complete HTTPS URL. There is no third option.

Q: Do existing extensions need to be migrated?

A: No. Absolute HTTPS URLs continue to work exactly as before. Relative paths are an additional option, so adopt them per extension as you touch each one.

Resources

Flow trigger lifecycle callback configuration reference

Need guidance? Talk to Makro.