Case Study: Custom Wholesale Marketplace migration to Shopify Plus

Tradyl, a Bangalore based woman-led startup is a wholesale e-commerce marketplace for suppliers in India to sell clothing products around the world had a custom website with NextJS as a frontend and as the backend.

Their challenge was frontend design changes and new sections taking too much time to design and develop which led to issues with backend performance regularly. They approached us with this problem and requested a migration to Shopify.

Usually, our customers start of with a lower plan on Shopify and then move to Shopify Plus once they scale but Tradyl had unique requirements that we highlight below.

Challenge 1: Volume Discounts

Since Tradyl is a wholesale marketplace, they also sell based on volume. This was a challenge because Shopify does not allow changing the price of a product based on volume by default. The merchant needs the Wholesale Channel(now discontinued) or the new B2B Channel which is available to Shopify Plus merchants only. This allows the merchant to apply volume prices for all products on the catalog but Tradyl had different volume price structures based on product verticals.

Clarity made use of Product and Variant Metafields. While the products had common fields, the variants had 3 price levels based on 3 quantity tiers. Each level had a Minimum Quantity, Maximum Quantity and Price, a total of 9 metafields per variant.

Custom Volume-based Product form using Shopify Ajax API

We leveraged Shopify liquid to fetch all variant metafields related to the volume price structure and built a custom vanilla JS order form. This allowed a customer to add the quantities for each size and then add to cart, something that is not available by default on a Shopify theme.

The prices also had to change based on the total quantity of the product. We had to use Shopify product attributes here to send these to cart which we will talk about in the next challenge.

Challenge 2: Checkout customisation

Shopify by default does not allow customising the prices of a product unless you are on Shopify Plus. Tradyl were convinced by the demos provided by Clarity and signed the contract for the Plus account.

The main reason to switch to Shopify Plus was a feature called Shopify Scripts which allows code written in Ruby that lets a developer modify certain parts of the checkout flow. In our case we needed to modify the price of the product based on the quantity.

We fetched the custom attributes passed on via the product form and updated the default price in checkout to the updated price based on the quantity of the variant added.

Shopify Scripts will be discontinued in 2024 and we’re working on migrating this to Shopify Functions that offers a lot more flexibility and performance.

Challenge 3: Product Catalog

By default, the built-in Shopify Product importer only allows you to manage the base predefined fields in Shopify. If a merchant wants to manage metafields, they would need to use an app.

Luckily, we learned so much about Shopify product management in our previous project that we decide to build our own public app – Bulk Transporter. We used Bulk Mutation API for this that allowed us to push changes with 1 api call to Shopify.

It would have been very slow to update products in Tradyl one-by-one because of the following numbers in their store:

Products: 40,000
Variants: 175,000
Product Metafields: 690,000
Variant Metafields: 2,150,000.

Shopify’s Bulk Mutation API allows us to update this in a few hours versus days.

Challenge 4: Multi-currency

As a global marketplace, Tradyl wanted to sell products in multiple currencies just like how they did with their previous website. This challenge is yet to be resolved since Shopify only allows multi-currency via Shopify Payments(their own payment gateway) which is not available in India yet. For now, they have decided to sell in USD only.

This was our most challenging Shopify project to date because it involved a lot more customisation than we expected and we’re happy to say we delivered it with a few unavoidable delays.

Need help with your website?

We’d love to hear from you! Drop us a line below and we’ll do our best to get back to you within one business day.