Search brands

Search or filter product brands. The response provides the list of brands used in a store. Also operates with a public token.

📘

Access scopes required: read_brands

Headers

NameTypeDescription
AuthorizationstringoAuth token with mandatory Bearer before it. Example: Bearer e***s0, where e***s0 should be replaced with your oAuth token.

Q: How can I specify what fields I want to receive in response?

Add responseFields query param, specifying field names you want to receive.
Example: ?responseFields=count,items(name,productsFilteredByBrandUrl)

All query params

NameTypeDescription
limitnumberMaximum number of returned items. Maximum allowed value: 100. Default value: 100
offsetnumberOffset from the beginning of the returned items list (for paging)
langstringPreferred language for the brand name fields in search results. If a certain field does not have the translation available for the set language, the default language text will be used for that field.
hidden_brandsbooleanBy default, Ecwid returns only brands of enabled (not hidden) products. Set this parameter to true if you want hidden (disabled) product brands to be returned. false is default. Works with a secret token only
baseUrlstringStorefront URL for Ecwid to use when returning product URLs in the url field. If not specified, Ecwid will use the storefront URL specified in the store settings
cleanUrlsbooleanIf true, Ecwid will return the SEO-friendly clean URL (without hash '#') in the url field. If false, Ecwid will return URL in the old format (with hash '#'). We recommend using true value if merchant's website supports clean SEO-friendly URL feature
sortBystringSort order. Supported values:
  • PRODUCT_COUNT_DESC default</li
  • NAME_ASC
.

Q: How to get all products from a store?

Use the offset parameter to get all products in a store. For example, if a store has 452 products, you would need to call the /products endpoint 5 times with different offset parameter values:

  • offset=0 // 0-100 products
  • offset=100 // 100-200 products
  • offset=200 // 200-300 products
  • offset=300 // 300-400 products
  • offset=400 // 400-452 products

As a result, you will get all 452 products after these 5 consecutive requests.

Response

A JSON object of type 'SearchResult' with the following fields:

SearchResult

FieldTypeDescription
totalnumberThe total number of found brands
countnumberThe total number of the brands returned in this batch
offsetnumberOffset from the beginning of the returned items list (for paging)
limitnumberMaximum possible number of returned items in this request.
itemsArrayThe items list

Items

FieldTypeDescription
namestringBrand name
productsFilteredByBrandUrlstringThe URL that leads to the search page of your website with all the products related to a certain brand
nameTranslated<TranslatedNames>Translations of the "brand" value into other languages

TranslatedNames

FieldTypeDescription
'{countrycode}'stringReturns the value that matches with a corresponding language. Example:
"nameTranslated": { 'en': "Adidas", 'fr': "Adidas", 'pt': "Adidas" }

Errors

In case of error, Ecwid responds with an error HTTP status code and, optionally, JSON-formatted body containing error description

HTTP codes

HTTP StatusMeaningCode (optional)
403Access token doesn't have read_brands scope

Error response body (optional)

FieldTypeDescription
errorMessagestringError message
Language
Authorization
Query