ime_pay 0.0.6 copy "ime_pay: ^0.0.6" to clipboard
ime_pay: ^0.0.6 copied to clipboard

Flutter plugin to integrate IME Pay in your Android and iOS app.

example/lib/main.dart

import 'package:flutter/material.dart';
import 'package:ime_pay/ime_pay.dart';

void main() {
  runApp(MyApp());
}

class MyApp extends StatefulWidget {
  @override
  _MyAppState createState() => _MyAppState();
}

class _MyAppState extends State<MyApp> {
  @override
  void initState() {
    super.initState();
  }

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Scaffold(
        appBar: AppBar(
          title: const Text('IME PAY example app'),
        ),
        body: Center(
          child: ElevatedButton(
              child: Text('Pay with IME'),
              onPressed: () {
                ImePay imePay = ImePay(
                  merchantCode: 'TEST',
                  module: 'TEST',
                  userName: 'TEST',
                  password: 'TEST',
                  amount: 50.0,
                  merchantName: 'TEST',
                  recordingServiceUrl: 'TEST',
                  deliveryServiceUrl: 'TEST',
                  environment: ImePayEnvironment.TEST,
                  refId: 'TEST',
                );
                imePay.startPayment(onSuccess: (ImePaySuccessResponse data) {
                  print(data);
                }, onFailure: (error) {
                  print(error);
                });
              }),
        ),
      ),
    );
  }
}
8
likes
150
pub points
50%
popularity

Publisher

verified publisherbibek-timsina.com.np

Flutter plugin to integrate IME Pay in your Android and iOS app.

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (LICENSE)

Dependencies

flutter

More

Packages that depend on ime_pay