Code Monkey home page Code Monkey logo

enets_demo_android's Introduction

eNETS_Demo_Android

This repository will get you a copy of the project up and running on your local machine for development and testing purposes. Does not show interaction with merchant portal.

See development portal for a complete guide on how to deploy the project on a live system.

Main implementation

1. AndroidManifest.xml

Take note of the additional permissions added.

<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.READ_PHONE_STATE"/>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
<uses-permission
    android:name="android.permission.INTERACT_ACROSS_USERS_FULL"
    android:protectionLevel="normal"/>
<uses-permission android:name="com.nets.netspay.QR_TRANSACTION"/>

2. build.gradle(Module: app)

A few additional dependencies, namely:

implementation 'javax.xml.bind:jaxb-api:2.2.12'        
implementation 'com.android.support:design:26.1.0'
implementation project(':enetslib-release')

3. MainActivity.java

Mainly for the calling of the method from within the additional SDK library. Include the library first.

sendPaymentRequest(String key, String hmac, String txnReq, final PaymentCallback var4, final AppCompatActivity var5)

4. HMAC_Gen.java

Used for generating your HMAC. In actually production environment, the HMAC should be generated on the merchant portal. However, for this sample application, the implementation is shown in the application.

Basic Functionalities

  1. Allows generation of default UAT UMID, Key, Secret Key values.

  2. Allows generation of payload with the previous values and current date_time as merchantTxnRef

  3. Displays generated payload and corresponding HMAC

  4. Allows alteration and editing of the payload

  5. Simulates sending of the payload

Payment Options

1. Debit Payment (Built in)

2. Credit Payment

Use 4111-1111-1111-1111, any future expiry date and and 3 digits security number

3. NETSPAY Option

Requires UAT version of NETSPAY

<uses-permission android:name="com.nets.netspay.QR_TRANSACTION"/> <!-- Ensure you have this permission -->

Built With

enets_demo_android's People

Contributors

loichiilek avatar

Watchers

James Cloos avatar Roshan 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.