Phriction DatingVIP Public Payment Application Project API Documentation transaction.create History Version 2 vs 14
Version 2 vs 14
Version 2 vs 14
Content Changes
Content Changes
== transaction.create ==
Note: command is available on staging env only for now. It is supported by RocketGate and Argus processors only.
==== Description ====
Initialize and finish transaction in one command
==== Input Parameters ====
<table>
<tr><th>Name</th><th>Type</th><th>Required</th><th>Description</th></tr>
<tr><td>pp_type</td><td>(string)</td><td>yes</td><td>Payment processor type</td></tr>
<tr><td>tracking_order</td><td>(int)</td><td>no</td><td>Order ID to be tracked on client app.</td></tr>
<tr><td>tracking_user</td><td>(int)</td><td>yes</td><td>User ID to be tracked on client app.</td></tr>
<tr><td>tracking_tag</td><td>(int)</td><td>yes</td><td>Tag ID to be tracked on client app.</td></tr>
<tr><td>first_name</td><td>(string)</td><td>yes</td><td>First Name</td></tr>
<tr><td>last_name</td><td>(string)</td><td>yes</td><td>Last Name</td></tr>
<tr><td>zipcode</td><td>(string)</td><td>yes</td><td>User ZIP code</td></tr>
<tr><td>country</td><td>(string)</td><td>yes</td><td>Country abbr.</td></tr>
<tr><td>email</td><td>(string)</td><td>yes</td><td>User email address</td></tr>
<tr><td>ip</td><td>(string)</td><td>yes</td><td>IP address from which user is making the transaction</td></tr>
<tr><td>host</td><td>(string)</td><td>yes</td><td>Host form which user is making the transaction</td></tr>
<tr><td>currency</td><td>(string)</td><td>yes</td><td>Currency abbr.</td></tr>
<tr><td>order_type</td><td>(string)</td><td>no</td><td>Allowed values '' (empty string) and `xsale`. Determine if order is Cross Sale or not.</td></tr>
<tr><td>initial_order_hash</td><td>(string)</td><td>no</td><td>Use only in case of order_type = 'xsale'. Put hash from transation.init response of initial/basic order</td></tr>
<tr><td>return_url</td><td>(string)</td><td>no</td><td>Return URL (used for PayPal like PP's)</td></tr>
<tr><td>cancel_url</td><td>(string)</td><td>no</td><td>Cancel URL (used for PayPal like PP's)</td></tr>
<tr><td>items</td><td>(array)</td><td>yes</td><td>Array of items</td></tr>
<tr><td>pp_config</td><td>(array)</td><td>no</td><td>Merchand data params to override</td></tr>
<tr><td>card_number</td><td>(string)</td><td>yes</td><td>Credit Card Number</td></tr>
<tr><td>transaction_id</td><td>(string)</td><td>no</td><td>Can be used instead of Credit Card for repeated billing transactions</td></tr>
<tr><td>card_cvv2</td><td>(string)</td><td>yes</td><td>Credit Card CVV2</td></tr>
<tr><td>card_expire</td><td>(string)</td><td>yes</td><td>Credit Card Expiration date</td></tr>
<tr><td>xsale-descriptor</td><td>(string)</td><td>no</td><td>Force descriptor value (XS only)</td></tr>
<tr><td>step_down</td><td>(int)</td><td>no</td><td>Force step down procedure (start immediately with stepped down price)</td></tr>
</table>
items
<table>
<tr><th>Name</th><th>Type</th><th>Required</th><th>Description</th></tr>
<tr><td>trial_amount</td><td>float</td><td>no</td><td>Trial Amount</td></tr>
<tr><td>trial_unit</td><td>string (day|week|month|year)</td><td>no</td><td>Trial unit</td></tr>
<tr><td>trial_period</td><td>int</td><td>no</td><td>Trial period</td></tr>
<tr><td>amount</td><td>float</td><td>yes</td><td>rebill amount</td></tr>
<tr><td>rebill_unit</td><td>string (day|week|month|year)</td><td>yes</td><td>rebill unit</td></tr>
<tr><td>rebill_period</td><td>int</td><td>yes</td><td>rebill period</td></tr>
<tr><td>max_rebill_count</td><td>int</td><td>yes</td><td>max rebill count (-1 unlimited)</td></tr>
<tr><td>description</td><td>string</td><td>yes</td><td>Item description</td></tr>
</table>
pp_config
<table>
<tr><th>Name</th><th>Type</th><th>Required</th><th>Description</th></tr>
<tr><td>ppac_id</td><td>int</td><td>no</td><td>Merchant account id (defined for partner in payment app)</td></tr>
<tr><td>force_acc</td><td>int</td><td>no</td><td>**Rocket Gate** specific, if set it will set appropriate merchantAccount parameter for API call to Rocket Gate</td></tr>
<tr><td>force_mid</td><td>int</td><td>no</td><td>**Rocket Gate** specific, if set it will set appropriate merchantSiteID parameter for API call to Rocket Gate</td></tr>
</table>
==== Return ====
<table>
<tr><th>Name</th><th>Type</th><th>Description</th></tr>
<tr><td>result</td><td>array</td><td>Result array with data</td></tr>
</table>
==== Usage Example ====
```
{
"result": {
"code": 700,
"status": "Action completed successfully",
"command": "transaction.create",
"result": {
"hash": "1554909890217532c2fe3c75da8275e3",
"redirect": "",
"success": true,
"rg_avs_response": "",
"rg_cvv2_code": "",
"authNo": "422144",
"merchantInvoiceID": "M1_4153916_49356",
"merchantAccount": "2",
"approvedAmount": "1.0",
"cardLastFour": "1881",
"version": "1.0",
"merchantCustomerID": "M1_4153916",
"reasonCode": "0",
"retrievalNo": "100016a07da07af",
"payType": "CREDIT",
"cardHash": "3RPN+a+d07r0bOlq7NcWPKvzgcyyHmPxXw+hCxxmP6k=",
"cardDebitCredit": "1",
"cardDescription": "UNKNOWN",
"cardCountry": "CA",
"cardType": "VISA",
"bankResponseCode": "0",
"approvedCurrency": "PLN",
"guidNo": "100016A07DA07AF",
"cardExpiration": "0621",
"responseCode": "0",
"remote_tran_id": "100016A07DA07AF",
"payment_tran_id": 298906,
"rg_merchant_id": "1358984622",
"rg_customer_id": "M1_4153916",
"rg_reason_code": "0",
"rg_guid_no": "100016A07DA07AF",
"rg_cc_hash": "3RPN+a+d07r0bOlq7NcWPKvzgcyyHmPxXw+hCxxmP6k=",
"items_data": [
{
"item_id": "69312",
"tracking_item": "0"
}
],
"sub_ids": [
36214
],
"ppac_id": "74"
},
"request": {
"cmd": "transaction.create",
"data": {
"tracking_user": "4153916",
"tracking_tag": "14",
"tracking_item": "13084",
"first_name": "Jeremiah",
"last_name": "Hawn",
"street": "",
"city": "",
"state": "",
"zipcode": "92691",
"country": "US",
"email": "xstest426@xstest426.net",
"ip": "68.5.187.46",
"host": "68.5.187.46",
"currency": "PLN",
"items": [
{
"amount": "1",
"description": "$1.00USD - 1 Month Premium Membership Access||13084",
"max_rebill_count": "1",
"rebill_unit": "day",
"rebill_period": "30",
"trial_period": "30",
"trial_amount": "1.00",
"trial_unit": "day"
}
],
"pp_type": "RG",
"transaction_id": "297634"
},
"token": "dating-frontend-m1@staging",
"pass": "***"
},
"ts": 1554909890,
"origin_ip": "69.61.68.253",
"errors": null
}
}
```
== transaction.create ==
**Note: command is supported by all CC and mobile processors (RG, AR, NB, PO, RG, IO, GP).**
==== Description ====
Initialize and finish transaction in one command
==== Input Parameters ====
<table>
<tr><th>Name</th><th>Type</th><th>Required</th><th>Description</th></tr>
<tr><td>pp_type</td><td>(string)</td><td>yes</td><td>Payment processor type</td></tr>
<tr><td>tracking_order</td><td>(int)</td><td>no</td><td>Order ID to be tracked on client app.</td></tr>
<tr><td>tracking_user</td><td>(int)</td><td>yes</td><td>User ID to be tracked on client app.</td></tr>
<tr><td>tracking_tag</td><td>(int)</td><td>yes</td><td>Tag ID to be tracked on client app.</td></tr>
<tr><td>first_name</td><td>(string)</td><td>no</td><td>First Name</td></tr>
<tr><td>last_name</td><td>(string)</td><td>no</td><td>Last Name</td></tr>
<tr><td>zipcode</td><td>(string)</td><td>no</td><td>User ZIP code</td></tr>
<tr><td>country</td><td>(string)</td><td>no</td><td>Country abbr.</td></tr>
<tr><td>email</td><td>(string)</td><td>yes</td><td>User email address</td></tr>
<tr><td>ip</td><td>(string)</td><td>yes</td><td>IP address from which user is making the transaction</td></tr>
<tr><td>host</td><td>(string)</td><td>yes</td><td>Host form which user is making the transaction</td></tr>
<tr><td>currency</td><td>(string)</td><td>yes</td><td>Currency abbr.</td></tr>
<tr><td>order_type</td><td>(string)</td><td>no</td><td>Allowed values '' (empty string) and `xsale`. Determine if order is Cross Sale or not.</td></tr>
<tr><td>initial_order_hash</td><td>(string)</td><td>no</td><td>Use only in case of order_type = 'xsale'. Put hash from transation.init response of initial/basic order</td></tr>
<tr><td>return_url</td><td>(string)</td><td>no</td><td>Return URL (used for PayPal like PP's)</td></tr>
<tr><td>cancel_url</td><td>(string)</td><td>no</td><td>Cancel URL (used for PayPal like PP's)</td></tr>
<tr><td>items</td><td>(array)</td><td>yes</td><td>Array of items</td></tr>
<tr><td>pp_config</td><td>(array)</td><td>no</td><td>Merchand data params to override</td></tr>
<tr><td>card_number</td><td>(string)</td><td>yes</td><td>Credit Card Number</td></tr>
<tr><td>transaction_id</td><td>(string)</td><td>no</td><td>Can be used instead of Credit Card for repeated billing transactions</td></tr>
<tr><td>card_cvv2</td><td>(string)</td><td>yes</td><td>Credit Card CVV2</td></tr>
<tr><td>card_expire</td><td>(string)</td><td>yes</td><td>Credit Card Expiration date</td></tr>
<tr><td>xsale-descriptor</td><td>(string)</td><td>no</td><td>Force descriptor value (XS only)</td></tr>
<tr><td>step_down</td><td>(int)</td><td>no</td><td>Force step down procedure (start immediately with stepped down price)</td></tr><tr><td>allow_step_down</td><td>(int)</td><td>no</td><td>Allow step down procedure (start immediately when 1st attempt fails - if possible)</td></tr>
<tr><td>merchant_order_number</td><td>(string)</td><td>*yes(GP)</td><td>GP only param</td></tr>
<tr><td>package_name</td><td>(string)</td><td>*yes(GP)</td><td>GP only param</td></tr>
<tr><td>purchase_token</td><td>(string)</td><td>*yes(GP)</td><td>GP only param</td></tr>
<tr><td>purchase_id</td><td>(string)</td><td>*yes(GP/IO)</td><td>GP and IO only param</td></tr>
<tr><td>receipt-data</td><td>(string)</td><td>*yes(IO)</td><td>IO only param</td></tr>
<tr><td>fingerprint</td><td>(string)</td><td>*no(RG 3DS 2)</td><td>**RocketGate only param. Required in step 2, device fingerpring</td></tr>
<tr><td>user_agent</td><td>(string)</td><td>*no(RG 3DS 2)</td><td>**RocketGate only param. Required in step 2, user's user agent</td></tr>
<tr><td>user_accept</td><td>(string)</td><td>*no(RG 3DS 2)</td><td>**RocketGate only param. Required in step 2, user's user_accept</td></tr>
<tr><td>browser_fields</td><td>(string)</td><td>*no(RG 3DS 2)</td><td>**RocketGate only param. Required in step 2, JSON containing browser dada (details below)</td></tr>
<tr><td>md</td><td>(string)</td><td>*no(RG 3DS 2)</td><td>**RocketGate only param. Required in step 3, returned transaction id (md, guid)</td></tr>
</table>
items
<table>
<tr><th>Name</th><th>Type</th><th>Required</th><th>Description</th></tr>
<tr><td>trial_amount</td><td>float</td><td>no</td><td>Trial Amount</td></tr>
<tr><td>trial_unit</td><td>string (day|week|month|year)</td><td>no</td><td>Trial unit</td></tr>
<tr><td>trial_period</td><td>int</td><td>no</td><td>Trial period</td></tr>
<tr><td>amount</td><td>float</td><td>yes</td><td>rebill amount</td></tr>
<tr><td>rebill_unit</td><td>string (day|week|month|year)</td><td>yes</td><td>rebill unit</td></tr>
<tr><td>rebill_period</td><td>int</td><td>yes</td><td>rebill period</td></tr>
<tr><td>max_rebill_count</td><td>int</td><td>yes</td><td>max rebill count (-1 unlimited)</td></tr>
<tr><td>description</td><td>string</td><td>yes</td><td>Item description</td></tr>
</table>
pp_config
<table>
<tr><th>Name</th><th>Type</th><th>Required</th><th>Description</th></tr>
<tr><td>ppac_id</td><td>int</td><td>no</td><td>Merchant account id (defined for partner in payment app)</td></tr>
<tr><td>force_acc</td><td>int</td><td>no</td><td>**Rocket Gate** specific, if set it will set appropriate merchantAccount parameter for API call to Rocket Gate</td></tr>
<tr><td>force_mid</td><td>int</td><td>no</td><td>**Rocket Gate** specific, if set it will set appropriate merchantSiteID parameter for API call to Rocket Gate</td></tr>
<tr><td>force_3ds</td><td>int</td><td>no</td><td>**Rocket Gate** specific, Experimental/temporary, when set to true/1 it will allow to make 3ds 2.0 transaction</td></tr>
</table>
browser_fields (*json containing optioinal fields listed below)
<table>
<tr><th>Name</th><th>Type</th><th>Required</th><th>Description</th><th>Example value</th></tr>
<tr><td>java_enabled</td><td>bool</td><td>no</td><td>Java enabled</td><td>true</td></tr>
<tr><td>language</td><td>string</td><td>no</td><td>Java enabled</td><td>en-US</td></tr>
<tr><td>color_depth</td><td>numeric</td><td>no</td><td>Java enabled</td><td>32</td></tr>
<tr><td>screen_height</td><td>numeric</td><td>no</td><td>Java enabled</td><td>864</td></tr>
<tr><td>screen_width</td><td>numeric</td><td>no</td><td>Java enabled</td><td>1536</td></tr>
<tr><td>time_zone</td><td>numeric</td><td>no</td><td>Java enabled</td><td>480</td></tr>
</table>
==== Return ====
<table>
<tr><th>Name</th><th>Type</th><th>Description</th></tr>
<tr><td>result</td><td>array</td><td>Result array with data</td></tr>
</table>
==== Usage Example ====
```
{
"result": {
"code": 700,
"status": "Action completed successfully",
"command": "transaction.create",
"result": {
"hash": "1554909890217532c2fe3c75da8275e3",
"redirect": "",
"success": true,
"rg_avs_response": "",
"rg_cvv2_code": "",
"authNo": "422144",
"merchantInvoiceID": "M1_4153916_49356",
"merchantAccount": "2",
"approvedAmount": "1.0",
"cardLastFour": "1881",
"version": "1.0",
"merchantCustomerID": "M1_4153916",
"reasonCode": "0",
"retrievalNo": "100016a07da07af",
"payType": "CREDIT",
"cardHash": "3RPN+a+d07r0bOlq7NcWPKvzgcyyHmPxXw+hCxxmP6k=",
"cardDebitCredit": "1",
"cardDescription": "UNKNOWN",
"cardCountry": "CA",
"cardType": "VISA",
"bankResponseCode": "0",
"approvedCurrency": "PLN",
"guidNo": "100016A07DA07AF",
"cardExpiration": "0621",
"responseCode": "0",
"remote_tran_id": "100016A07DA07AF",
"payment_tran_id": 298906,
"rg_merchant_id": "1358984622",
"rg_customer_id": "M1_4153916",
"rg_reason_code": "0",
"rg_guid_no": "100016A07DA07AF",
"rg_cc_hash": "3RPN+a+d07r0bOlq7NcWPKvzgcyyHmPxXw+hCxxmP6k=",
"items_data": [
{
"item_id": "69312",
"tracking_item": "0"
}
],
"sub_ids": [
36214
],
"ppac_id": "74"
},
"request": {
"cmd": "transaction.create",
"data": {
"tracking_user": "4153916",
"tracking_tag": "14",
"tracking_item": "13084",
"first_name": "Jeremiah",
"last_name": "Hawn",
"street": "",
"city": "",
"state": "",
"zipcode": "92691",
"country": "US",
"email": "xstest426@xstest426.net",
"ip": "68.5.187.46",
"host": "68.5.187.46",
"currency": "PLN",
"items": [
{
"amount": "1",
"description": "$1.00USD - 1 Month Premium Membership Access||13084",
"max_rebill_count": "1",
"rebill_unit": "day",
"rebill_period": "30",
"trial_period": "30",
"trial_amount": "1.00",
"trial_unit": "day"
}
],
"pp_type": "RG",
"transaction_id": "297634"
},
"token": "dating-frontend-m1@staging",
"pass": "***"
},
"ts": 1554909890,
"origin_ip": "69.61.68.253",
"errors": null
}
}
```
==== Usage Example 3DSv2 - full workflow example ====
==== Step 1 ====
```
{
"code": 631,
"status": "Transaction was declined because 3-D Secure 2.0 fingerprint is required",
"command": "transaction.create",
"result": {
"hash": "160501994931331a6a4eec14438345dc",
"success": false,
"rg_avs_response": "",
"rg_cvv2_code": "",
"needs_resubmission": true,
"cardType": "VISA",
"_3DSECURE_DEVICE_COLLECTION_JWT": "eyJhbGciOiJIUzI1NiJ9.eyJqdGkiOiI3MjA1OTE5OTA1ODI1NTkwOSIsImlhdCI6MTYwNTAyMDMyNywiaXNzIjoiNWNmYTVhMDFhZmE4MGQyMjUwZmQzMTc5IiwiT3JnVW5pdElkIjoiNWNmNzA2OWRiYjg3NjgxOTZjMTBhNGU5In0.9EFTeyIQI75ohgmgqfXqGTCA0j7R65IK9GPzzwTzaFU",
"reasonCode": "225",
"merchantInvoiceID": "M1_1_234736",
"merchantAccount": "3",
"version": "1.0",
"cardLastFour": "1091",
"cardHash": "lDeyafqiaLIdgqxNYUJ5FjMvWESYoA3r49aauQoNdEw=",
"guidNo": "1000175B2AAA025",
"responseCode": "2",
"_3DSECURE_DEVICE_COLLECTION_URL": "https:\/\/centinelapistag.cardinalcommerce.com\/V1\/Cruise\/Collect",
"cardExpiration": "1123",
"merchantCustomerID": "M1_1",
"payType": "CREDIT",
"remote_tran_id": "1000175B2AAA025",
"payment_tran_id": 979396,
"rg_merchant_id": "1358984622",
"rg_customer_id": "M1_1",
"rg_reason_code": "2",
"rg_guid_no": "1000175B2AAA025",
"rg_cc_hash": "lDeyafqiaLIdgqxNYUJ5FjMvWESYoA3r49aauQoNdEw=",
"partial_billing": 0,
"partial_billing_factor": 1,
"items_data": [
{
"item_id": "254696",
"tracking_item": "13808"
}
],
"ppac_id": "74"
},
"request": {
"cmd": "transaction.create",
"data": {
"pp_type": "RG",
"card_number": "400000xxxxxx1091",
"card_cvv2": "xxx",
"card_expire": "1123",
"first_name": "tester",
"last_name": "tester",
"zipcode": "10001",
"items": [
{
"amount": "2.96",
"description": "3 months - $15.99GBP\/month^^ENV=staging||13808",
"max_rebill_count": "10",
"rebill_unit": "day",
"rebill_period": "90",
"trial_period": "0",
"trial_amount": "0",
"trial_unit": "day",
"tracking_item": "13808"
}
],
"tracking_company": "1",
"tracking_tag": "1",
"tracking_user": "1",
"email": "tester@tester.com",
"country": "DE",
"state": "1",
"city": "berlin",
"street": "hohestrasee 1",
"ip": "83.30.69.51",
"currency": "EUR",
"return_url": "https:\/\/payment.dvipdev.com\/emulate\/rg3ds",
"cancel_url": "https:\/\/payment.dvipdev.com\/emulate\/rg3ds",
"order_type": "basic",
"pp_config": {
"ppac_id": "74",
"force_3ds": "1"
},
},
"token": "dating-frontend-m1@staging",
"pass": "xxx"
},
"ts": 1605020329,
"origin_ip": "69.61.68.253",
"errors": [
{
"code": 631,
"error_msg": "[225] 3DSecure 2.0 fingerprinting required - 3DSecure 2.0 fingerprinting required - JWT returned, fingepring required"
}
]
}
```
=== Step 2 ===
```
{
"code": 615,
"status": "Transaction was declined because 3-D Secure authentication is required",
"command": "transaction.create",
"result": {
"hash": "160501994931331a6a4eec14438345dc",
"success": false,
"rg_avs_response": "",
"rg_cvv2_code": "",
"post_params": {
"ACSredirectURL": "https:\/\/dev-secure.rocketgate.com\/hostedpage\/3DSimulator_2_0.jsp",
"ACSJWT": "https:\/\/payment.dvipdev.com\/emulate\/rg3ds",
"ACStermURL": "https:\/\/payment.dvipdev.com\/listener\/RG",
"ACSmd": "1000175B2AAB663"
},
"needs_resubmission": true,
"merchantInvoiceID": "M1_1_234736",
"merchantAccount": "3",
"approvedAmount": "2.96",
"cardLastFour": "1091",
"version": "1.0",
"_3DSECURE_STEP_UP_URL": "https:\/\/dev-secure.rocketgate.com\/hostedpage\/3DSimulator_2_0.jsp",
"merchantCustomerID": "M1_1",
"scrubResults": "NEGDB=0,PROFILE=0,ACTIVITY=0",
"reasonCode": "202",
"transactionTime": "2020-11-10 09:58:53",
"payType": "CREDIT",
"cardHash": "lDeyafqiaLIdgqxNYUJ5FjMvWESYoA3r49aauQoNdEw=",
"_3DSECURE_STEP_UP_JWT": "https:\/\/payment.dvipdev.com\/emulate\/rg3ds",
"cardDebitCredit": "0",
"cardDescription": "UNKNOWN",
"cardType": "VISA",
"approvedCurrency": "EUR",
"_3DSECURE_VERSION": "2.2.0",
"guidNo": "1000175B2AAB663",
"cardExpiration": "1123",
"responseCode": "2",
"remote_tran_id": "1000175B2AAB663",
"payment_tran_id": 979406,
"rg_merchant_id": "1358984622",
"rg_customer_id": "M1_1",
"rg_reason_code": "2",
"rg_guid_no": "1000175B2AAB663",
"rg_cc_hash": "lDeyafqiaLIdgqxNYUJ5FjMvWESYoA3r49aauQoNdEw=",
"partial_billing": 0,
"partial_billing_factor": 1,
"items_data": [
{
"item_id": "254696",
"tracking_item": "13808"
}
],
"ppac_id": "74"
},
"request": {
"cmd": "transaction.create",
"data": {
"pp_type": "RG",
"card_number": "400000xxxxxx1091",
"card_cvv2": "xxx",
"card_expire": "1123",
"first_name": "tester",
"last_name": "tester",
"zipcode": "10001",
"items": [
{
"amount": "2.96",
"description": "3 months - $15.99GBP\/month^^ENV=staging||13808",
"max_rebill_count": "10",
"rebill_unit": "day",
"rebill_period": "90",
"trial_period": "0",
"trial_amount": "0",
"trial_unit": "day",
"tracking_item": "13808"
}
],
"tracking_company": "1",
"tracking_tag": "1",
"tracking_user": "1",
"email": "tester@tester.com",
"country": "DE",
"state": "1",
"city": "berlin",
"street": "hohestrasee 1",
"ip": "83.30.69.51",
"currency": "EUR",
"return_url": "https:\/\/payment.dvipdev.com\/emulate\/rg3ds",
"cancel_url": "https:\/\/payment.dvipdev.com\/emulate\/rg3ds",
"order_type": "basic",
"pp_config": {
"ppac_id": "74",
"force_3ds": "1"
},
"user_agent": "Mozilla\/5.0 (X11; Ubuntu; Linux x86_64; rv:82.0) Gecko\/20100101 Firefox\/82.0",
"user_accept": "text\/html,application\/xhtml+xml,application\/xml;q=0.9,image\/webp,*\/*;q=0.8",
"fingerprint": "0_6248ed13-b695-4ada-821b-02a11ed38591"
},
"token": "dating-frontend-m1@staging",
"pass": "***"
},
"ts": 1605020334,
"origin_ip": "69.61.68.253",
"errors": [
{
"code": 615,
"error_msg": "[202] Declined - 3-DS - Transaction was declined because 3-D Secure authentication is required"
}
]
}
```
=== Step 3 ===
```
{
"code": 700,
"status": "Action completed successfully",
"command": "transaction.create",
"result": {
"hash": "160501994931331a6a4eec14438345dc",
"success": true,
"rg_avs_response": "Y",
"rg_cvv2_code": "M",
"authNo": "673033",
"merchantInvoiceID": "M1_1_234736",
"merchantAccount": "3",
"approvedAmount": "2.96",
"cardLastFour": "1091",
"version": "1.0",
"avsResponse": "Y",
"merchantCustomerID": "M1_1",
"scrubResults": "NEGDB=0,PROFILE=0,ACTIVITY=0",
"ECI": "05",
"cvv2Code": "M",
"reasonCode": "0",
"transactionTime": "2020-11-10 09:59:30",
"payType": "CREDIT",
"cardHash": "lDeyafqiaLIdgqxNYUJ5FjMvWESYoA3r49aauQoNdEw=",
"cardDebitCredit": "0",
"cardDescription": "UNKNOWN",
"cardType": "VISA",
"bankResponseCode": "0",
"approvedCurrency": "EUR",
"guidNo": "1000175B2AB474B",
"cardExpiration": "1123",
"responseCode": "0",
"remote_tran_id": "1000175B2AB474B",
"payment_tran_id": 979416,
"rg_merchant_id": "1358984622",
"rg_customer_id": "M1_1",
"rg_reason_code": "0",
"rg_guid_no": "1000175B2AB474B",
"rg_cc_hash": "lDeyafqiaLIdgqxNYUJ5FjMvWESYoA3r49aauQoNdEw=",
"partial_billing": 0,
"partial_billing_factor": 1,
"items_data": [
{
"item_id": "254696",
"tracking_item": "13808"
}
],
"sub_ids": [
189636
],
"ppac_id": "74"
},
"request": {
"cmd": "transaction.create",
"data": {
"pp_type": "RG",
"card_number": "400000xxxxxx1091",
"card_cvv2": "xxx",
"card_expire": "1123",
"first_name": "tester",
"last_name": "tester",
"zipcode": "10001",
"items": [
{
"amount": "2.96",
"description": "3 months - $15.99GBP\/month^^ENV=staging||13808",
"max_rebill_count": "10",
"rebill_unit": "day",
"rebill_period": "90",
"trial_period": "0",
"trial_amount": "0",
"trial_unit": "day",
"tracking_item": "13808"
}
],
"tracking_company": "1",
"tracking_tag": "1",
"tracking_user": "1",
"email": "tester@tester.com",
"country": "DE",
"state": "1",
"city": "berlin",
"street": "hohestrasee 1",
"ip": "83.30.69.51",
"currency": "EUR",
"return_url": "https:\/\/payment.dvipdev.com\/emulate\/rg3ds",
"cancel_url": "https:\/\/payment.dvipdev.com\/emulate\/rg3ds",
"order_type": "basic",
"pp_config": {
"ppac_id": "74",
"force_3ds": "1"
},
"md": "1000175B2AAB663"
},
"token": "dating-frontend-m1@staging",
"pass": "***"
},
"ts": 1605020372,
"origin_ip": "69.61.68.253",
"errors": null
}
```
== transaction.create ==
**Note: command is available on staging env only for now.s supported by all CC and mobile processors (RG, AR, NB, PO, RG, IO, It is supported by RocketGate and Argus processors only.GP).**
==== Description ====
Initialize and finish transaction in one command
==== Input Parameters ====
<table>
<tr><th>Name</th><th>Type</th><th>Required</th><th>Description</th></tr>
<tr><td>pp_type</td><td>(string)</td><td>yes</td><td>Payment processor type</td></tr>
<tr><td>tracking_order</td><td>(int)</td><td>no</td><td>Order ID to be tracked on client app.</td></tr>
<tr><td>tracking_user</td><td>(int)</td><td>yes</td><td>User ID to be tracked on client app.</td></tr>
<tr><td>tracking_tag</td><td>(int)</td><td>yes</td><td>Tag ID to be tracked on client app.</td></tr>
<tr><td>first_name</td><td>(string)</td><td>yesno</td><td>First Name</td></tr>
<tr><td>last_name</td><td>(string)</td><td>yesno</td><td>Last Name</td></tr>
<tr><td>zipcode</td><td>(string)</td><td>yesno</td><td>User ZIP code</td></tr>
<tr><td>country</td><td>(string)</td><td>yesno</td><td>Country abbr.</td></tr>
<tr><td>email</td><td>(string)</td><td>yes</td><td>User email address</td></tr>
<tr><td>ip</td><td>(string)</td><td>yes</td><td>IP address from which user is making the transaction</td></tr>
<tr><td>host</td><td>(string)</td><td>yes</td><td>Host form which user is making the transaction</td></tr>
<tr><td>currency</td><td>(string)</td><td>yes</td><td>Currency abbr.</td></tr>
<tr><td>order_type</td><td>(string)</td><td>no</td><td>Allowed values '' (empty string) and `xsale`. Determine if order is Cross Sale or not.</td></tr>
<tr><td>initial_order_hash</td><td>(string)</td><td>no</td><td>Use only in case of order_type = 'xsale'. Put hash from transation.init response of initial/basic order</td></tr>
<tr><td>return_url</td><td>(string)</td><td>no</td><td>Return URL (used for PayPal like PP's)</td></tr>
<tr><td>cancel_url</td><td>(string)</td><td>no</td><td>Cancel URL (used for PayPal like PP's)</td></tr>
<tr><td>items</td><td>(array)</td><td>yes</td><td>Array of items</td></tr>
<tr><td>pp_config</td><td>(array)</td><td>no</td><td>Merchand data params to override</td></tr>
<tr><td>card_number</td><td>(string)</td><td>yes</td><td>Credit Card Number</td></tr>
<tr><td>transaction_id</td><td>(string)</td><td>no</td><td>Can be used instead of Credit Card for repeated billing transactions</td></tr>
<tr><td>card_cvv2</td><td>(string)</td><td>yes</td><td>Credit Card CVV2</td></tr>
<tr><td>card_expire</td><td>(string)</td><td>yes</td><td>Credit Card Expiration date</td></tr>
<tr><td>xsale-descriptor</td><td>(string)</td><td>no</td><td>Force descriptor value (XS only)</td></tr>
<tr><td>step_down</td><td>(int)</td><td>no</td><td>Force step down procedure (start immediately with stepped down price)</td></tr><tr><td>allow_step_down</td><td>(int)</td><td>no</td><td>Allow step down procedure (start immediately when 1st attempt fails - if possible)</td></tr>
<tr><td>merchant_order_number</td><td>(string)</td><td>*yes(GP)</td><td>GP only param</td></tr>
<tr><td>package_name</td><td>(string)</td><td>*yes(GP)</td><td>GP only param</td></tr>
<tr><td>purchase_token</td><td>(string)</td><td>*yes(GP)</td><td>GP only param</td></tr>
<tr><td>purchase_id</td><td>(string)</td><td>*yes(GP/IO)</td><td>GP and IO only param</td></tr>
<tr><td>receipt-data</td><td>(string)</td><td>*yes(IO)</td><td>IO only param</td></tr>
<tr><td>fingerprint</td><td>(string)</td><td>*no(RG 3DS 2)</td><td>**RocketGate only param. Required in step 2, device fingerpring</td></tr>
<tr><td>user_agent</td><td>(string)</td><td>*no(RG 3DS 2)</td><td>**RocketGate only param. Required in step 2, user's user agent</td></tr>
<tr><td>user_accept</td><td>(string)</td><td>*no(RG 3DS 2)</td><td>**RocketGate only param. Required in step 2, user's user_accept</td></tr>
<tr><td>browser_fields</td><td>(string)</td><td>*no(RG 3DS 2)</td><td>**RocketGate only param. Required in step 2, JSON containing browser dada (details below)</td></tr>
<tr><td>md</td><td>(string)</td><td>*no(RG 3DS 2)</td><td>**RocketGate only param. Required in step 3, returned transaction id (md, guid)</td></tr>
</table>
items
<table>
<tr><th>Name</th><th>Type</th><th>Required</th><th>Description</th></tr>
<tr><td>trial_amount</td><td>float</td><td>no</td><td>Trial Amount</td></tr>
<tr><td>trial_unit</td><td>string (day|week|month|year)</td><td>no</td><td>Trial unit</td></tr>
<tr><td>trial_period</td><td>int</td><td>no</td><td>Trial period</td></tr>
<tr><td>amount</td><td>float</td><td>yes</td><td>rebill amount</td></tr>
<tr><td>rebill_unit</td><td>string (day|week|month|year)</td><td>yes</td><td>rebill unit</td></tr>
<tr><td>rebill_period</td><td>int</td><td>yes</td><td>rebill period</td></tr>
<tr><td>max_rebill_count</td><td>int</td><td>yes</td><td>max rebill count (-1 unlimited)</td></tr>
<tr><td>description</td><td>string</td><td>yes</td><td>Item description</td></tr>
</table>
pp_config
<table>
<tr><th>Name</th><th>Type</th><th>Required</th><th>Description</th></tr>
<tr><td>ppac_id</td><td>int</td><td>no</td><td>Merchant account id (defined for partner in payment app)</td></tr>
<tr><td>force_acc</td><td>int</td><td>no</td><td>**Rocket Gate** specific, if set it will set appropriate merchantAccount parameter for API call to Rocket Gate</td></tr>
<tr><td>force_mid</td><td>int</td><td>no</td><td>**Rocket Gate** specific, if set it will set appropriate merchantSiteID parameter for API call to Rocket Gate</td></tr>
<tr><td>force_3ds</td><td>int</td><td>no</td><td>**Rocket Gate** specific, Experimental/temporary, when set to true/1 it will allow to make 3ds 2.0 transaction</td></tr>
</table>
browser_fields (*json containing optioinal fields listed below)
<table>
<tr><th>Name</th><th>Type</th><th>Required</th><th>Description</th><th>Example value</th></tr>
<tr><td>java_enabled</td><td>bool</td><td>no</td><td>Java enabled</td><td>true</td></tr>
<tr><td>language</td><td>string</td><td>no</td><td>Java enabled</td><td>en-US</td></tr>
<tr><td>color_depth</td><td>numeric</td><td>no</td><td>Java enabled</td><td>32</td></tr>
<tr><td>screen_height</td><td>numeric</td><td>no</td><td>Java enabled</td><td>864</td></tr>
<tr><td>screen_width</td><td>numeric</td><td>no</td><td>Java enabled</td><td>1536</td></tr>
<tr><td>time_zone</td><td>numeric</td><td>no</td><td>Java enabled</td><td>480</td></tr>
</table>
==== Return ====
<table>
<tr><th>Name</th><th>Type</th><th>Description</th></tr>
<tr><td>result</td><td>array</td><td>Result array with data</td></tr>
</table>
==== Usage Example ====
```
{
"result": {
"code": 700,
"status": "Action completed successfully",
"command": "transaction.create",
"result": {
"hash": "1554909890217532c2fe3c75da8275e3",
"redirect": "",
"success": true,
"rg_avs_response": "",
"rg_cvv2_code": "",
"authNo": "422144",
"merchantInvoiceID": "M1_4153916_49356",
"merchantAccount": "2",
"approvedAmount": "1.0",
"cardLastFour": "1881",
"version": "1.0",
"merchantCustomerID": "M1_4153916",
"reasonCode": "0",
"retrievalNo": "100016a07da07af",
"payType": "CREDIT",
"cardHash": "3RPN+a+d07r0bOlq7NcWPKvzgcyyHmPxXw+hCxxmP6k=",
"cardDebitCredit": "1",
"cardDescription": "UNKNOWN",
"cardCountry": "CA",
"cardType": "VISA",
"bankResponseCode": "0",
"approvedCurrency": "PLN",
"guidNo": "100016A07DA07AF",
"cardExpiration": "0621",
"responseCode": "0",
"remote_tran_id": "100016A07DA07AF",
"payment_tran_id": 298906,
"rg_merchant_id": "1358984622",
"rg_customer_id": "M1_4153916",
"rg_reason_code": "0",
"rg_guid_no": "100016A07DA07AF",
"rg_cc_hash": "3RPN+a+d07r0bOlq7NcWPKvzgcyyHmPxXw+hCxxmP6k=",
"items_data": [
{
"item_id": "69312",
"tracking_item": "0"
}
],
"sub_ids": [
36214
],
"ppac_id": "74"
},
"request": {
"cmd": "transaction.create",
"data": {
"tracking_user": "4153916",
"tracking_tag": "14",
"tracking_item": "13084",
"first_name": "Jeremiah",
"last_name": "Hawn",
"street": "",
"city": "",
"state": "",
"zipcode": "92691",
"country": "US",
"email": "xstest426@xstest426.net",
"ip": "68.5.187.46",
"host": "68.5.187.46",
"currency": "PLN",
"items": [
{
"amount": "1",
"description": "$1.00USD - 1 Month Premium Membership Access||13084",
"max_rebill_count": "1",
"rebill_unit": "day",
"rebill_period": "30",
"trial_period": "30",
"trial_amount": "1.00",
"trial_unit": "day"
}
],
"pp_type": "RG",
"transaction_id": "297634"
},
"token": "dating-frontend-m1@staging",
"pass": "***"
},
"ts": 1554909890,
"origin_ip": "69.61.68.253",
"errors": null
}
}
```
==== Usage Example 3DSv2 - full workflow example ====
==== Step 1 ====
```
{
"code": 631,
"status": "Transaction was declined because 3-D Secure 2.0 fingerprint is required",
"command": "transaction.create",
"result": {
"hash": "160501994931331a6a4eec14438345dc",
"success": false,
"rg_avs_response": "",
"rg_cvv2_code": "",
"needs_resubmission": true,
"cardType": "VISA",
"_3DSECURE_DEVICE_COLLECTION_JWT": "eyJhbGciOiJIUzI1NiJ9.eyJqdGkiOiI3MjA1OTE5OTA1ODI1NTkwOSIsImlhdCI6MTYwNTAyMDMyNywiaXNzIjoiNWNmYTVhMDFhZmE4MGQyMjUwZmQzMTc5IiwiT3JnVW5pdElkIjoiNWNmNzA2OWRiYjg3NjgxOTZjMTBhNGU5In0.9EFTeyIQI75ohgmgqfXqGTCA0j7R65IK9GPzzwTzaFU",
"reasonCode": "225",
"merchantInvoiceID": "M1_1_234736",
"merchantAccount": "3",
"version": "1.0",
"cardLastFour": "1091",
"cardHash": "lDeyafqiaLIdgqxNYUJ5FjMvWESYoA3r49aauQoNdEw=",
"guidNo": "1000175B2AAA025",
"responseCode": "2",
"_3DSECURE_DEVICE_COLLECTION_URL": "https:\/\/centinelapistag.cardinalcommerce.com\/V1\/Cruise\/Collect",
"cardExpiration": "1123",
"merchantCustomerID": "M1_1",
"payType": "CREDIT",
"remote_tran_id": "1000175B2AAA025",
"payment_tran_id": 979396,
"rg_merchant_id": "1358984622",
"rg_customer_id": "M1_1",
"rg_reason_code": "2",
"rg_guid_no": "1000175B2AAA025",
"rg_cc_hash": "lDeyafqiaLIdgqxNYUJ5FjMvWESYoA3r49aauQoNdEw=",
"partial_billing": 0,
"partial_billing_factor": 1,
"items_data": [
{
"item_id": "254696",
"tracking_item": "13808"
}
],
"ppac_id": "74"
},
"request": {
"cmd": "transaction.create",
"data": {
"pp_type": "RG",
"card_number": "400000xxxxxx1091",
"card_cvv2": "xxx",
"card_expire": "1123",
"first_name": "tester",
"last_name": "tester",
"zipcode": "10001",
"items": [
{
"amount": "2.96",
"description": "3 months - $15.99GBP\/month^^ENV=staging||13808",
"max_rebill_count": "10",
"rebill_unit": "day",
"rebill_period": "90",
"trial_period": "0",
"trial_amount": "0",
"trial_unit": "day",
"tracking_item": "13808"
}
],
"tracking_company": "1",
"tracking_tag": "1",
"tracking_user": "1",
"email": "tester@tester.com",
"country": "DE",
"state": "1",
"city": "berlin",
"street": "hohestrasee 1",
"ip": "83.30.69.51",
"currency": "EUR",
"return_url": "https:\/\/payment.dvipdev.com\/emulate\/rg3ds",
"cancel_url": "https:\/\/payment.dvipdev.com\/emulate\/rg3ds",
"order_type": "basic",
"pp_config": {
"ppac_id": "74",
"force_3ds": "1"
},
},
"token": "dating-frontend-m1@staging",
"pass": "xxx"
},
"ts": 1605020329,
"origin_ip": "69.61.68.253",
"errors": [
{
"code": 631,
"error_msg": "[225] 3DSecure 2.0 fingerprinting required - 3DSecure 2.0 fingerprinting required - JWT returned, fingepring required"
}
]
}
```
=== Step 2 ===
```
{
"code": 615,
"status": "Transaction was declined because 3-D Secure authentication is required",
"command": "transaction.create",
"result": {
"hash": "160501994931331a6a4eec14438345dc",
"success": false,
"rg_avs_response": "",
"rg_cvv2_code": "",
"post_params": {
"ACSredirectURL": "https:\/\/dev-secure.rocketgate.com\/hostedpage\/3DSimulator_2_0.jsp",
"ACSJWT": "https:\/\/payment.dvipdev.com\/emulate\/rg3ds",
"ACStermURL": "https:\/\/payment.dvipdev.com\/listener\/RG",
"ACSmd": "1000175B2AAB663"
},
"needs_resubmission": true,
"merchantInvoiceID": "M1_1_234736",
"merchantAccount": "3",
"approvedAmount": "2.96",
"cardLastFour": "1091",
"version": "1.0",
"_3DSECURE_STEP_UP_URL": "https:\/\/dev-secure.rocketgate.com\/hostedpage\/3DSimulator_2_0.jsp",
"merchantCustomerID": "M1_1",
"scrubResults": "NEGDB=0,PROFILE=0,ACTIVITY=0",
"reasonCode": "202",
"transactionTime": "2020-11-10 09:58:53",
"payType": "CREDIT",
"cardHash": "lDeyafqiaLIdgqxNYUJ5FjMvWESYoA3r49aauQoNdEw=",
"_3DSECURE_STEP_UP_JWT": "https:\/\/payment.dvipdev.com\/emulate\/rg3ds",
"cardDebitCredit": "0",
"cardDescription": "UNKNOWN",
"cardType": "VISA",
"approvedCurrency": "EUR",
"_3DSECURE_VERSION": "2.2.0",
"guidNo": "1000175B2AAB663",
"cardExpiration": "1123",
"responseCode": "2",
"remote_tran_id": "1000175B2AAB663",
"payment_tran_id": 979406,
"rg_merchant_id": "1358984622",
"rg_customer_id": "M1_1",
"rg_reason_code": "2",
"rg_guid_no": "1000175B2AAB663",
"rg_cc_hash": "lDeyafqiaLIdgqxNYUJ5FjMvWESYoA3r49aauQoNdEw=",
"partial_billing": 0,
"partial_billing_factor": 1,
"items_data": [
{
"item_id": "254696",
"tracking_item": "13808"
}
],
"ppac_id": "74"
},
"request": {
"cmd": "transaction.create",
"data": {
"pp_type": "RG",
"card_number": "400000xxxxxx1091",
"card_cvv2": "xxx",
"card_expire": "1123",
"first_name": "tester",
"last_name": "tester",
"zipcode": "10001",
"items": [
{
"amount": "2.96",
"description": "3 months - $15.99GBP\/month^^ENV=staging||13808",
"max_rebill_count": "10",
"rebill_unit": "day",
"rebill_period": "90",
"trial_period": "0",
"trial_amount": "0",
"trial_unit": "day",
"tracking_item": "13808"
}
],
"tracking_company": "1",
"tracking_tag": "1",
"tracking_user": "1",
"email": "tester@tester.com",
"country": "DE",
"state": "1",
"city": "berlin",
"street": "hohestrasee 1",
"ip": "83.30.69.51",
"currency": "EUR",
"return_url": "https:\/\/payment.dvipdev.com\/emulate\/rg3ds",
"cancel_url": "https:\/\/payment.dvipdev.com\/emulate\/rg3ds",
"order_type": "basic",
"pp_config": {
"ppac_id": "74",
"force_3ds": "1"
},
"user_agent": "Mozilla\/5.0 (X11; Ubuntu; Linux x86_64; rv:82.0) Gecko\/20100101 Firefox\/82.0",
"user_accept": "text\/html,application\/xhtml+xml,application\/xml;q=0.9,image\/webp,*\/*;q=0.8",
"fingerprint": "0_6248ed13-b695-4ada-821b-02a11ed38591"
},
"token": "dating-frontend-m1@staging",
"pass": "***"
},
"ts": 1605020334,
"origin_ip": "69.61.68.253",
"errors": [
{
"code": 615,
"error_msg": "[202] Declined - 3-DS - Transaction was declined because 3-D Secure authentication is required"
}
]
}
```
=== Step 3 ===
```
{
"code": 700,
"status": "Action completed successfully",
"command": "transaction.create",
"result": {
"hash": "160501994931331a6a4eec14438345dc",
"success": true,
"rg_avs_response": "Y",
"rg_cvv2_code": "M",
"authNo": "673033",
"merchantInvoiceID": "M1_1_234736",
"merchantAccount": "3",
"approvedAmount": "2.96",
"cardLastFour": "1091",
"version": "1.0",
"avsResponse": "Y",
"merchantCustomerID": "M1_1",
"scrubResults": "NEGDB=0,PROFILE=0,ACTIVITY=0",
"ECI": "05",
"cvv2Code": "M",
"reasonCode": "0",
"transactionTime": "2020-11-10 09:59:30",
"payType": "CREDIT",
"cardHash": "lDeyafqiaLIdgqxNYUJ5FjMvWESYoA3r49aauQoNdEw=",
"cardDebitCredit": "0",
"cardDescription": "UNKNOWN",
"cardType": "VISA",
"bankResponseCode": "0",
"approvedCurrency": "EUR",
"guidNo": "1000175B2AB474B",
"cardExpiration": "1123",
"responseCode": "0",
"remote_tran_id": "1000175B2AB474B",
"payment_tran_id": 979416,
"rg_merchant_id": "1358984622",
"rg_customer_id": "M1_1",
"rg_reason_code": "0",
"rg_guid_no": "1000175B2AB474B",
"rg_cc_hash": "lDeyafqiaLIdgqxNYUJ5FjMvWESYoA3r49aauQoNdEw=",
"partial_billing": 0,
"partial_billing_factor": 1,
"items_data": [
{
"item_id": "254696",
"tracking_item": "13808"
}
],
"sub_ids": [
189636
],
"ppac_id": "74"
},
"request": {
"cmd": "transaction.create",
"data": {
"pp_type": "RG",
"card_number": "400000xxxxxx1091",
"card_cvv2": "xxx",
"card_expire": "1123",
"first_name": "tester",
"last_name": "tester",
"zipcode": "10001",
"items": [
{
"amount": "2.96",
"description": "3 months - $15.99GBP\/month^^ENV=staging||13808",
"max_rebill_count": "10",
"rebill_unit": "day",
"rebill_period": "90",
"trial_period": "0",
"trial_amount": "0",
"trial_unit": "day",
"tracking_item": "13808"
}
],
"tracking_company": "1",
"tracking_tag": "1",
"tracking_user": "1",
"email": "tester@tester.com",
"country": "DE",
"state": "1",
"city": "berlin",
"street": "hohestrasee 1",
"ip": "83.30.69.51",
"currency": "EUR",
"return_url": "https:\/\/payment.dvipdev.com\/emulate\/rg3ds",
"cancel_url": "https:\/\/payment.dvipdev.com\/emulate\/rg3ds",
"order_type": "basic",
"pp_config": {
"ppac_id": "74",
"force_3ds": "1"
},
"md": "1000175B2AAB663"
},
"token": "dating-frontend-m1@staging",
"pass": "***"
},
"ts": 1605020372,
"origin_ip": "69.61.68.253",
"errors": null
}
```