ServeApps/SelfServe/Klaviyo integration

Trigger Klaviyo flows the moment an order can be edited

Connect Klaviyo with one click and SelfServe sends four events as orders are placed, edited and closed. Build the emails and SMS around them in Klaviyo's flow builder. Nothing else to configure.

Powering post-purchase operations for Shopify Plus merchants like

✳✳✳✳✳✳✳✳✳✳✳✳✳✳✳

How it works

The merchant connects once; after that SelfServe talks to Klaviyo on its own.

01

Connect from the Integrations page

In the SelfServe admin, open Integrations, then Manage on the Klaviyo card, then Connect Klaviyo. Klaviyo asks for two permissions: write events, read the account name.

02

Klaviyo sends you straight back

SelfServe exchanges the code for tokens, stores them, and shows the card as Connected to your account, with the four metric names it will send.

03

Events start flowing

As customers place and edit orders, SelfServe pushes the events automatically. Each metric appears in Klaviyo's trigger dropdown after its first event arrives.

04

Build the flows

Pick a SelfServe metric as the trigger in Klaviyo's flow builder and write the email or SMS. Every event carries the order details the message needs.

Leaving is one click too. Disconnect in SelfServe revokes the grant on Klaviyo's side and clears the tokens. Uninstalling the app does the same automatically.

Four events, four moments worth a message

Each one is a Klaviyo metric with the order on it, so a flow can personalise without a lookup.

Edits Allowed

An order is created with an edit window. Fired by the Shopify orders/create webhook handler.

Properties

OrderIdOrderNameShopEditsClosureStrategyEditsAllowedUntilEditsAllowedUntilDisplayItemEditingAllowedUntilAddressEditingAllowedUntil

Flow idea: the order confirmation that says exactly how long the customer has to change their mind.

One Hour Left to Edit

A fixed-deadline edit window has about an hour left. A background scanner checks every ten seconds and fires once per order.

Properties

OrderIdOrderNameShopEditsClosureStrategyEditsAllowedUntilEditsAllowedUntilDisplay

Flow idea: a last-call reminder by email or SMS before the order locks.

Editing Disallowed

The edit window closes for any reason: time ran out, the order was fulfilled, the order was cancelled.

Properties

OrderIdOrderNameShopClosureReason

Flow idea: the "your order is locked and on its way" message, branched on ClosureReason.

Payment Due

An order edit leaves an amount outstanding, so an additional-payment window opens. Fired after the Shopify order edit is committed.

Properties

OrderIdPaymentUrlAmountDueCurrencyPaymentDueAt

Flow idea: a pay-the-difference reminder with the hosted Shopify payment link.

Two permissions, and not one more

SelfServe asks Klaviyo for exactly what the integration needs. It does not read profiles, segments, lists, campaigns, flows, metrics or any other data in your Klaviyo account.

  • events:write. Pushes the four events that drive your flows. This is the whole point of the integration.
  • accounts:read. Reads the account's display name once, so the card can say Connected to your account. No profile, segment or list data is read with it.

Technical reference

For developers and for Klaviyo's review team: what SelfServe calls, with which scope, and how it keeps the connection healthy. Every authenticated call carries the API revision headerrevision: 2026-04-15.

Endpoints and scopes

PurposeEndpointScopeWhen
Push the four lifecycle events to the merchant’s accountPOST /api/events/events:writeOrder created, deadline approaching, window closed, additional payment opened
Show the connected account’s name in SelfServeGET /api/accounts/accounts:readOnce, on OAuth callback success
Exchange the authorization code for tokensPOST /oauth/tokenOAuth, no API scopeOnce, on connect
Refresh the access token (about hourly)POST /oauth/tokenOAuth, no API scopeLazily, checked before each event push
Revoke the grantPOST /oauth/revokeOAuth, no API scopeDisconnect button; app uninstall webhook

Expected responses

EndpointOn successNotes
POST /api/events/202 AcceptedThe primary event-push endpoint, used for all four lifecycle events.
GET /api/accounts/200 OKIf it fails, the integration still connects, just without an account name shown.
POST /oauth/token200 OKUsed for the initial exchange and every refresh.
POST /oauth/revoke200 OKBest effort: a failure never blocks a disconnect or an uninstall.

How the connection stays healthy

  • PKCE and a one-hour state tokenThe OAuth flow uses code_challenge with S256 and a server-side state persisted for one hour and validated on callback.
  • Lazy refreshAccess tokens expire after an hour. SelfServe refreshes before any event push once the token is within 60 seconds of expiry.
  • Rotation persistedKlaviyo issues a new refresh token on every refresh; SelfServe stores the rotated value every time.
  • invalid_grant means disconnectedIf a refresh is refused, all token columns are cleared and the integration shows as disconnected at the next merchant interaction.
  • One retry on a 401A 401 during an event push triggers exactly one forced refresh and retry. A second 401 clears the tokens.
  • Revoke on the way outDisconnect and app uninstall both call /oauth/revoke, then clear the tokens locally. Uninstall never waits for the revoke.
  • No duplicate eventsEvery event carries a deterministic unique_id of the form metric-windowId, so retried webhooks and restarts cannot create duplicates in Klaviyo.
  • Scopes match the runtimeThe two scopes requested at authorize time, events:write and accounts:read, are exactly the two used. No others are requested or used.

Connect Klaviyo in one click

Install SelfServe, open Integrations, connect your account. The four events start the moment the next order comes in.

Merchants say it best.

Read all testimonials →

Reviews from the Shopify App Store, as merchants wrote them.

“Great app with a great team behind it! There was a small bug with the upsell widget and they fixed in 20 minutes. Thanks a lot!”

“SelfServe Order Edits + Upsells does exactly what it promises and does it exceptionally well. It empowers customers to fix their own mistakes, swap variants, and add items post-purchase without creating support tickets or operational chaos.”

“The support helped me out way out of office hours, thanks so much!”

“This app has been a game-changer for our store. One of the biggest pain points we had was customers emailing us to fix small order mistakes such as wrong variant, wrong address, or wanting to add an extra item after checkout. With SelfServe, all of that is now handled automatically without my support team needing to step in. When I needed support, the team had a dedicated group to handle my issue and resolved it very quickly. That gave me extra confidence in using the app long-term. Overall, this app has reduced support tickets, improved customer satisfaction, and added extra sales. Highly recommended!”

“The setup was surprisingly easy, and we had the customer-facing order editing live in under 15 minutes. Now you can swap a medium for a large directly from the order status page without bothering support. It's early days but I think we can cut support tickets easily by 30%.”

“Honestly this app is so good. We used to get SO many emails about wrong adresss or people wanting to change their order. Now they just do it themselves on the order status page and it saved us so much time. The upsell thing is also pretty cool, gotten us a few extra sales. def recommend it.”

“I thought the upsell part was just a gimmick. I got this so customers would stop bugging me to change their address. But I threw a couple of our smaller items up as post-checkout 'add-ons' just to test it... and people are actually buying them! It's wild.”