Adding card to Vault

I remain confused about this requirement: "You need to send Purchase or Preauthorization or Card verification with Credential on File fields as the first transaction before you do Vault add Credit Card."  I've added a card to the vault for unscheduled transactions in a test store and made a transaction with it but am unconvinced it'll work in production.

My code:

            /********************** Post Request Variables *************************/
            string host = ConfigurationManager.AppSettings["MonerisHost"];
            string storeId = ConfigurationManager.AppSettings["MonerisStore"];
            string apiToken = ConfigurationManager.AppSettings["MonerisApiToken"];
            string processingCountryCode = "CA";
            bool statusCheck = false;
            Boolean error = false;
            string errorMsg;

            // Address Verification Service
            AvsInfo avsCheck = new AvsInfo();
            avsCheck.SetAvsStreetNumber(memberPaymentMethod.BillingAddressLine1);
            avsCheck.SetAvsStreetName(memberPaymentMethod.BillingAddressLine2);
            avsCheck.SetAvsZipCode(memberPaymentMethod.BillingAddressPostalCode);

            // Card Validation Digits
            CvdInfo cvdCheck = new CvdInfo();
            cvdCheck.SetCvdIndicator("1");
            cvdCheck.SetCvdValue(memberPaymentMethod.CVV);

            CofInfo cof = new CofInfo();
            cof.SetIssuerId("168451306048014");
            cof.SetPaymentIndicator("U"); //U - unscheduled merchant-initiated transaction
            cof.SetPaymentInformation("0");

            ResAddCC resaddcc = new ResAddCC();
            resaddcc.SetCustId(GetMemberId(memberPaymentMethod.ContactId).ToString());
            resaddcc.SetPan(memberPaymentMethod.CardNumber);
            resaddcc.SetExpDate(memberPaymentMethod.ExpiryYearMonth.ToString());
            resaddcc.SetCryptType("7");
            resaddcc.SetDataKeyFormat("0U");
            resaddcc.SetCofInfo(cof);
            resaddcc.SetAvsInfo(avsCheck);

            HttpsPostRequest mpgReq = new HttpsPostRequest();
            mpgReq.SetProcCountryCode(processingCountryCode);
            mpgReq.SetTestMode(true); //false or comment out this line for production transactions
            mpgReq.SetStoreId(storeId);
            mpgReq.SetApiToken(apiToken);
            mpgReq.SetTransaction(resaddcc);
            mpgReq.SetStatusCheck(statusCheck);
            mpgReq.Send();

            Receipt receipt = mpgReq.GetReceipt();

Can I simply make a transaction against this card now? I don't see where cvdCheck is used.

  • Hello,

    You can add a credit card to the vault with or without cvd. If you add it without cvd, when the token is used to process a transaction you will need to send cvd with the token to process the transaction. You can give it a try by testing a transaction with APIs. If you have more questions, feel free to e-mail eproducts@moneris.com
  • In reply to RamiY:

    I won't have the CVV when processing actual transactions as these are unscheduled future transactions. How do I add a credit card to the vault with CVD? I can't find it in developer.moneris.com/.../Vault
  • In reply to Neil:

    Hello Neil,

    You can use hosted tokenization to store the cvd into the vault. I would reocmmend looking into the following link:
    developer.moneris.com/.../Card Verification

    Specifically in the CVD section.

    Best regards