# Integrating to Shopify

You can use Zapier to integrate directly into your Shopify site, so that you can add it as a Product in your site, and attach recurring subscription payments via plugins like Recharge.

This guide will show you how to set this up, assuming you have a Shopify account and the Recharge Shopify App.

## Provision users when customers buy your customers

First create a new Zap, and in the trigger section find the ReCharge Zapier Integration. From the trigger events, select the New Subscription event and then connect to your account.

<figure><img src="https://604798110-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fr9bdlQGFzhny8zWPvxIn%2Fuploads%2Fg618VZwOqr52QIKdjZSD%2Fimage.png?alt=media&#x26;token=c561c734-0f58-478a-8822-6a8fbacdf3b3" alt=""><figcaption></figcaption></figure>

For the Action, select Smorg and select Provision a new user.

<figure><img src="https://604798110-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fr9bdlQGFzhny8zWPvxIn%2Fuploads%2Fy72at1RBZ4LjQ57eSYe6%2Fimage.png?alt=media&#x26;token=1f06ebf8-9740-442c-82fe-ae9512dbf8e6" alt=""><figcaption></figcaption></figure>

You can then configure this action by filling in the information in the configuration screen:

* You should already have the Space ID from your Studio account
* For the other fields apart from password, use the "/" key to map the appropriate fields from the Recharge trigger.&#x20;
* For the Correlated User ID, map the email address
* For the password field, set a default password that will be used for all your customers, and in the communication to your customer you can advise them to change it once they have logged in.
* IMPORTANT - for the subscription expiry date, pick a date way in future e.g. 1st Jan 2100 so that your customers are always subscribed until they cancel.

<figure><img src="https://604798110-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fr9bdlQGFzhny8zWPvxIn%2Fuploads%2Fypw7n3gCvFA0GDhYQe8p%2Fimage.png?alt=media&#x26;token=3667dd8e-24e4-43c1-bed1-43f4eda92136" alt=""><figcaption></figcaption></figure>

## Handle subscription cancellations

You'll also need to create a new Zap to handle member cancellations. In this case, choose the Recharge Zapier Trigger and choose New Cancelled Subscription

<figure><img src="https://604798110-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fr9bdlQGFzhny8zWPvxIn%2Fuploads%2FMeoy0bThe72WXbL3WBWI%2Fimage.png?alt=media&#x26;token=1de291a2-3e37-4a19-841f-e06fdbf2e076" alt=""><figcaption></figcaption></figure>

The Smorg Zapier action you would the configure would be the "Change user subscription expiration"

<figure><img src="https://604798110-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fr9bdlQGFzhny8zWPvxIn%2Fuploads%2F4SXtVB9KC54laKTzgDT0%2Fimage.png?alt=media&#x26;token=ff15b605-fed8-4303-b9a3-96b0cc2d39c3" alt=""><figcaption></figcaption></figure>

You can then go ahead and configure this action by mapping (using "/"), the expiration date to the cancellation date as provided by the Recharge Zapier trigger in the previous step.

You can also create a further Zapier action to send an email to your customers relating to the cancellation. FInd out how to do this by following the steps in this guide [using-zapier-to-send-welcome-emails](https://help.mealiq.io/integrations/using-zapier-to-send-welcome-emails "mention")and follow from Step 10 onwards.

## Send an email to your new customers

Follow this guide [using-zapier-to-send-welcome-emails](https://help.mealiq.io/integrations/using-zapier-to-send-welcome-emails "mention")to automate the sending of emails to your customers.
