Skip to main content

Set Up Your Stay Ai Integration

Postscript integrates with Stay Ai, allowing you to share information between the two solutions. Stay Ai is a comprehensive subscription p...

Updated today

Postscript integrates with Stay Ai, allowing you to share information between the two solutions. Stay Ai is a comprehensive subscription platform that allows merchants to acquire subscribers, increase customer lifetime value, and reduce churn. With our Stay Ai integration, merchants can keep subscribers up-to-date on orders via SMS.

In this article, we'll walk you through setting up the integration. We'll also define each available Stay Ai trigger event and guide you through building an automation employing Stay Ai trigger events.

IMPORTANT The Stay Ai integration only works with Postscript’s latest API update. This integration cannot use Legacy Automations, only Automation Flows.

Create a Postscript API Key


  1. Select your Shop Name in the side menu of your Postscript dashboard, then select API.

  2. Select Create Security Key Pair on the right side of the page, then confirm your action by selecting Yes.

  3. Add a label to your API key so you can track where this API key is being used.

  4. Select Show in the Private Key column to reveal your API key. Copy this key or write it down—you'll need to enter it in Stay Ai later.

Configure Postscript in Stay Ai


1. From your Stay Ai merchant portal, select the Settings option on the left-side navigation panel. Then select Integrations.

StayAi1.png

2. Under Postscript, select the + Integrate with Stay Ai button.

3. Enter the Private API key you generated in the previous section of this help article, then select the Validate button to confirm that the authentication is secure.

StayAi2.png

4. If the connection is validated, you will see a green checkmark next to Postscript. Then select the Finish Installation button.

StayAi3.png

Create a Stay Ai-Specific Automation


StayAIAutomation.gif
  1. From your Postscript Dashboard, select Messages; then select Automations.

  2. Select Create Automation in the upper-right corner. Select Create Automation Flow.

  3. Select Create a new automation, then Create flow.

  4. Name your automation. Be sure to use a name that will allow you to easily identify and track this automation in the future.

  5. Select the dropdown menu under Add a subscriber when, then choose your Stay Ai trigger. These will be labeled in the following format: Alloy_Automation - Stay Ai [CUSTOMER EVENT].

  6. Continue customizing your automation flow by dragging and dropping actions into your flow, customizing your message, and adding merge tags.

  7. When you're ready to send your flow, select Schedule or Activate in the top-right corner of the page. You have two options when sending a flow:

    • Activate immediately: This option will immediately begin the flow, allowing subscribers to enter the automation based on the selected properties.

    • Activate at a scheduled time and date: Choose when you'd like the flow to begin, allowing subscribers to enter.

Understanding Stay Ai-Specific Automation Triggers


For an event to initiate an automation in Postscript, real subscriber activity (or test actions) must occur. Below are the trigger events Stay Ai can send to Postscript.

Trigger Name

Definition

A Subscription has started

The subscriber has successfully created a new subscription.

An order is purchased

A subscription order has been processed.

A billing attempt was processed

The order was processed and payment was received.

An order is upcoming

This trigger will notify a subscriber 5 days before an upcoming order is processed.

A subscription order is canceled

The subscriber has successfully canceled their subscription.

A subscription order is paused

The subscriber has successfully paused their subscription.

A subscription order is skipped

The subscriber has successfully skipped their upcoming subscription order.

A billing attempt is failed

The subscriber’s card on file was declined.

An item is out of stock

The product the customer is subscribed to is currently out of stock.

When customizing the messages sent after an event is triggered, merchants can add the following variables to include dynamic information from the subscriber's profile.

Variable

Definition

city

City on Customer's shipping address

country

Country on Customer's shipping address

createdAt

Date the subscription was created

discountedPrice

Price on subscription including the discount

email

Email on the subscription

firstName

First Name of Customer

lastName

Last Name of Customer

loginLink

magic link for the customer portal

nextBillingDate

Next scheduled billing date for the subscription

orderId

Shopify Order ID

orderIntervalFrequency

Amount of time in between shipments

orderIntervalUnit

Unit of time in between shipments (weeks, months, years)

orderNumber

Order cycle number for the. upcoming shipment on the subscription

phone

Phone number for the Customer

price

Price of the subscription

province

Province (if applicable) on the Customer's shipping address

stayActiveSubscriber

Pulls in Yes or No value for active subscribers

stayActiveSubscriptionCount

Amount of active subscriptions for the customer

stayActiveSubscriptionVariantIds

Pulls in Variant IDs on the Subscription

stayActiveSubscriptionChargeCount

Amount of charges for the subscriber on Stay

stayCancelledSubscriptionCount

Amount of cancelled subscriptions for the customer

stayExternalCustomerId

Customer ID on Stay

stayFirstChargeProcessedAt

Date of first subscription charge on Stay

stayOrderId

Order ID on Stay

staySubscriptionId

Subscription ID on Stay

staySubscriptions

Pulls the product names on the subscription

subscriptionContractID

Contract ID on Stay

NOTE: StayAI does not backfill data proactively, but it is available for subscribers after a trigger event occurs.

Get Support


Have questions? Please feel free to reach out to our wonderful Support team at [email protected] or via live chat. You can also submit a support request here!

Need ongoing channel strategy guidance? Please fill out this form and we'll connect you to one of our certified partners.

Did this answer your question?