instamojo_plus 0.0.1 copy "instamojo_plus: ^0.0.1" to clipboard
instamojo_plus: ^0.0.1 copied to clipboard

A Flutter package to integrate Instamojo payment gateway.

๐Ÿช™ Instamojo Flutter

A simple Flutter plugin for integrating Instamojo Payment Gateway in your mobile apps. Supports both Android and iOS, with WebView-based checkout for a smooth in-app payment flow.

๐Ÿš€ Features

๐Ÿ” Secure Instamojo payment gateway integration

๐Ÿ’ณ Accept payments using Instamojo APIs

๐ŸŒ WebView-based hosted payment page

๐Ÿ“ฆ Simple and developer-friendly API

๐Ÿงช Supports Sandbox and Live environments

โš™๏ธ Getting Started

Add dependency

dependencies: instamojo_flutter: path: ../ # or from pub.dev once published

Import the package

import 'package:instamojo_flutter/instamojo_flutter.dart';

Initialize API

final api = InstamojoApi( apiKey: 'YOUR_CLIENT_ID', authToken: 'YOUR_CLIENT_SECRET', isLive: false, // false = Sandbox, true = Production );

๐Ÿ’ก Example Usage final paymentRequest = { "purpose": "Subscription", "amount": "10.0", "buyer_name": "Sujith", "email": "[email protected]", "phone": "7994095833", "redirect_url": "https://www.example.com/redirect/" };

final response = await api.createPaymentRequest(paymentRequest);

if (response['success']) { final longUrl = response['payment_request']['longurl']; Navigator.push( context, MaterialPageRoute( builder: (context) => PaymentScreen( paymentUrl: longUrl, onPaymentSuccess: (data) => print('Payment Success: $data'), onPaymentError: (error) => print('Payment Error: $error'), onPaymentCancel: () => print('Payment Cancelled'), ), ), ); }

1
likes
0
points
12
downloads

Publisher

verified publishersujithdev.live

Weekly Downloads

A Flutter package to integrate Instamojo payment gateway.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

flutter, http, url_launcher, webview_flutter

More

Packages that depend on instamojo_plus