How to Make the Most of Shopify's New Price Rules API

Price Rules API: 2017

Sales, discounts, and special pricing can be a strong incentive to shop. Have you ever bought something because of a special offer, or made most of your purchases in one place because of loyalty reward discounts? I think it’s safe to assume that most of us have.

But you don’t even have to assume: Daria Kourilina — Shopify’s Product Manager for discounts — shared at Shopify’s Unite conference that almost one in five sales completed online last year, were completed using a discount code. In addition, merchants with an active discount code were eight times more likely to make a sale.

Given that discount codes are such a powerful incentive for shopping, upsells, customer loyalty and more, we’ve officially launched our Price Rules API to give app developers who create marketing, sales, and loyalty program apps the extra fire power needed to help merchants succeed.

Previously, we offered a Discounts API to only Shopify Plus merchant with app integrations, but the new Price Rules API is available to all Shopify app developers. We’ve taken the best parts of the old Discounts API (now sunsetted) and added new and flexible pricing rules to better suit different business types and app objectives.

This article will cover the new types of pricing rules you can implement, as well as demonstrate some of the ways the Price Rules API can be used in an app.

Price Rules API

New types of pricing rules you can implement

Unlike the old API, you’re no longer limited to simple percentage based (e.g. 15 percent off your order) or fixed amount discounts (e.g. $10 off a purchase of $50 or more). There’s also more flexibility in setting rules around purchase criteria for free shipping.

The original features of the Discounts API have been transferred over, and include:

  • Fixed percentage discount
  • Fixed dollar amount discount
  • Free shipping
  • Discount code creation

Now, you have the added ability to create new and more sophisticated discounts. Some of the great new ways you can use the Price Rules API include:

  • Developing apps that allow merchants to apply specific discounts to selected groupings (e.g. multiple products, multiple collections, and customer groups).
  • Combining these conditions to create certain discounts (e.g. free shipping and a minimum order amount, or a certain percentage off for new customers only).
  • Providing one free shipping code that can be used internationally, instead of individual codes for each country.

To help provide further flexibility in creating discounting apps, this API also lets you play in:

  • Percentages
  • Dollar amounts
  • Conditions for free shipping
  • Discounts associated with a minimum set of cart items

With all this flexibility in creation, you can find the optimal discount model for any business type.

As well, when merchants distribute discount codes across various channels, such as email and social media, reports can be generated and served to merchants directly within the Shopify Admin. This feature will help show the value your discount app provides, while delivering a seamless experience within Shopify.

You might also like: How to Get the Most Out of Shopify’s New Design System Polaris.

Some ways the Price Rules API can be used in an app

You can use the Price Rules API to build a stand-alone discount app, or to integrate discounts as part of a function in a current or new app that helps generate sales or retain customers. Below are some examples of how our launch partners have used the API, as well as some suggested categories for application.

Use in a loyalty app

A loyal customer who’s recognized and rewarded is a customer who’s more willing to stick around. With this API enabling you to target specific purchase conditions to specific customer groups, you can give frequent shoppers and VIP buyers the special treatment.

With this API enabling you to target specific purchase conditions to specific customer groups, you can give frequent shoppers and VIP buyers the special treatment.

In building loyalty with new customers and priority groups, you can also create specific new customer codes, student discounts codes, or any other group codes you desire. For example, there may be a new mom buying a onesie from a merchant, and they want to provide discounts on other infant essentials. You can now make that happen!

One example of a loyalty app that’s already enabled this new API, is Smile.io. As seen below, they give recommended discounts to help make rewarding loyal customers easy.

Price Rules API: Smile.io

Use in an email marketing app

Email marketing is a tried and true tactic for driving sales. Along with this tactic, however, is a common expectation that merchant emails will contain discounts and special offers. Especially for merchants who use emails as their primary marketing strategy, it’s important to switch-up the discounts provided, so that customer don’t get email fatigue.

Especially for merchants who use emails as their primary marketing strategy, it’s important to switch-up the discounts provided, so that customer don’t get email fatigue.

Knowing that UI is important, the Shopify app eCommerce Email Marketing by Soundest makes it easy for merchants to add discount codes to emails. Along with their simple drag and drop layout, they make setting conditions — like type of discount, expiry date, and maximum number of redemptions — straightforward for merchants to do on their own.

Price Rules API: Marketing App

Use in a upsell app

Repeat purchasers are always better than one-time shoppers. In addition to the current strategies merchants employ, such as showcasing complementary items, announcing new stock, or including reminders to reorder, you can now further tempt a merchant’s customers to check-out by including special discounts as part of an upsell.

You can now further tempt a merchant’s customers to check-out by including special discounts as part of an upsell.

Marketing dashboard app Conversio, which helps merchants send upsell promotion receipts following a purchase, now lets merchants add various discounts directly onto the order receipt, including discounts on similar products, and discounts for referring a friend.

Price Rules API: Upsell App

Use in an inventory management app

As part of the reporting capabilities of this API, you can now see how discount codes are applied at an item level. This can help show which items are redeemed most frequently when a discount code is provided. This helps merchants understand what merchandise is priced too steeply and would sell better if the sticker price was reduced.

In addition, if there’s an item piling up in the stock room and merchants need to reduce the inventory level, quantity discounts can be a great way to promote sales and reduce stock.

We currently don’t have an example of how this has been implemented, meaning this opportunity is ripe for the picking!

You might also like: Learn to Build Apps for In-Person Sales Using Shopify's POS App SDK.

Take a spin on the Price Rules API today!

With all the new capabilities and flexibility to build, helping merchants provide sophisticated discounts is easier than ever. The Price Rules API and all its documents are ready and open for access.

In the words of Alexandra Edelstein, developer at Klaviyo:

“Our team was able to easily extend Shopify’s existing python API and build new pyactiveresources for the Price Rule API endpoints. As a Shopify Partner, it was important for us to bring the benefits of the new API to our customers as quickly as possible, and we’re delighted to find the API so easy to use!”

Price Rules API

What new discount types are you most excited for? Tell us about it in the comments below.

Grow your business with the Shopify Partner Program

Learn more