News |
shopify

Storefront API `@inContext` supports `channelId`

Source: Shopify Dev Changelog

Storefront API Adds Channel-Specific Context Control

Shopify’s Storefront API version 2026-10 now supports a channelId argument in the @inContext directive. Developers can use this parameter to apply a specific sales channel’s context to an entire GraphQL query, affecting product availability and pricing data returned by the API.

The new argument works at the query level. When developers pass a channelId to @inContext, the API returns product data filtered by that channel’s configuration, including which products are available for sale and their channel-specific pricing.

Implementation Details

The syntax follows standard GraphQL patterns. Developers declare channelId as a query variable and pass it to the @inContext directive. The API then applies that channel’s context to all fields in the query, including availableForSale status and priceRange data.

This change affects how multi-channel stores handle product data. Previously, developers needed separate queries or additional filtering logic to retrieve channel-specific information. The new parameter consolidates this into a single query operation.

Developer Considerations

Apps that support multi-channel selling need to update their Storefront API integration to version 2026-10 to access this functionality. Existing queries continue to work without modification, as the channelId argument is optional.

Developers building headless storefronts or custom sales channels can now retrieve accurate product availability and pricing for specific channels without additional API calls. This reduces the complexity of managing channel-specific product catalogs in custom implementations.

Read the full announcement →

Stay in the loop

Get Shopify ecosystem news and positioning insights for app founders.