Card on File Payment
Saving Card for Future Payments via SDKs
If you do not have saved (tokenized) cards for future payments please refer to our guides:
Web
Monri Components
Redirect Integration
Lightbox Integration
Mobile
Payment With Saved Card
Before you continue familiarize yourself with Transaction API.
To execute payment with saved card:
you need to supply
pan_token
instead of a single use token or card number, expiration date, cvvset
moto
totrue
Authorization request example
This JSON is now posted to https://ipgtest.monri.com/v2/transaction
.
Note that pan_token
and moto
values are set.
IMPORTANT
Parametrize https://ipgtest.monri.com
URL, in production mode the subdomain will be different.
If all values pass validations at our side, transaction is send to the bank and response is returned. This response may look like this:
HTTP status code: 201 - Created
HTTP headers: {:connection=>"close", :date=>"Tue, 25 Oct 2011 01:18:37 GMT", :location=>"https://ipgtest.monri.com/transactions/845", :content_type=>"application/json; charset=utf-8", :cache_control=>"no-cache", :x_ua_compatible=>"IE=Edge", :x_runtime=>"1.475305", :transfer_encoding=>"chunked"}
HTTP body:
New transaction is generated - 201 Created HTTP status code, and it's location is set in appropriate HTTP header.
A client then must parse a body from HTTP response and extract all values from that JSON
document.
Transaction is approved only and if only status is set to approved
.
All other fields are standard data carried over payment networks.
If issuer declines a transaction, status flag is set to declined
. In a case of an error, the flag will be set to invalid
.
IMPORTANT
Do not rely on any output variable except status to determine successful of authorization.
Last updated