I am implementing the creation of encrypted Paypal buttons using their Button Manager API. Despite all my efforts I am facing the error 11945 The button country and language code combination specified is invalid.
.
First I tried to implement the creation of my own button but while tracing this error, I ended up with their tutorial using curl
, which fails for me too with the same error. (Note: I had to change the credentials to mine).
To be specific, this code from their tutorial fails with the error 11945:
curl https://api-3t.sandbox.paypal.com/nvp \
-s \
--insecure \
-d USER=<my-user-name> \
-d PWD=<my-password> \
-d SIGNATURE=<my-signature> \
-d VERSION=51.0 \
-d METHOD=BMCreateButton \
-d BUTTONCODE=ENCRYPTED \
-d BUTTONTYPE=CART \
-d BUTTONSUBTYPE=PRODUCTS \
-d BUTTONCOUNTRY=US \
-d L_BUTTONVAR1=item_name%3Dshoehorn \
-d L_BUTTONVAR2=amount%3D1464.46 \
-d L_BUTTONVAR3=tax=%3D21 \
-d L_BUTTONVAR4=item_number%3D123456
I tried to figure out why is that but I haven't found any relevant sources.
Can anyone explain this issue? The country code is set to US
, which should be fine.
All help will be appreciated.
Note: I am using the sandbox right now.
Note: Defining locale through lc
attribute does not help. I tried en
as well as en_US
values.
After a discussion with the Paypal support, there is the conclusion.
Short version: It's a bug.
Long version (by moderator MTS_Ciaran):
Thanks, so this looks like a bug on the sandbox from what I can see. The issue is that the account is CZ and for some reason we're not allowing the button creation because of that. It doesnt look to be the same on the live environment so I would suggest using a US account for testing and once live the CZ account shouldn't be an issue.
I'll work internally to get the sandbox corrected for this.