FloPayFloPay

Introduction

FloPay documentation covering the REST API, Playground, SDKs, and webhook delivery model.

FloPay

FloPay is a payment orchestration platform. These docs cover the main ways to work with Flo: the REST API, the Playground, the JavaScript and React SDKs, the Node SDK, and the webhook contract clients receive from Flo.

Use Flo when you want a consistent payment surface for checkout, subscriptions, invoices, and webhook-driven automation without coupling your application to a single gateway.

REST API

The Flo REST API is the server-side surface for creating and managing Flo resources directly.

Use it when you want to:

  • create checkout sessions from your backend
  • manage client webhook endpoints and review delivery events
  • build integrations in non-JavaScript stacks
  • work directly with Flo resources outside the SDKs

Open the REST API docs

Playground

The Playground is the fastest way to explore Flo in a hosted environment before wiring up your own frontend or backend.

Use it to:

  • understand the checkout flow end to end
  • see how Flo concepts map to real user journeys
  • validate integration expectations before implementation

Open the Playground

FloPay SDK

The SDK packages are the frontend and Node integration layer for teams that want higher-level primitives on top of the Flo platform.

Packages

The SDK is split into four packages:

PackagePurpose
@flopay/sharedShared types, error classes, constants, and theme definitions
@flopay/jsCore browser SDK -- loads the payment provider, creates elements, confirms payments
@flopay/reactReact bindings -- FloPayCheckout, FloPayProvider, form components, and hooks
@flopay/nodeServer-side SDK -- webhook verification, customer management, and optional session creation

Key Features

  • Provider-agnostic adapter pattern -- swap from Stripe to another provider without changing your integration code
  • REST API and SDK coverage -- integrate through direct API calls, frontend SDKs, or a mixed model
  • Embedded one-shot checkout -- FloPayCheckout creates the session inline and renders the full payment form (cards, Apple Pay, Google Pay, PayPal) in one component, with the full lifecycle handled (tokenize, create intent, confirm, process, 3DS retry)
  • Automatic payment buttons -- FloPayAutomaticPaymentButton wraps saved-payment purchases in the same processing / success / decline modal used by checkout
  • 3D Secure handled automatically -- FloPayCheckout detects 3ds_required responses and triggers the authentication flow transparently
  • PayPal support -- direct PayPal and Stripe-rendered PayPal are routed automatically from the session's gateways map
  • Built-in theming -- three bundled themes (default, flat, night) with customizable CSS variables
  • Lower-level building blocks -- FloPayProvider, SplitCardForm, CheckoutForm, and PayPalButton are exposed for advanced setups that need full control over provider initialization
  • Structured errors -- FloPayError provides typed error categories (validation_error, api_error, network_error, etc.) with factory helpers

How It Works

Your App or Backend
  |
  +--> Flo REST API
  |
  +--> FloPay SDKs
  |       |
  |       +--> FloPayCheckout
  |
  +--> Flo Playground (for exploration and demo flows)
  |
  v
Flo Platform  -->  Gateway Adapters  -->  Payment Gateways
  |
  +--> Webhooks  -->  Your Backend
  1. Choose your surface -- use the REST API, the SDKs, or both
  2. Configure -- set the FloPay environment and your client ID
  3. Render -- drop in <FloPayCheckout createSession={...} /> for the embedded one-shot flow
  4. Pay -- Flo creates the session, initializes the active gateway, and renders the payment form
  5. Complete -- use onComplete on the client and webhooks on the server as needed

FloPay is published to Npm. See the Installation guide for registry setup.

Next Steps

On this page