Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds Invoice ID to DoCapture calls #PFW-222 #1185

Merged
merged 1 commit into from
Aug 14, 2018

Conversation

mgmartel
Copy link
Contributor

Since July 26th Paypal has been refusing our captures of authorized Paypal Express payments with error code 10003 and the message: "Invoice ID is required".

Though the documentation still doesn't indicate that Invoice IDs are required on DoCapture calls, we found that adding the INVNUM parameter fixes the issue.

This PR looks for the invoice id prefix on the payment gateway and adds the INVNUM accordingly.

  • I have only tested this with PayPal Express. Maybe this change should be limited to PPEC only?
  • The invoice ID is generated on the fly. If the user changes the invoice ID prefix between authorizatino & capture, this fix will generate the wrong Invoice ID. Should the Invoice ID be stored as post meta?

@angelleye
Copy link
Collaborator

Thanks for the feedback on this. Rather than generate a random value we should probably just send the same value that would have been sent with the original authorization, which would be the Woo Order ID (WP Post ID). It would also include any invoice prefix value set in our options.

We'll make necessary adjustments here and get this included in our next update. Thanks again!

@kcppdevelopers kcppdevelopers merged commit 834382f into angelleye:release Aug 14, 2018
@kcppdevelopers kcppdevelopers changed the title Adds Invoice ID to DoCapture calls Adds Invoice ID to DoCapture calls #PFW-222 Aug 14, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants