Skip to content

Channels

A channel represents an individual storefront — its hostname, theme, allowed locales and currencies, default locale, base currency, and SEO defaults. Most stores have one channel; multi-channel installations expose every channel through the same endpoints.

Endpoints

MethodPathPurpose
GET/api/shop/channelsPaginated list of channels
GET/api/shop/channels/{id}Single channel by ID

Use the example switcher above the curl block to flip between the two.

Request Headers

HeaderRequiredDescription
AcceptYesapplication/json
X-STOREFRONT-KEYYesStorefront API key (pk_storefront_…)

Query Parameters (collection only)

ParameterTypeDefaultDescription
pageinteger1Page number (1-based)
per_pageinteger10Items per page. Max 50.

The collection response carries pagination headers (X-Total-Count, X-Page, X-Per-Page, X-Total-Pages). See Pagination.

Channel Object Fields

Both endpoints return the same shape — the collection wraps an array of these objects, the single endpoint returns one.

FieldTypeDescription
idintegerChannel primary key
codestringUnique channel code — pass it as the X-Channel header to scope a request
hostnamestringPublic hostname for this channel
themestringTheme assigned to the channel
timezonestring | nullTimezone code (e.g. America/New_York)
homeSeoobjectSEO metadata: { meta_title, meta_keywords, meta_description }
isMaintenanceOnboolean (0/1)Maintenance mode flag
allowedIpsstring | nullComma-separated IP allowlist (used when maintenance mode is on)
logo, faviconstring | nullStorage paths
logoUrl, faviconUrlstring | nullFully-qualified asset URLs
createdAt, updatedAtstring (ISO-8601) | nullTimestamps
localesarray of IRI stringsLocales enabled for this channel — GET <iri> to dereference
currenciesarray of IRI stringsCurrencies enabled for this channel
defaultLocalestring (IRI) | nullDefault locale for the channel
baseCurrencystring (IRI) | nullBase currency for prices
translationstring (IRI) | nullChannel translation for the request locale (single IRI, not inline)
translationsarray of IRI stringsAll locale translations

Unlike Attribute / Category, the channel's translation is returned as an IRI, not an inline object. Follow it with GET <iri> to read name, description, maintenanceModeText, etc. See IRIs & HATEOAS.

Use Cases

  • Discover the channel code to send as X-Channel on subsequent requests.
  • Read locales / currencies / defaultLocale / baseCurrency IRIs to render channel-aware switchers.
  • Read homeSeo for the home-page <title> and meta tags before any product is loaded.
  • Check isMaintenanceOn before showing the storefront; if 1, fetch the translation IRI for the localized maintenance text.

Released under the MIT License.