Last updated:
0 purchases
sbp payments
sbp_payments #
Flutter plugin which helps to handle sbp payment links and open it with specific bank app.
Supports iOS and Android
Usage #
To use this plugin, add sbp_payments as a dependency in your pubspec.yaml file.
Installation #
iOS #
Add URL schemes as LSApplicationQueriesSchemes entries in your Info.plist file:
<key>LSApplicationQueriesSchemes</key>
<array>
<string>bank100000000000</string>
<string>bank100000000001</string>
...
<string>bank100000000999</string>
<string>bank100000001000</string>
</array>
copied to clipboard
That's need for UIApplication.shared.canOpenURL method worked correctly. You can copy and paste all lines from example.
See -[UIApplication canOpenURL:] for more details.
Example #
import 'package:flutter/material.dart';
import 'package:sbp_payments/sbp_payments.dart';
final _sbpLinkExample =
'https://qr.nspk.ru/AS100001ORTF4GAF80KPJ53K186D9A3G?type=01&bank=100000000007&crc=0C8A';
void main() => runApp(
const MaterialApp(
home: Material(
child: Center(
child: RaisedButton(
onPressed: _showBanks,
child: Text('Show SBP widget'),
),
),
),
),
);
void _showBanks() async => await SbpPayments.showBanks(_sbpLinkExample);
copied to clipboard
For personal and professional use. You cannot resell or redistribute these repositories in their original state.
There are no reviews.