PayPal API error INVALID_PROFILE_ID - paypal

I am using the PHP SDK, other API calls, like getting payment information work so the configuration is correct.
What I am trying to do is starting from a payment ID to find the billing agreement, check the agreement details and in some cases attempt to update it.
From the documentation I see only the billing agreement ID is the requiered parameter https://developer.paypal.com/docs/api/payments.billing-agreements/v1/#billing-agreements_get
so I do not understand what profile is this error mentioning, is the payment/transaction/payer missing some profile or other profile ?

That PHP SDK is deprecated and does not support the current version of PayPal Subscriptions, documented here.
There is no supported SDK for it; use a direct HTTPS integration for any server-side API calls.

Related

How to test failed PayPal transactions through Braintree SDK

I am using Braintree SDK on ASP.NET Core and I can create transactions using the access code generated from developers.paypal.com however all transactions are accepted by the payment processor and gateway.
I've tried to enter the magic amounts that are supposed to trigger declines as listed on the Braintree documentation however I think that they only work when you use a Braintree sandbox access token and not a PayPal sandbox access token (mentioned here). I've tried using an error code as an amount as documented on the PayPal API documentation here but that was accepted as well as a valid amount and the transaction went through.
Do I have to sign up for a Braintree sandbox account and to be able to get one of the decline codes documented here?
Full Disclosure: I work at Braintree. If you need any further assistance, feel free to contact support.
If you are using the PayPal access codes, in order to receive the decline codes, you'll want to use the mocked checkout flow and will need to setup a Braintree sandbox.

I want to know about TransactionSearch API ( which is deprecated ) for 2017 on PayPal

I know before 2017, the PayPal provides the Api which I can get all the transaction history via Rest API .
that is TransactionSearch using NVP.
but PayPal says it has been deprecated.
so I want to know ,how can I get transaction history via PayPal API.
Looking forward your help.
Although PayPal deprecated the classic API, you can also use all of the classic APIs(containing TransactionSearch API), PayPal just will not renew or develop new feature. But all of current functions can be used.
And if you want to use transaction search function under REST API, please refer following URL.
https://developer.paypal.com/docs/integration/direct/payments/paypal-payments/?mark=list%20payment#search-payment-details
Please refer "List payments with transaction details" section.
API document: https://developer.paypal.com/docs/api/payments/#payment_list

Transaction description and app name not showing with PayPal REST API

I am using PayPal Payments REST API to accept payments on some website.
Just now I noticed that both the transaction description as well as the app name (which you configure in developer dashboard) are no longer displayed. Why is this? Some recent change? Or something with my account?
It is very bad as I have a single company PayPal account which I use for various websites and the app name & transaction description is to give the corresponding payment flows their own identity. Currently people abort payments because they don't understand why the details in the payment overview on PayPal are completely different/unrelated from where they initiated payment.
Please see image below for what I mean.
If anyone can confirm this is happening for everyone now and/or refer to some PayPal documentation/statement regarding this topic then please share. I could not find anything on PayPal developer resources.
To display a 'custom' name, you need to create a custom 'Web experience profile'.
I was utilising the PHP SDK so did so by following their sample code.
You can also create a 'Web experience profile' with a direct request to the relevant API endpoint.
Once you have created the profile you simply set the identifier on the Payment object (PHP) like so:
$payment->setIntent("sale")
->setPayer($payer)
->setRedirectUrls($redirectUrls)
->setTransactions(array($transaction))
->setExperienceProfileId($this->config->paypal->experienceId);

How to retrieve from Client Buyer's Account his avaliable 'funds' or 'balance' on PayPal API?

I've just setup my PayFlow Service Manager with my admin settings and create a Sandbox Account to have a test environment. I was reading the docs and the SDK specifications, the samples code on Java...But I still can't find how to know how much funds available have the Client on his PayPal account, before execute a payment in my Site...
I found something of the classic API (GetBalance). This request doesn't exists yet on the new REST API. I need to implement on Java code.
Please Help! Thanks!

Paypal Mobile SDK cannot proceed payment, received unknown error

I wonder if anyone can help me with this problem. I receive this error from my iOS SDK, for 2 attempted requests:
2015-01-22 16:14:32.238 Page Advisor Consumer[6442:607] PayPal SDK: Request has failed with error: UNKNOWN_ERROR - System error (UNKNOWN_ERROR). Please try again later. (400) | PayPal Debug-ID: be3d18e185478 [live, PayPal iOS SDK 2.8.2]
2015-01-22 16:15:06.557 Page Advisor Consumer[6442:607] PayPal SDK: Request has failed with error: UNKNOWN_ERROR - System error (UNKNOWN_ERROR). Please try again later. (400) | PayPal Debug-ID: 52795d8d95006 [live, PayPal iOS SDK 2.8.2]
I wonder what cause this error. Because when I use direct payment REST API there seems to be no problem at all. I already use US Account. Please tell me if i need to provide anymore details. Thank you guys!
UPDATE::!!
I have done further testing, turns out that Mobile SDK somehow cannot create transaction in SGD if connected to a US account, while REST API allows it. Turns out the SDK needs Singapore Account in order to proceed.
The problem is Singapore Account cannot use the newest SDK. Any solution for this? I really desperately need the newest SDK to work with SGD, because the current REST API allows it.
Thanks
I looked up the debug IDs you provided (both Live and Sandbox) and they were all failing for the same reason: unsupported currency for direct credit card transactions.
SGD is not a supported currency for Direct Credit cards with the REST APIs. A list of supported direct credit card currencies can be found here. SGD is a supported currency for PayPal payments with the REST APIs. Since the mSDK sits on top of the REST APIs, the supported currency list for REST and mSDK are one and the same.
As for the error message itself, I will put in a request with the appropriate folks to see if we can display something a bit more informative.