We're moving the community! Starting July 7, the current community will be read-only for approx. 2 weeks. You can browse content, but posting will be temporarily unavailable. Learn more

Regarding the Assets Json API to detect if store owner has enabled the app embed block

Regarding the Assets Json API to detect if store owner has enabled the app embed block

shaileshbizspic
Shopify Partner
6 0 1

Hello Team,

We have a question regarding the usage of assests.json API. 
Can we access the assets.json API to detect whether the store owner has enabled the app embed block?
If we use this API to detect, Will it affect our build for the Shopify badge?

image (3).png

image (2).png

  

Please let us know so that we can move forward according to it.

Reply 1 (1)

den232
Shopify Partner
227 8 57

Oct 2024: Would be nice if the admin graphQL 10-2024 included this ... but not yet ... 

 

On this page  there is a section, which does work for me ... but it uses the dying REST ... jb

Detecting app blocks and app embed blocks

If you want to identify whether a merchant has added app blocks to their theme, or enabled app embed blocks, you can use the Asset REST Admin API resource to look for blocks that match your app type.