-
Notifications
You must be signed in to change notification settings - Fork 107
Getting 500 Internal Server Error, Php Api #648
Comments
Closing as a duplicate of #639 |
What does your request JSON look like with the payment_card object being used? |
Below is the response. Debug-id: e77c21ffb5281
|
Payment_method should be like this:
payment_card also requires "billing_country"; this comment has an example #639 (comment) |
How can I set payment_card to funding instruction? I didn't found this method in API. My code is as below for funding_instruction:
|
@malik-umair let me know if this helps. Use PaymentCard instead of CreditCard
This does have the extra required field of billing country though https://github.com/paypal/PayPal-PHP-SDK/blob/master/lib/PayPal/Api/PaymentCard.php#L272 Then set it as the funding instrument. Keep your payment_method as setPaymentMethod("credit_card") |
@pp-randy I've tried your suggestion and it worked. Thanks! Is this PayPal change or API change, due to which this issue occur? And are there any upcoming changes for recurring payment method with credit card? Thanks! |
@malik-umair this was an issue isolated to the sandbox but since PayPal documentation shows credit_card as deprecated using payment_card should be good to use going forward. However, to be clear credit_card should be supported for some time now the issue is isolated to the sandbox, and we are still working to resolve it. Using credit_card is still showing as current here for billing-agreement (recurring payment): https://developer.paypal.com/docs/api/payments.billing-agreements#definition-credit_card I will ask around and follow up on payment_card for billing agreements and see if something comes up. |
@pp-randy I had looked at the https://github.com/paypal/PayPal-PHP-SDK/blob/master/lib/PayPal/Api/FundingInstrument.php#L74 and the function setPaymentCard also marked as deprecated and Not publicly available. So how can we confirm which one is actually deprecated. |
Hey @avptechnocrats ! You are correct. We have deprecated |
Required Information
Issue Description
Below is my Test JSON request:
The text was updated successfully, but these errors were encountered: