Skip to main content

Stay AI Subscriptions Integration

Connect Stay AI to Mage so subscribers can redeem points for discounts on their renewals and earn bonus points at subscription milestones.

Written by Kris James

Connect your Stay AI subscriptions account to Mage to reward your subscribers. This integration lets customers exchange their points for discounts on their subscription renewals, and lets you award bonus points when subscribers reach renewal milestones.

Before you start

You need:

  • Stay AI installed and active on your Shopify store with Admin access to the dashboard.

  • A Mage Starter plan or above

1. Create an API key in Stay AI

  1. Log in to your Stay AI dashboard.

  2. Go to Account, then API Tokens.

  3. Click New API Key.

  4. Give it a name like Mage Loyalty.

  5. Select the following permissions. This step is important. Without them, the integration will not work: Read Subscriptions, Write Subscriptions, Read Webhooks, Update Webhooks, and Delete Webhooks.

  6. Create the key and copy it. You will paste this into Mage in the next step.

2. Connect Stay AI to Mage

  1. Go to the Integrations page in your Mage admin.

  2. Find the Stay card and click Manage.

  3. Paste your Stay API key into the field.

  4. Click Connect Stay. Mage will validate the key and save it once it is verified.

You should now see the Stay card showing as Connected. If you see an error, double-check that you copied the full key and that the permissions above are enabled in Stay.

3. Reward your Stay AI subscribers

With Stay connected, you can reward your subscribers in two ways:

Set up the Flexible Redemption block

The Stay integration powers the Apply to subscription button on the Flexible Redemption block. This lets customers exchange their points for a custom-value discount and apply it directly to one of their subscriptions, instead of using it as a one-time code at checkout.

  1. Open the Flexible Redemption block in your theme editor or Mage admin.

  2. Turn on "Show apply to subscription".

  3. Check your flexible reward's purchase type. It must be set to Subscription or Both. A one-time reward cannot be applied to a subscription, so the Apply button will stay hidden if the reward is set to One-time only.

  4. Save.

What customers see

When a signed-in customer with an active Stay subscription opens the Flexible Redemption block:

  • They use the slider to choose how many points to exchange.

  • They can click Redeem for a one-time discount code at checkout, or Apply to subscription to add the discount to a subscription renewal.

  • When they click Apply to subscription, a dialog opens showing their active Stay subscriptions. They pick one, confirm, and Mage applies the discount automatically to the next renewal.

If a customer does not have any active subscriptions, the dialog will let them know there is nothing to apply the discount to.

How the discount respects your reward settings

The discount that lands on the subscription follows everything you configured on the flexible reward. That includes:

  • Minimum spend

  • How many renewals the discount runs for, such as the next payment only, the next three, or all renewals

  • Product or collection restrictions

  • Discount combinations

So if you set your reward to "Limit discount to the first payment", customers who apply it to a subscription will only see the discount on their next renewal.

Reward subscription milestones

The subscription milestone earning rule awards bonus points when a customer reaches a chosen number of completed subscription orders. With Stay connected, the rule fires automatically the moment one of your Stay subscribers hits the threshold you configured.

  1. Go to Earning Rules in your Mage admin.

  2. Add or edit the Subscription Milestone rule.

  3. Set the renewal threshold (for example, 3 completed orders) and the points to award.

  4. Make sure the rule is Active and save.

How the count works. The milestone fires on the exact renewal that brings them to your threshold, and customers who were already past the threshold when you turned the rule on are not retro-awarded.

Disconnecting Stay AI

  1. Go to the Integrations page.

  2. Find the Stay card and click Manage.

  3. Click Disconnect and confirm.

Discounts that have already been applied to subscriptions stay in place and Stay will keep honouring them at renewal. Future customer point exchanges to subscriptions and subscription milestone awards are blocked until you reconnect.

Frequently asked questions

Which subscriptions can my customers apply discounts to?

Any of their active Stay subscriptions. When a signed-in customer opens the Flexible Redemption block and chooses Apply to subscription, Mage shows their active subscriptions and they pick the one to discount.

Do subscription milestones count orders from before I turned the rule on?

No. The milestone fires on the renewal that brings a customer to your exact threshold. Customers who were already past the threshold when you switched the rule on are not awarded retroactively. New subscribers, and existing subscribers who have not yet reached the threshold, are awarded when they reach it.

Why do my customers not see the "Apply to subscription" button?

Check that the Stay card shows as Connected, that the Flexible Redemption block has "Show apply to subscription" turned on, that your flexible reward's purchase type is Subscription or Both (not One-time), and that the customer is signed in and has an active Stay subscription.

What plan do I need?

A Mage Starter plan or above.

What happens to existing discounts if I disconnect Stay?

Discounts already applied to subscriptions stay in place and Stay keeps honouring them at renewal. Disconnecting only stops new point-to-subscription discounts and new milestone awards until you reconnect.

Did this answer your question?