Shopify API to access the Brand object

Hi there,

Using Shopify API we need to access the store’s Brand object.

  1. Any sample snippet or links anyone can share on how to access the Brand object using PHP code?

  2. Using REST API how can I get value for a storefront variable like {{shop.brand.logo}}

Any help would be appreciated!

Hi @user072319 :waving_hand:

I’d recommend checking out our PHP library for Shopify APIs that can make GraphQL requests. At this time, the Brand object is only accessible via Storefront API which only supports GraphQL. The query would look something like:

{
    shop {
        brand {
            logo {
                image {
                    url
                }
            }
        }
    }
}

Hope that helps!

it don’t work as expected , it shows in the documentation but there is no mention in query doc

when i try to query i get brand don’t exist

Did you ever resolve this? Running into a similar issue. I have access to the Shop object, and it doesn’t appear that brand has any special permission requirements.