App reviews, troubleshooting, and recommendations
I'm not sure what or when this changed but I’m no longer able to make a PUT request to /admin/api/{VERSION}/themes/{THEME_ID}/assets.json with a post body like this, as depicted in the docs:
{
"asset": {
"key": "layout/alternate.liquid",
"source_key": "layout/theme.liquid"
}
}
I get the following error no matter what the file I’m trying to create or duplicate from source:
{
"errors": {
"asset": [
"Template type 'alternate' does not support liquid templates"
]
}
}
Unfortunately, this is definitely a breaking change. I haven’t changed any code in my app, have replicated this issue in Postman, and have tried all supported API versions and nothing changes…same result.
😞
Solved! Go to the solution
This is an accepted solution.
In case this helps anyone, it turns out Shopify did make a change that I still don't see documented.
On January 8th 2021 a fix was implemented that is now enforcing a naming convention for template type theme assets.
When using the Asset API you'll now need to enforce the template type as part of the key. So for example, if you were creating a new 404 template the duplicate rest payload to the Asset endpoint might look something like this.
{
"asset": {
"key": "templates/myfile.alternate.liquid",
"source_key": "templates/myfile.liquid"
}
}
This is an accepted solution.
In case this helps anyone, it turns out Shopify did make a change that I still don't see documented.
On January 8th 2021 a fix was implemented that is now enforcing a naming convention for template type theme assets.
When using the Asset API you'll now need to enforce the template type as part of the key. So for example, if you were creating a new 404 template the duplicate rest payload to the Asset endpoint might look something like this.
{
"asset": {
"key": "templates/myfile.alternate.liquid",
"source_key": "templates/myfile.liquid"
}
}
Shopify and our financial partners regularly review and update verification requiremen...
By Jacqui Mar 14, 2025Unlock the potential of marketing on your business growth with Shopify Academy's late...
By Shopify Mar 12, 2025Learn how to increase conversion rates in every stage of the customer journey by enroll...
By Shopify Mar 5, 2025