Giter VIP home page Giter VIP logo

monri-android's Introduction

monri-android

Our Android libraries let you easily accept mobile payments and manage customer information inside any Android app.

Monri has created a Java library for Android, allowing you to easily submit payments from an Android app. With our mobile library, we address PCI compliance by eliminating the need to send card data directly to your server. Instead, our libraries send the card data directly to our servers, where we can convert them to tokens.

Your app will receive the token back, and can then send the token to an endpoint on your server, where it can be used to process a payment.

We support Android 4.4 (API level 19) and above.

Installation

Installing the Monri Android library is simple using Android Studio and IntelliJ. You don’t need to clone a repo or download any files. Just add the following to your project’s build.gradle file, inside the dependencies section.

implementation 'com.monri:monri-android:2.1.+'

Proguard rules

Add:

-keep public class com.monri.** {
  public protected private *;
}

-keep public enum com.monri.** {
  *;
}

to proguard-rules.pro

Payment API Integration

At some point in the flow of your app you'll obtain payment details from the user. After that you could:

  • use obtained payment details and proceed with charge (confirmPayment)
  • or tokenize obtained payment details for server side usage

In Payment API Integration it's explained how to:

  • create payment
  • collect payment details
  • confirm payment
  • get results back on your app and on your backend

If you want to tokenize obtained payment details then continue to the "Tokens API Integration"

Tokens API Integration

After you've obtained payment details it's easy to securely transfer collected data via Tokens API.

In Tokens API Integration it's explained how to:

  • create token request
  • create token
  • how to use created token for transaction authorization on your backend

Questions

If you have any questions about documentation/APIs/flow do not hesitate to contact us at [email protected]

monri-android's People

Contributors

adnanomerovic avatar jasmind-monri avatar jasminsuljic avatar vmedved-asee avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

monri-android's Issues

Application crashes when user enter expiration month bigger then 12 (CardMultilineWidget)

E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.monri.android.example, PID: 22328
java.lang.UnsupportedOperationException: Failed to resolve attribute at index 4: TypedValue{t=0x2/d=0x1010099 a=1}
at android.content.res.TypedArray.getColor(TypedArray.java:477)
at android.widget.TextView.readTextAppearance(TextView.java:3896)
at android.widget.TextView.(TextView.java:1240)
at android.widget.TextView.(TextView.java:1129)
at androidx.appcompat.widget.AppCompatTextView.(AppCompatTextView.java:99)
at androidx.appcompat.widget.AppCompatTextView.(AppCompatTextView.java:95)
at androidx.appcompat.widget.AppCompatTextView.(AppCompatTextView.java:91)
at com.google.android.material.textfield.IndicatorViewController.setErrorEnabled(IndicatorViewController.java:422)
at com.google.android.material.textfield.TextInputLayout.setErrorEnabled(TextInputLayout.java:938)
at com.google.android.material.textfield.TextInputLayout.setError(TextInputLayout.java:1055)
at com.monri.android.view.ErrorListener.displayErrorMessage(ErrorListener.java:21)
at com.monri.android.view.MonriEditText.setShouldShowError(MonriEditText.java:164)
at com.monri.android.view.ExpiryDateEditText$1.afterTextChanged(ExpiryDateEditText.java:192)
at android.widget.TextView.sendAfterTextChanged(TextView.java:11003)
at android.widget.TextView.setText(TextView.java:6403)
at android.widget.TextView.setText(TextView.java:6197)
at android.widget.EditText.setText(EditText.java:146)
at android.widget.TextView.setText(TextView.java:6154)
at com.monri.android.view.ExpiryDateEditText$1.onTextChanged(ExpiryDateEditText.java:159)
at android.widget.TextView.sendOnTextChanged(TextView.java:10972)
at android.widget.TextView.handleTextChanged(TextView.java:11084)
at android.widget.TextView$ChangeWatcher.onTextChanged(TextView.java:14157)
at android.text.SpannableStringBuilder.sendTextChanged(SpannableStringBuilder.java:1263)
at android.text.SpannableStringBuilder.replace(SpannableStringBuilder.java:575)
at android.text.SpannableStringBuilder.replace(SpannableStringBuilder.java:506)
at android.text.SpannableStringBuilder.replace(SpannableStringBuilder.java:36)
at android.view.inputmethod.BaseInputConnection.replaceText(BaseInputConnection.java:849)
at android.view.inputmethod.BaseInputConnection.commitText(BaseInputConnection.java:199)
at com.android.internal.widget.EditableInputConnection.commitText(EditableInputConnection.java:183)
at android.view.inputmethod.InputConnectionWrapper.commitText(InputConnectionWrapper.java:169)
at com.android.internal.view.IInputConnectionWrapper.executeMessage(IInputConnectionWrapper.java:341)
at com.android.internal.view.IInputConnectionWrapper$MyHandler.handleMessage(IInputConnectionWrapper.java:85)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loop(Looper.java:214)
at android.app.ActivityThread.main(ActivityThread.java:7050)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:494)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:965)

MonriLoggerImpl.java:10 index out of bounds exception

com.monri.android.logger.MonriLoggerImpl. (MonriLoggerImpl.java:10)
com.monri.android.logger.MonriLoggerFactory.get (MonriLoggerFactory.java:2)
com.monri.android.flows.ActivityActionRequiredFlow. (ActivityActionRequiredFlow.java:12)

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.