shopify python api: how do add new assets to published theme?
<p>The shopify docs are horrible, I couldn't find any info on adding new assets to an existing shopify store.</p>

<p>We're developing an app that needs to add some css and liquid files.</p>

<p>Can someone here can shed some light on how to achieve this simple task?</p>

<p>Thanks</p>

<pre><code>asset = shopify.Asset()
asset.key = "templates/josh.liquid"
asset.value = "{% comment %} Liquid is cool {% endcomment %}"
success = asset.save()
</code></pre>

<p>Be careful; if an asset already exists with the same key then it will be overwritten. You can find out more from the <a href="https://help.shopify.com/api/reference/asset#update" rel="nofollow">Asset API documentation.</a></p>

python shopify