PayPal ExpressCheckout - You do not have permission to make this API call - paypal

I have integrated a simple online form that demands some input from the user and has the item and pricing information in hidden fields.
After the user verified his inputs he hits the button to pay with PayPal and will be redirected to PP where he can pay instantly.
The PP URL is
https://api-3t.sandbox.paypal.com/nvp
for the sandbox and
https://api-3t.paypal.com/nvp
for the live environment paypemnt.
In the sandbox everything works fine when I use the sandbox credentials. After I set the URLs to live, changing the API credentials to the live credentials I am receiving the error
You do not have permission to make this API call.
I have tested and verified the following:
the PP account is a business account and verified
the form has been checked and approved as PP app by PayPal
the form uses the correct API credentials
set "Accept payments from your shop before configuring an API" to "YES" and saved it with the submit/save button
checked the http request parameter live and they are looking fine
The error occours after sending the parameters from setExpressCheckoutData().
Now I am confused. I've red some infos to set MODE "test" to "live" at the end of the cart but don't know exactly what that means.
Please help.

Found the reason and fixed it.
Removed the parameter "subject" from the request data. If this parameter isn't passed (I think it is necessary for Unipay only) the ExpressCheckout works fine.
In the sandbox it doesn't matter wether to use this parameter or not.

Related

Why PayPal IPN work on Simulator, but not working on sandbox?

I made a copy of this script on my server. And when I test it on IPN simulator in the developer panel, and everything is fine - I get emails and the logs are saved. But when I try to test the same script via sandbox facilitator account, the script does not work. I added the URL of the IPN script in the settings and I'm testing as buyer account.
Tell me please, what else can check?
You need to make sure you've configured the SELLER sandbox account you're using with the IPN URL that you are testing.
Also, make sure this is not getting overridden by the PayPal button or API integration you are testing with. For example, the Notify URL parameter can be used to specify an IPN URL in payment requests, and this would override anything set at the account level.
If you have the URL set properly, and you don't have an override, it should hit that URL as expected. You can check the IPN History of the sandbox seller account to verify whether or not IPNs are getting sent.

Cannot access Paypal Sandbox Accounts

PayPal:
Cant access paypal sandbox - if trying to appraoch directly, you are being redirected to the paypal main site.
If trying to reach the sandbox via the paypal developer site,
browsed to Dashboard>Sandbox>accounts,
(find the facilitator and buyer accounts - which apperently do require decent passwords to work) than press "Click Me" just to fail again by being redirected to a page indicating:
"We're sorry.
Relying party validation error: client_id or redirect_url provided in the request does not match any of the registered clients. Please check the request and try again."
OK, found a way aroudn this.
Problem: For some reason if you are a PayPal user and also wish to use the sandbox (in my case I have a seperate private account and a business account, and the sandbox is used by the busienss account), any attempt to approach the sandbox results in being redirected to paypal main site (at least in my region).
Solution: Use a seperate cognito or private window for the sandbox - never login to you your own account while working with the sandbox, and if you do, restart the browser and get a new private window.

Paypal DG Express Cannot Use Sandbox. Live Account Works Fine

I have a Paypal Digital Goods Express payment form created using their wizard.
When I use our live account it works fine. But when I use the sandbox Business (Seller) account I created, when a user clicks on the 'Buy' button, the popup window appears with only this message:
SetExpressCheckout API call failed. Detailed Error Message: Short Error Message: Error Code: Error Severity Code:
I did some research and saw this article:
https://www.paypal-knowledge.com/infocenter/index?page=content&widgetview=true&id=FAQ1914&viewlocale=en_EN
It suggests that our hosting company needs to update their PHP/TLS, but I did the Curl test and it properly returns a 200 OK.
I also saw this Stackoverflow article:
Paypal "SetExpressCheckout" API method has stopped working with sandbox seller account
...where the problem was the wrong sandbox endpoint, but I've made sure that the endpoint is indeed:
https://api-3t.sandbox.paypal.com/nvp
...and it still doesn't work.
I've tried clearing my browser cache, using different computers to test and all with the same result.
Any ideas?
did you enable Digital Goods feature on your sandbox accounts?
If you have not enabled it on your sandbox account, please contact MTS(Merchant Technical Support)
https://www.paypal-techsupport.com/app/ask
to toggle it for your sandbox account.

