Class BuyerAuthVETransaction
After a successful Verify Enrollment Transaction, you should redirect the user's browser to his/her banks secure authentication server which will authenticate the user. While redirecting to this secure authentication server, you must pass the parameter PaReq obtained in the response of this transaction. For more information, please refer to the Payflow Developers' Guide.
This example shows how to create and perform a Verify Enrollment transaction. *.......... .......... //Populate required data objects. *
//Create the Card object. CreditCard card = new CreditCard("XXXXXXXXXXXXXXXX","XXXX"); *
//Create the currency object. Currency amt = new Currency(new decimal(1.00),"US"); .......... .......... *
//Create a new Verify Enrollment Transaction. BuyerAuthVETransaction trans = new BuyerAuthVETransaction( UserInfo, PayflowConnectionData, Card, Amt, RequestId); //Submit the transaction. trans.SubmitTransaction(); *
// Get the Response. Response resp = trans.getResponse(); if (Resp != null) { // Get the Transaction Response parameters. TransactionResponse trxnResponse = resp.getTransactionResponse(); if (trxnResponse != null) { System.out.println("RESULT = " + trxnResponse.getResult()); System.out.println("RESPMSG = " + trxnResponse.getRespMsg()); } *
// Get the Buyer auth Response parameters. BuyerAuthResponse bAResponse = resp.getBuyerAuthResponse(); if (bAResponse != null) { System.out.println("AUTHENTICATION_STATUS = " + bAResponse.getAuthenticationStatus()); System.out.println("AUTHENTICATION_ID = " + bAResponse.getAuthenticationId()); System.out.println("ACSURL = " + bAResponse.getAcsUrl()); System.out.println("PAREQ = " + bAResponse.getPaReq()); } } // Get the Context and check for any contained SDK specific errors. Context ctx = resp.getTransactionContext(); if (ctx != null ++ ctx.getErrorCount() %3E 0) { System.out.println("Errors = " + Ctx.ToString()); }
-
Field Summary
Fields inherited from class paypal.payflow.BaseTransaction
requestId -
Constructor Summary
ConstructorsConstructorDescriptionBuyerAuthVETransaction(UserInfo userInfo, CreditCard creditCard, Currency currency, String requestId) Constructor.BuyerAuthVETransaction(UserInfo userInfo, CreditCard creditCard, PayflowConnectionData payflowConnectionData, Currency currency, String requestId) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionprotected voidGenerates the transaction request.Gets, Sets Purchase description.voidsetPurDesc(String purDesc) Methods inherited from class paypal.payflow.BaseTransaction
addHeader, clearExtendData, getBuyerAuthStatus, getClientInfo, getContext, getExtData, getRequest, getRequestBuffer, getRequestId, getResponse, getTender, getTrxType, getVerbosity, RemoveTransHeader, setBuyerAuthStatus, setClientInfo, setContext, setExtData, setRequestId, setTender, setVerbosity, submitTransaction
-
Constructor Details
-
BuyerAuthVETransaction
public BuyerAuthVETransaction(UserInfo userInfo, CreditCard creditCard, PayflowConnectionData payflowConnectionData, Currency currency, String requestId) Constructor.- Parameters:
userInfo- - User Info object populated with user credentials.creditCard- - Credit card information for the user.payflowConnectionData- - Connection credentials object.currency- - Currency valuerequestId- - StringAfter a successful Verify Enrollment Transaction, you should redirect the user's browser to his/her banks secure authentication server which will authenticate the user. While redirecting to this secure authentication server, you must pass the parameter PaReq obtained in the response of this transaction.
-
BuyerAuthVETransaction
public BuyerAuthVETransaction(UserInfo userInfo, CreditCard creditCard, Currency currency, String requestId) Constructor.- Parameters:
userInfo- UserInfo object populated with user credentials.creditCard- Credit card information for the user.currency- Currency valuerequestId- StringAfter a successful Verify Enrollment Transaction, you should redirect the user's browser to his/her browser to the secure authentication server which will authenticate the user. While redirecting to this secure authentication server, you must pass the parameter PaReq obtained in the response of this transaction.
-
-
Method Details
-
getPurDesc
Gets, Sets Purchase description.Maps to Payflow Parameter -
PUR_DESC- Returns:
- purDesc
-
setPurDesc
- Parameters:
purDesc- String
-
generateRequest
protected void generateRequest()Generates the transaction request.- Overrides:
generateRequestin classBaseTransaction
-