cancel
Showing results for 
Search instead for 
Did you mean: 

Mastercard ASI (Account Status Inquiry) support

Hi,

 

Mastercard have an ASI (Account Status Inquiry) service which is useful for verifying card details without submitting transactions.

 

Do any of the Authorize.NET APIs support Mastercard ASI functionality or does Authorize.NET integrate with Mastercard ASI behind the scenes for zero dollar value authOnly transactions?

 

Thanks.

smrdev75
Member
7 REPLIES 7

Hi @smrdev75

 

You should be able to use the validate customer profile API for this 

 

https://developer.authorize.net/api/reference/index.html#customer-profiles-validate-customer-payment...

 

 

validationMode Indicates the processing mode for the request. If the customer profile contains no payment data, this field should not be sent.

String.

Use testMode to perform a Luhn mod-10 check on the card number, without further validation. Use liveMode to submit a zero-dollar or one-cent transaction (depending on card type and processor support) to confirm the card number belongs to an active credit or debit account.




Send feedback at developer_feedback@authorize.net
Anurag
Moderator Moderator
Moderator

Hi 

 

Thanks for the reply.

 

I don't think the Customer Profile API is relevant to my use case as I do not use customer profiles. I've recently taken ownership of some code which uses the following endpoint:

 

https://test.authorize.net/gateway/transact.dll 

 

Does this API have any sort of card verification service?

 

I know some other payment services providers have zero dollar value auth services which allow cards to be verified.

 

Thanks.

 

Syed.

Hi Syed

 

https://test.authorize.net/gateway/transact.dll is our legacy API endpoint, we recommend to use our new endpoint https://apitest.authorize.net/xml/v1/request.api

 

But to answer your question, 

Mastercard ASI is a service only for Mastercard brand cards but if you want validate any brand card you can do a $0 transaction and validate it, although it depends on if the processor you have opted for supports $0 transaction.

 

Or another way is do a fixed amount transaction and later void it.

 

Thanks

Kaushik

kikmak42
Authorize.Net Expert Authorize.Net Expert
Authorize.Net Expert

I have 2 requirements at the moment.

 

1. I need to understand whether Authorize.NET integrate with the Mastercard ASI (Account Status Inquiry) service (I understand that this is only for Mastercard branded cards). If so, which of the Authorize.NET APIs do I use to take advantage of Mastercard ASI functionality?

 

2. On the new endpoint https://apitest.authorize.net/xml/v1/request.api  what request do I send to do a $0 auth and validate?

 

Thanks.  

 

1. I need to understand whether Authorize.NET integrate with the Mastercard ASI (Account Status Inquiry) service (I understand that this is only for Mastercard branded cards). If so, which of the Authorize.NET APIs do I use to take advantage of Mastercard ASI functionality?

 

[Bhavana]:  It depends on the processor and its card type features where the zero dollar auth is supported. Which processor are you trying to integrate to for your transactions?

 

 

2. On the new endpoint https://apitest.authorize.net/xml/v1/request.api  what request do I send to do a $0 auth and validate?

 

[Bhavana]: Pls. use the following to make the zero dollar auth. Below is the certTest request

<createTransactionRequest xmlns="AnetApi/xml/v1/schema/AnetApiSchema.xsd">
  <merchantAuthentication>
    <name>78BZ5Xprry</name>
    <transactionKey>8s2F95Q7brhHd7Tn</transactionKey>
  </merchantAuthentication>
  <refId>123456</refId>
  <transactionRequest>
    <transactionType>authOnlyTransaction</transactionType>
    <amount>0</amount>
    <payment>
      <creditCard>
        <cardNumber>5424000000000015</cardNumber>
        <expirationDate>2020-12</expirationDate>
        <cardCode>999</cardCode>
      </creditCard>
    </payment>
    <order>
     <invoiceNumber>INV-12345</invoiceNumber>
     <description>Product Description</description>
    </order>
    <lineItems>
      <lineItem>
        <itemId>1</itemId>
        <name>vase</name>
        <description>Cannes logo </description>
        <quantity>18</quantity>
        <unitPrice>45.00</unitPrice>
      </lineItem>
    </lineItems>
    <tax>
      <amount>4.26</amount>
      <name>level2 tax name</name>
      <description>level2 tax</description>
    </tax>
    <duty>
      <amount>8.55</amount>
      <name>duty name</name>
      <description>duty description</description>
    </duty>
    <shipping>
      <amount>4.26</amount>
      <name>level2 tax name</name>
      <description>level2 tax</description>
    </shipping>
    <poNumber>456654</poNumber>
    <customer>
      <id>99999456654</id>
    </customer>
    <billTo>
      <firstName>Ellen</firstName>
      <lastName>Johnson</lastName>
      <company>Souveniropolis</company>
      <address>14 Main Street</address>
      <city>Pecan Springs</city>
      <state>TX</state>
      <zip>44628</zip>
      <country>USA</country>
    </billTo>
    <shipTo>
      <firstName>China</firstName>
      <lastName>Bayles</lastName>
      <company>Thyme for Tea</company>
      <address>12 Main Street</address>
      <city>Pecan Springs</city>
      <state>TX</state>
      <zip>44628</zip>
      <country>USA</country>
    </shipTo>
    <customerIP>192.168.1.1</customerIP>
    <userFields>
      <userField>
        <name>MerchantDefinedFieldName1</name>
        <value>MerchantDefinedFieldValue1</value>
      </userField>
      <userField>
        <name>favorite_color</name>
        <value>blue</value>
      </userField>
    </userFields>
  </transactionRequest>