paypal sandbox merchant account error

I have a website that I'm trying to hook paypal up to with a php script. php builds the query string and then submits to https://www.paypal.com/cgi-bin/webscr with the query string attached. I can verify that this works fine. I haven't processed a payment but it directs to PayPal with the correct quantities and prices, etc.
However when I change to https://www.sandbox.paypal.com/cgi-bin/webscr I get an error when I try to process that says there was a problem with the merchants PayPal account.
I have created several test accounts on PayPal sandbox but from what I can tell looking around it seems I need another merchant account in the sandbox? If so, I don't see how to do this. I'm guessing I need to change the "?business=mycode" portion of the query string but I don't know how to figure out what to change it to...
Anyway I looked around a while and can't find the answer, can anyone help or direct me to another post that answers this (I looked but couldn't find it, or at least didn't understand it if I did)?
When changing back from live to sandbox, all you should need to change if using a non hosted button is the URL to reflect the environment that you are trying to test with and the value of the business variable. This can be set to either your email address of the actual test or live seller account or the merchant id. If you have not already created an account for testing. You can do so by going to PayPal's Developer Site, and creating a developer account. Then once you have done this, you can log into the developer account and go to the Applications tab. Once on this page, click the link for sandbox accounts on the left, and create a preconfigured test seller account. This will generate an email address linked to a test account. This will be the email address that you will need to use. If this doesn't work, can you provide the string that you are submitting over to PayPal or the button code that you are using and I will take a look at it.
There is error in API key for sandbox testing in Paypal... It is due to corrupt key generation which is not properly decoded on sandbox server when you send a purchase request.
I tried using following sandbox public credentials and it works fine for me
username: sdk-three_api1.sdk.com
password: QFZCWN5HZM8VBG7Q
key: A-IzJhZZjhg29XQ2qnhapuwxIDzyAZQ92FRP5dqBzVesOkzbdUONzmOU
however I tried several times using the sandbox merchant account that i have created myself.... but was unable to ACK success.

Testing the PayPal Adaptive Paymemts API in the Sandbox

I want to simulate a simple scenario with the adaptive API. A seller, buyer and my app.
I created 3 test accounts in the Sandbox website:
Account named buyer - of type Personal.
Account named seller - of type Business.
Account named myApp - of type Business.
I am using the Adaptive Payments C#.Net code samples from paypal developers site. (The code I am using is inside csharp_nv_adaptivepayments.zip , in the Pay.cs file).
I changed sAPIUser, sAPIPassword, sAPISignature to match myApp (From API Credentialns page in SandBox site)
I changed sReceiverEmail to the seller email.
I changed sSenderEmail to the buyer email.
After sending the request to https://svcs.sandbox.paypal.com/AdaptivePayments/Pay ,
and getting the response with sResponse = oStreamReader.ReadToEnd(); I get an OK status and I have a payKey in my hand.
Now, as the AdaptivePayments PDF says (P. 70) I need to redirect the user to
https://www.paypal.com/webscr?cmd=_ap-payment&paykey=value , So I use Response.Redirect() to this url. When the browser loads the page, I get a java script error in:
var sf = new PAYPAL.AP.Subflow();
Stating that "Object doesn't support this action".
I tried to change the url to http://www.sanbox.paypal....paykey=value but then I just get a white page , saying "Please login to use the PayPal Sandbox features."
Also, in both cases i didn't see any payment activity in the seller,buyer logs.
What am I doing wrong here ?
Yaron,
To make Live API calls, you need to obtain a Live APP ID from PayPal,
For making sandbox calls, you need to properly set up the sandbox testing environment, AND be logged in to it beforehand.
This guide explains in detail what you need to do for each case:
Requires x.com free registration
http://www.x.com/servlet/JiveServlet/download/211264-21046/HelloMoney.zip
EDIT
X.com died a while back. I've posted my original files in GitHub:
https://github.com/lmarkus/AdaptivePaymentsExample