Coder Social home page Coder Social logo

ionic-monri-android-ios's Introduction

ionic-monri-android-ios

Encapsulated Monri's Android and SDK payment features

Installation

Clone project in the same tree view as your project. In package.json add

{
  "dependencies": {
    "ionic-monri-android-ios": "file:../ionic-monri-android-ios"
  }
}
npm install
npx cap sync

Usage

import {IonicMonri} from '../../../../ionic-monri-android-ios';

// ...
//new card
const result = await IonicMonri.confirmPayment({
        options: {
            authenticityToken: '6a13d79bde8da9320e88923cb3472fb638619ccb',
            developmentMode: true,
        },
        params: {
            clientSecret: "client_secret", // create one on your backend
            card: {
                pan: '4111 1111 1111 1111',
                cvv: '123',
                expiryMonth: 12,
                expiryYear: 2032,
                saveCard: true
            },
            transaction: {
                email: '[email protected]',
                orderInfo: 'Ionic monri order info',
                phone: '061123213',
                city: 'Sarajevo',
                country: 'BA',
                address: 'Ferhadija',
                fullName: 'Ionic Monri Example',
                zip: '71210',
            },
        }
    }
);

//saved card
const result = await IonicMonri.confirmPayment({
        options: {
            authenticityToken: '6a13d79bde8da9320e88923cb3472fb638619ccb',
            developmentMode: true,
        },
        params: {
            clientSecret: "client_secret", // create one on your backend
            savedCard: {
                panToken: 'd5719409d1b8eb92adae0feccd2964b805f93ae3936fdd9d8fc01a800d094584', //retrive one via API
                cvv: '123',//allow the user to enter cvv..
            },
            transaction: {
                email: '[email protected]',
                orderInfo: 'Ionic monri order info saved card no 3DS',
                phone: '061123213',
                city: 'Sarajevo',
                country: 'BA',
                address: 'Ferhadija',
                fullName: 'Ionic Monri Example',
                zip: '71210',
            },
        }
    }
);

Contributing

See the contributing guide to learn how to contribute to the repository and the development workflow.

License

MIT

ionic-monri-android-ios's People

Contributors

adnanomerovic avatar jasminsuljic avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.