1 min read

Store Availability

Last Updated - Platform 24.0 - SDK 19.0

When using the Store Finder or Store Details for Store Availability the app switches uses the stores/availability API using the StoreAvailabilityService.

Store Availability is disabled by default as it requires backend support. When enabled, the Store Availability feature is accessed from the Product Details screen via a link that forwards the product and current variant selection.

product details link

Tapping the link will present the Variant Selector if a product variant is not already selected on the Product Details screen.

Enable Store Availability

To enable the link, set the isStoreAvailabilityEnabled setting to true.

  1. Open your AppModule to the setUpDependencies function.
  2. Enable the isStoreAvailabilityEnabled setting.
Settings.ProductDetails.isStoreAvailabilityEnabled = true

If you have previously customised the Product Details screen, or want to customise the link, you can override the link view using a custom data source.

class CustomProductViewDataSource: PoqProductViewDataSource {
let storeAvailabilityLinkView = CustomStoreAvailabilityLinkView()
override func makeViews(for product: ProductDetailsViewData) -> [UIView] {
var views = [UIView?]()
views.append(makeStoreAvailabilityView(with: product))
return views.compactMap { $0 }
override func makeStoreAvailabilityView(with product: ProductDetailsViewData) -> UIView? {
storeAvailabilityLinkView.delegate(to: delegate)
storeAvailabilityLinkView.setup(with: product)
return storeAvailabilityLinkView