reclaim_flutter_sdk 0.1.1 copy "reclaim_flutter_sdk: ^0.1.1" to clipboard
reclaim_flutter_sdk: ^0.1.1 copied to clipboard

discontinued
PlatformAndroidiOS

Pre-built widgets library to export user's data with provable authenticity using HTTPS & Reclaim Protocol Zero-knowledge proof technology

Reclaim Flutter SDK #

Reclaim Protocol is a secure protocol that allows users to export their data from any website with provable authenticity, using HTTPS and zero-knowledge proof technology. The Reclaim Flutter SDK provides the full power of the Reclaim Protocol in a widget.

[Flutter SDK UI]

Features #

Use this package in your Flutter app to:

  • Show a Reclaim widget that opens a UI equivalent to the Reclaim Protocol App.
  • Ask users to create a verficiation based on a provider created in the Reclaim Developer Tool.
  • Supports pop-ups which allows for OAuth flows like Google login to work.
  • Recieve proofs in your Flutter app and dispatch actions based on them.

Getting started #

  • Get an Application ID from the Reclaim Developer Tool.
  • Create of choose a provider and get its ID from the dev tool.

Usage #

  • Import the Reclaim package:
import 'package:reclaim_flutter_sdk/reclaim_flutter_sdk.dart';
  • Create the verification object from the class ReclaimVerification within your app:
reclaimVerification = ReclaimVerification(
    buildContext: context, // your build context
    appId: 'YOUR_APP_ID', // your application identifier from the dev tool
    providerId: 'aaa47198-2523-40da-b9a9-bfa290730d52', // your provider identifier from the dev tool
    secret: '', // your secret token of your application from the dev tool/
    context: '', // your claim context
    parameters: { /* ... */ }, // parameters to pre-inject in the provider response selections
)
  • Use the constructor withSignature to use your own generated signature and timestamp:
reclaimVerification = ReclaimVerification.withSignature(
    buildContext: context, // your build context
    appId: 'YOUR_APP_ID', // your application identifier from the dev tool
    providerId: 'aaa47198-2523-40da-b9a9-bfa290730d52', // your provider identifier from the dev tool
    signature: '', // { providerId, timestamp } signed using your application secret
    timestamp: 0, // the timestamp from the signature
    context: '', // your claim context
    parameters: { /* ... */ }, // parameters to pre-inject in the provider response selections
)
  • reclaimVerification.startVerification() is an async function that would return the proofs in the form of CreateClaimOutput on success:
class CreateClaimOutput {
  final String identifier;
  final ProviderClaimData claimData;
  final List<String> signatures;
  final List<WitnessData> witnesses;
}
  • Make sure to catch errors and handle them.

  • Check out the Example.

Additional information #

3
likes
120
points
80
downloads

Publisher

verified publisherdev.reclaimprotocol.org

Weekly Downloads

Pre-built widgets library to export user's data with provable authenticity using HTTPS & Reclaim Protocol Zero-knowledge proof technology

Homepage
Repository

Documentation

API reference

License

MIT (license)

Dependencies

crypto, cupertino_icons, device_info_plus, dio, eth_sig_util, flutter, flutter_inappwebview, flutter_svg, fluttertoast, http, json_annotation, native_dio_adapter, path_provider, share_plus, shared_preferences, system_info_plus, url_launcher, uuid, web3dart

More

Packages that depend on reclaim_flutter_sdk