Docs How to integrate

How to integrate with Mantle

Mantle relies on connected platform APIs and its own API for bi-directional data synchronization between your app, those connected platforms and Mantle.

The Mantle API allows you to fetch data, perform actions from your app’s backend and update Mantle, which can proxy those actions to various platforms such as Shopify or Stripe.

The functionality currently offered to enable customer-related operations through the Mantle API include:

  • Retrieving customer information.
  • Subscribing a customer to a new plan, or cancelling an active subscription.
  • Logging usage events to track feature adoption or to create usage charges.

Mantle offers an adaptable integration process. It allows you to decide whether you want to use its complete functionality or just specific features tailored to your needs.

Mantle provides two different APIs:

  • Core API: At time of writing, the Core API is used to identify a customer to Mantle. It will associate a merchant/user with a unique Mantle customer and store important data like platform-specific access tokens. This is required to make authenticated requests on behalf of your customer, while ensuring the secrecy of the customer’s private data. In the future, the Core API will also enable developers with access a broader part of the Mantle platform. Scoped to individual apps.

  • Surface API: Enables you to execute actions from the Mantle admin, log data to Mantle, and surface data to your customers. Data such as the user’s active subscription, billing history, feature entitlements and plans they’re eligible to select. Scoped to individual customers.

A full implementation can be found in our example app.