alsaqi_payment_sdk 1.0.5
alsaqi_payment_sdk: ^1.0.5 copied to clipboard
Production-ready Payment Gateway SDK for Flutter. Supports card payments, tokenization, and payment status queries with strong security practices.
Al-Saqi Payment SDK for Flutter #
Hosted purchase integration for Flutter merchants.
This SDK README covers the hosted checkout flow only. Direct card entry is intentionally out of scope here.
Requirements #
- Flutter 3.10+
- Dart 3+
- Android host app must include internet permission
Installation #
dependencies:
alsaqi_payment_sdk: ^1.0.5
Or consume this package through the Git repository:
dependencies:
alsaqi_payment_sdk:
git:
url: https://gitlab.secnode.app/al-saqi-payment-gateway/sdks/pg-flutter-sdk.git
ref: main
path: alsaqi_payment_sdk
Android Manifest #
<uses-permission android:name="android.permission.INTERNET" />
Initialization #
import 'package:alsaqi_payment_sdk/alsaqi_payment_sdk.dart';
import 'package:flutter/widgets.dart';
void main() {
WidgetsFlutterBinding.ensureInitialized();
PaymentSDK.initialize(
apiKey: 'YOUR_API_KEY',
environment: Environment.sandbox,
clientId: 'YOUR_CLIENT_ID',
secretKey: 'YOUR_SECRET_KEY',
logLevel: LogLevel.debug,
language: 'en',
theme: PaymentTheme.defaults,
darkTheme: PaymentTheme.dark,
);
runApp(const MyApp());
}
Hosted Payment Sheet #
await PaymentSDK.presentPaymentSheet(
context: context,
amount: 75000,
currency: 'IQD',
requestId: 'REQ-10001',
invoiceId: 'INV-10001',
onResult: (result) {
if (result.success) {
print('Approved: ${result.transactionId}');
} else {
print('Failed: ${result.message}');
}
},
);
Full Payment Page #
await PaymentSDK.pushPaymentPage(
context: context,
amount: 75000,
currency: 'IQD',
requestId: 'REQ-10001',
invoiceId: 'INV-10001',
onResult: (result) {
if (result.success) {
print('Approved: ${result.transactionId}');
} else {
print('Failed: ${result.message}');
}
},
);
Result Fields #
successtransactionIdrequestIdinvoiceIdrrnresponseCodemessagestatus
Support #
Merchant support and SDK questions: sdk@alsaqi.io