Skip to main content
The Shoppex Storefront SDK enables you to embed a fully functional store on any website. Display products, manage carts, and redirect customers to checkout - all with a few lines of code.

Features

Product Catalog

Fetch and display products, categories, and groups from your Shoppex store.

Cart Management

Add, update, and remove items. Cart data persists in localStorage.

Secure Checkout

Redirect to Shoppex’s hosted checkout for PCI-compliant payments.

Lightweight

Under 15KB gzipped. No dependencies. Works everywhere.

How It Works

1

Initialize

Add the SDK to your website and initialize with your store slug. One line of code to get started.
2

Display Products

Fetch your product catalog and render it in your own custom UI. Full control over design.
3

Manage Cart

Add items to cart - the SDK handles storage in the browser automatically.
4

Checkout

Redirect customers to Shoppex’s secure, PCI-compliant hosted checkout page.
5

Delivery

Customers receive their digital products via email. You’re done!
No backend required. The SDK handles everything client-side. Cart data is stored in localStorage, and checkout is hosted by Shoppex.

Quick Example

<script src="https://cdn.shoppex.io/sdk/v1/shoppex.min.js"></script>
<script>
  // Initialize with your store slug
  shoppex.init('your-store');

  // Fetch and display products
  shoppex.getProducts().then(({ data }) => {
    data.forEach(product => {
      console.log(product.title, product.price);
    });
  });

  // Add to cart
  shoppex.addToCart('product-id', 'variant-id', 1);

  // Proceed to checkout
  shoppex.checkout();
</script>

Next Steps