Add myket in app purchase
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

22 regels
560 B

  1. import 'dart:async';
  2. import 'dart:convert';
  3. import 'package:flutter/services.dart';
  4. class Myketpayment {
  5. static const MethodChannel _channel = const MethodChannel('myketpayment');
  6. static Future<bool> setup(String rsa) async {
  7. final bool version = await _channel.invokeMethod('setup', {"rsa": rsa});
  8. return version;
  9. }
  10. static Future<Map> buy({String sku, bool consume = false, String payload = ""}) async {
  11. Map result = await _channel.invokeMethod('buy', {"sku": sku, "payload": payload, "consume": consume});
  12. return result;
  13. }
  14. }