</createTransactionRequest>
bhav
Authorize.Net Expert Authorize.Net Expert
Authorize.Net Expert

Hi there, I tried to implement the above code using the sample code https://github.com/AuthorizeNet/sample-code-java for Zero Pre Auth but is failing. Please find below the details.

 

I am trying to make a authOnlyTransaction with amount 0 to cater Mastercard ASI requirements. The transaction is failing with transaction error code 290 (There is one or more missing or invalid required fields.) and resultCode "ERROR" with code "E00027"

I am able to make successful transaction if I change the amount to a non zero value.

Environment: Sanbox 
Request data structure:

{
  "merchantAuthentication": {
    "name": "-removed-",
    "transactionKey": "-removed-",
    "sessionToken": null,
    "password": null,
    "impersonationAuthentication": null,
    "fingerPrint": null,
    "clientKey": null,
    "accessToken": null,
    "mobileDeviceId": null
  },
  "clientId": null,
  "refId": "12345",
  "transactionRequest": {
    "transactionType": "authOnlyTransaction",
    "amount": 0.00,
    "currencyCode": null,
    "payment": {
      "creditCard": {
        "cardNumber": "4242424242424242",
        "expirationDate": "0822",
        "cardCode": "123",
        "isPaymentToken": null,
        "cryptogram": null,
        "tokenRequestorName": null,
        "tokenRequestorId": null,
        "tokenRequestorEci": null
      },
      "bankAccount": null,
      "trackData": null,
      "encryptedTrackData": null,
      "payPal": null,
      "opaqueData": null,
      "emv": null,
      "dataSource": null
    },
    "profile": null,
    "solution": null,
    "callId": null,
    "terminalNumber": null,
    "authCode": null,
    "refTransId": null,
    "splitTenderId": null,
    "order": null,
    "lineItems": null,
    "tax": null,
    "duty": null,
    "shipping": null,
    "taxExempt": null,
    "poNumber": null,
    "customer": null,
    "billTo": null,
    "shipTo": null,
    "customerIP": null,
    "cardholderAuthentication": null,
    "retail": null,
    "employeeId": null,
    "transactionSettings": null,
    "userFields": null,
    "surcharge": null,
    "merchantDescriptor": null,
    "subMerchant": null,
    "tip": null,
    "processingOptions": null,
    "subsequentAuthInformation": null,
    "otherTax": null,
    "shipFrom": null
  }
}

Response:

{
      "refId": "12345",
      "messages": {
        "resultCode": "ERROR",
        "message": [
          {
            "code": "E00027",
            "text": "The transaction was unsuccessful."
          }
        ]
      },
      "sessionToken": null,
      "transactionResponse": {
        "responseCode": "3",
        "rawResponseCode": null,
        "authCode": "",
        "avsResultCode": "P",
        "cvvResultCode": "",
        "cavvResultCode": "",
        "transId": "0",
        "refTransID": "",
        "transHash": "0361773D30A57757263264653B9B5EAA",
        "testRequest": "0",
        "accountNumber": "XXXX4242",
        "entryMode": null,
        "accountType": "Visa",
        "splitTenderId": null,
        "prePaidCard": null,
        "messages": null,
        "errors": {
          "error": [
            {
              "errorCode": "290",
              "errorText": "There is one or more missing or invalid required fields."
            }
          ]
        },
        "splitTenderPayments": null,
        "userFields": null,
        "shipTo": null,
        "secureAcceptance": null,
        "emvResponse": null,
        "transHashSha2": "9BE4002C112F9674B30F6202138EE717C23383A7B422912D27EDA6C4ACB0EFBF5764FDAF9B67A5F6AF33DCEFD857581A22DD12BFD1961FE17465AF7412173C0C",
        "profile": null,
        "networkTransId": null
      },
      "profileResponse": null
    }

I managed to make a successful request with amount 0 by providing data for "billTo" input parameter. "billTo": { "address": "14 Main Street", "zip": "44628" } The address and zip fields seems mandatory if the amount is zero. For non zero amounts, they are optional. 

 

curl -X POST \
  https://apitest.authorize.net/xml/v1/request.api \
  -H 'Content-Type: application/json' \
  -H 'Postman-Token: b5e8194e-2ca6-417c-af47-ac079133abbd' \
  -H 'cache-control: no-cache' \
  -d '{
   "createTransactionRequest": {
      "merchantAuthentication": {
         "name": "--removed--",
         "transactionKey": "--removed--"
      },
      "transactionRequest": {
         "transactionType": "authOnlyTransaction",
         "amount": "0",
         "payment": {
            "creditCard": {
               "cardNumber": "4007000000027",
               "expirationDate": "2020-12"
            }
         },
         "billTo": {
            "address": "14 Main Street",
            "zip": "44628"
         }
      }
   }
}'

Can anyone please update why this fields are mandatory only for amount zero?