Skip to main content
@the-meridian/sdk is the package you install inside your own Shopify app. It is the runtime half of Meridian: you design plans, features and automations in the dashboard, and the SDK applies them in your app’s code.
react and react-dom (>= 18) are peer dependencies, and the package needs Node 18 or newer. It ships ESM and CJS with types.

What it gives you

You never implement Shopify’s recurring-charge or usage-charge APIs yourself. Meridian holds the billing handshake, and the SDK is the thin layer your app calls.
The billing half of that list (subscribe, cancel, raise cap, and usage overage charges) requires your app to be hosted on Meridian. Everything else works wherever your app runs. What needs Meridian hosting draws the line precisely; read it before you plan an integration.

Two entry points

@the-meridian/sdk

The React surface, for the browser: the provider, the useMeridian hook, and the two page components.

@the-meridian/sdk/server

The server surface, for Node: the app factory, the server and admin clients, webhook verification, and the referral helpers. No React.
The split is a security boundary: your app’s secret API key is only ever read by the server entry. See Credentials.

The shape of an integration

  1. Your server holds MERIDIAN_APP_ID and MERIDIAN_API_KEY.
  2. In your Shopify afterAuth hook, one call registers webhooks, fires your install automations, reports the shop’s subscriptions (trials included) and attributes any affiliate referral.
  3. In the loader for your app shell, you exchange the shop for a short-lived shop token.
  4. In the browser, you mount the provider with that token. Everything below it can gate features, read usage, and drive billing.
Quickstart walks through all four with the code.
The SDK is not the only way in: the Meridian MCP server exposes your Meridian workspace to an AI agent, and the CLI handles local development and managed developer databases.
Last modified on September 28, 2026