How to create a Pages template using Shopify API

How to create a Pages template using Shopify API

rg18
Shopify Partner
2 0 8

My Shopify App has a feature that creates a Page using the Pages REST API, for my merchants. In these pages, merchants can add my apps' app blocks. Right before the pages endpoint creation is called, we use Asset API to create a template file. This template file is sent as the `template_suffix` parameter when creating the new Shopify Page.

Now that PUT and DELETE requests to the Asset API are being deprecated, what is the alternative for creating a custom template file to use during the creation of the Page? Is it something achievable with theme app extensions?

Thank you very much!

Replies 5 (5)

tash92
Shopify Partner
2 0 1

Hy facing same issue did you find solution

afsan
Shopify Partner
7 0 1

I am also having the same issue, did you find any solutions??

S Afsan Rahmatullah
Software Engineer, Apploye Inc.

tanmaykejriwal
Shopify Partner
61 1 6

Following!

TK
den232
Shopify Partner
213 8 55

June 2024: I can confirm that PUT still works to duplicate a template, but POST gets me a file not found, 404 error.  jb

dom003
Shopify Partner
8 0 1

following.