Have your say in Community Polls: What was/is your greatest motivation to start your own business?
Our Partner & Developer boards on the community are moving to a brand new home: the .dev community forums! While you can still access past discussions here, for all your future app and storefront building questions, head over to the new forums.

Duplicate theme and connect to github

Solved

Duplicate theme and connect to github

njsaunders
Shopify Partner
2 0 0

I'd like to duplicate the live theme into an unpublished theme via the API, then connect it to a Github branch.

 

The AI bot on Shopify support seems to imply this is possible:

 

duplicate.png

but when I try I get an error about it not being a proper URL:

 

'{"errors":{"src":["131026583597 is not a valid URL"]}}'
Accepted Solution (1)

SBD_
Shopify Staff
1831 273 421

This is an accepted solution.

Hey @njsaunders 

 

I think the bot is confused here - src is for external zipped themes, e.g. `http://themes.shopify.com/theme.zip`

 

I don't believe there's a way to duplicate themes via the API (other than reading the theme, downloading each file and creating a zip).

 

 

Scott | Developer Advocate @ Shopify 

View solution in original post

Replies 4 (4)

SBD_
Shopify Staff
1831 273 421

This is an accepted solution.

Hey @njsaunders 

 

I think the bot is confused here - src is for external zipped themes, e.g. `http://themes.shopify.com/theme.zip`

 

I don't believe there's a way to duplicate themes via the API (other than reading the theme, downloading each file and creating a zip).

 

 

Scott | Developer Advocate @ Shopify 

njsaunders
Shopify Partner
2 0 0

Ok - Thanks.

 

Is there any way to connect/create a theme to a github branch via the API?

Liam
Community Manager
3108 344 895

There are some options for connecting to GitHub brances with the CLI, but our regular APIs don't interact with the GitHub integration. 

Liam | Developer Advocate @ Shopify 
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit Shopify.dev or the Shopify Web Design and Development Blog

Rasmus_Larsen
Shopify Partner
3 0 1

Hi,

Try looking at this one: https://apps.shopify.com/themeflow

You should be able to create the flow that you need.