Aus öffentlichen Paketdaten erstellte Orientierung.
Razorpay Flutter ist ein Plugin, das den Razorpay-Zahlungsgateway in Flutter-Anwendungen integriert und nahtlose In-App-Zahlungen für Android und iOS ermöglicht. Es bietet eine nativeähnliche Checkout-Erfahrung mit Unterstützung für Karten, UPI, Online-Banking, Wallets und mehr. Das Plugin vereinfacht die Zahlungsabwicklung durch sichere Transaktionen und bietet anpassbare UI-Komponenten. Entwickler können Zahlungsabläufe mit minimalem Aufwand mithilfe von einfachen APIs problemlos implementieren.
Anwendungsfälle
In-App-Käufe
E-Commerce-Plattformen
Abonnementabrechnung
Ereignisticketing
Zahlungen für digitale Dienstleistungen
Hauptmerkmale
Sichere Zahlungsabwicklung
Anpassbare Checkout-Oberfläche
Unterstützung mehrerer Zahlungsmethoden
Echtzeit-Statusaktualisierungen für Transaktionen
Einfache Integration in Flutter-Apps
Geeignet für
Mobile E-Commerce-Apps
SaaS-Plattformen
Ereignisverwaltungs-Apps
Freemium-App-Monetarisierung
Online-Kursplattformen
Hinweise
Gültige Razorpay-API-Schlüssel erforderlich
Erforderliche ordnungsgemäße Fehlerbehandlung bei fehlgeschlagenen Transaktionen
Muss den lokalen Zahlungsvorschriften entsprechen
Testen im Sandbox-Modus vor der Produktion
Regelmäßige SDK-Updates für Sicherheitspatches
Original-README
Originaler README-Schnappschuss aus dem verknüpften Quell-Repository. Aktuelle Inhalte finden Sie im Repository.
This flutter plugin is a wrapper around our Android and iOS SDKs.
The following documentation is only focused on the wrapper around our native Android and iOS SDKs. To know more about our SDKs and how to link them within the projects, refer to the following documentation:
Sign up for a Razorpay Account and generate the API Keys from the Razorpay Dashboard. Using the Test keys helps simulate a sandbox environment. No actual monetary transaction happens when using the Test keys. Use Live keys once you have thoroughly tested the application and are ready to go live.
void_handlePaymentSuccess(PaymentSuccessResponse response) {
// Do something when payment succeeds
}
void_handlePaymentError(PaymentFailureResponse response) {
// Do something when payment fails
}
void_handleExternalWallet(ExternalWalletResponse response) {
// Do something when an external wallet was selected
}
To clear event listeners, use the clear method on the Razorpay instance.
post_install do |installer|
installer.pods_project.targets.each do |target|
target.build_configurations.each do |config|
config.build_settings['ENABLE_BITCODE'] = 'NO'
end
end
end
Set config.build_settings['ENABLE_BITCODE'] = 'YES'.
Setting Swift version
Add the following line below config.build_settings['ENABLE_BITCODE'] = 'YES':
config.build_settings['SWIFT_VERSION'] = '5.0'
CocoaPods could not find compatible versions for pod "razorpay_flutter" when running pod install
Specs satisfying the `razorpay_flutter (from
`.symlinks/plugins/razorpay_flutter/ios`)` dependency were found, but they
required a higher minimum deployment target.
This is due to your minimum deployment target being less than iOS 10.0. To change this, open ios/Podfile in your project and add/uncomment this line at the top:
# platform :ios, '9.0'
and change it to
platform :ios, '10.0'
and run pod install again in the ios directory.
iOS build fails with 'razorpay_flutter/razorpay_flutter-Swift.h' file not found
Add use_frameworks! in ios/Podfile and run pod install again in the ios directory.
Gradle build fails with Error: uses-sdk:minSdkVersion 16 cannot be smaller than version 19 declared in library [:razorpay_flutter]
This is due to your Android minimum SDK version being less than 19. To change this, open android/app/build.gradle, find minSdkVersion in defaultConfig and set it to at least 19.
A lot of errors saying xxxx is not defined for the class 'Razorpay'
We export a class Razorpay from package:razorpay_flutter/razorpay_flutter.dart. Check if your code is redeclaring the Razorpay class.
Type 'xxxx' is not a subtype of type 'xxxx' of 'response' in Razorpay.on.<anonymous closure>
[VERBOSE-2:ui_dart_state.cc(148)] UnhandledException: type 'PaymentFailureResponse'is not a subtype of type 'PaymentSuccessResponse' of 'response'
#0Razorpay.on.<anonymous closure> (package:razorpay_flutter/razorpay_flutter.dart:87:14)
#1EventEmitter.emit.<anonymous closure> (package:eventify/src/event_emitter.dart:94:14)
#2List.forEach (dart:core-patch/growable_array.dart:278:8)
#3EventEmitter.emit (package:eventify/src/event_emitter.dart:90:15)
#4Razorpay._handleResult (package:razorpay_flutter/razorpay_flutter.dart:81:19)
#5Razorpay.open (package:razorpay_flutter/razorpay_flutter.dart:49:5)
Class Registrar not found
Please update to version 1.4.0 to fix this issue.
Check the signatures of the callbacks for payment events. They should match the ones described here.
API
Razorpay
open(map<String, dynamic> options)
Open Razorpay Checkout.
The options map has key as a required property. All other properties are optional.
For a complete list of options, please see the Checkout documentation.
on(String eventName, Function listener)
Register event listeners for payment events.
eventName: The name of the event.
listener: The function to be called. The listener should accept a single argument of the following type: