Need Help With Express Checkout Implementation

williamyang93
Contributor
Contributor

I'm currently using Layout C and I'm able to have it appear in my web app. I'm able to successfully pay with Credit Card and it will go to the success URL. However, I'm trying to work with the express checkout as well. For some reason, when I produce the secure token via pilot.payflow, the pilot.payflow Express checkout doesn't work. It says the secure token has already been used. But when I change both links to payflow, it works. It takes me to the sandbox checkout. However when I finish, it tries to re-direct me to the pilot. There was also a time where I changed the Tender=S (this shouldn't have worked) but it did. Both of them were working oddly. And then I tried playing around with other Tender choices (C/P) the P would automatically load the checkout but then it'd bomb out for some reason. I tried changing it back to S but now the Express Checkout isn't working anymore. Can I get some assistance on implementing this?

 

My API call:

 

const response = await fetch("https://pilot-payflowpro.paypal.com", {
  method: "POST",
  headers: {
    "Content-Type": "application/x-www-form-urlencoded",
  },
  body: `PARTNER=<PARTNER>&PWD=<PW>!&VENDOR=<VENDOR>&USER=<VENDOR>&TENDER=S&ACCT=5105105105105100&TRXTYPE=S&EXPDATE=1234&AMT=1.01&CREATESECURETOKEN=Y&SECURETOKENID=${uuid}`,
});
<iframe
  src={`https://pilot-payflowlink.paypal.com/?SECURETOKEN=${secureToken}&SECURETOKENID=${uuid}`}
  width="600"
  height="400"
  frameBorder="0"
  allowtransparency="true"
></iframe>;

 

Login to Me Too
0 REPLIES 0

Haven't Found your Answer?

It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.