discount-app-action-link: fix misleading {functionId} URL guidance - #421
Merged
Conversation
The template told partners to template {functionId} into the intent url
(e.g. /discounts/{functionId}/new) and claimed the platform fills it from the
functionId matchValue. That doesn't work: functionId is an optional intent input
(intents can't require inputs), so it can't fill a URL path segment. matchValue
only routes the intent to the app; it isn't interpolated into the url.
Guidance now: use a static route and, if you need the function ID in the path,
include it directly.
Assisted-By: devx/544990ff-9f89-4bd0-8c23-777a2f097188
loic-d
force-pushed
the
loic/discount-intent-static-url-guidance
branch
from
July 18, 2026 18:17
c8df260 to
f6f1d3e
Compare
loic-d
marked this pull request as ready for review
July 19, 2026 15:58
iphipps
approved these changes
Jul 21, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
The
discount-app-action-linktemplate tells partners they can template{functionId}into the intenturl(e.g./discounts/{functionId}/new) and that the platform fills it from thefunctionIdmatchValueinintent-schema.json.That doesn't work.
functionIdarrives as an optional intent input (intents can't declare required inputs), so the platform can't fill a required URL path segment from it.matchValueonly routes/pins the intent to your app — it is not interpolated into the URL.Fix
Updated the guidance in
shopify.extension.toml.liquidandREADME.md:{functionId}placeholder./discounts/019f…/new).The
{id}param on the edit route is unaffected — it's filled from the top-level intentvalue, not from aninputSchemaproperty.