Skip to main content
The zbd_ramp package provides a native Flutter widget for integrating ZBD Ramp into your iOS, Android, and Web applications.

Features

Flutter Optimized

Built specifically for Flutter with native WebView integration

Cross-Platform

Works seamlessly on iOS, Android, and Web

Type Safe

Full Dart type safety with comprehensive type definitions

Real-Time Events

PostMessage communication for error handling, logging, and step tracking

Installation

Add the package to your pubspec.yaml:
Then run:

Quick Start

1. Create Session Token

First, initialize a ramp session from your backend or directly in your Flutter app:

2. Display the Ramp Widget

Add the widget to your Flutter app:

API Reference

initRampSession()

Creates a new session token for the ZBD Ramp widget.

Parameters

Either email OR accessToken must be provided for authentication.

Returns

refreshAccessToken()

Refreshes an expired access token using a refresh token.
Token Lifecycle:
  • Access tokens expire after 30 days
  • Refresh tokens expire after 90 days
  • Both tokens are received via webhook after user completes OTP login with email

Parameters

Returns

Example

ZBDRampWidget

Main Flutter widget that renders the ZBD Ramp interface.

Constructor

RampConfig

Configuration for the widget:

RampCallbacks

Event handlers for widget lifecycle:

Complete Example

Here’s a full implementation with all callbacks:

Error Handling

Handle errors gracefully in your application:

Platform Setup

iOS Configuration

Add the following to your ios/Runner/Info.plist:

Android Configuration

Add permissions to your android/app/src/main/AndroidManifest.xml:

Try the Example App

The quickest way to see the SDK in action:
1

Clone the Repository

2

Install Dependencies

3

Run the Example

4

Test with Your Credentials

  • Enter your ZBD API Key
  • Fill in email and Lightning destination
  • Tap β€œCreate Session & Load Ramp”

Resources

Package on pub.dev

View the official Flutter package

GitHub Repository

View source code and example app

API Reference

Complete API documentation

Webhook Events

Handle webhook notifications

Other SDKs

Core TypeScript/JavaScript package for web applications.View TypeScript SDK β†’

Support

Need help? Create an issue on GitHub or reach out to our support team.