Paypal recurring payments with a variable amount of 2 (in Spain)

a few days ago I wrote this message about periodic Paypal payments with a variable amount of recurring Paypal payments with a variable amount

I marked it as fixed, but it is not.

First, I decided to develop approach 1 (deleting the old profile and creating a new one). It worked. But after that I realized that I did not cover all my requirements. So finally, the right approach for me is number 2. This means that, as @Andrew Angell suggested, I will develop my own billing system that pays customers. To do this, I will create billing agreements, and I will use the return identifiers to perform the reference transactions with the required amount and whenever I need it. Is it still right?

According to Paypal docs, this is possible: https://developer.paypal.com/docs/classic/express-checkout/integration-guide/ECReferenceTxns/

So, I'm trying to follow the steps, so do setExpressCheckout first:

# Paypal setExpressCheckout def setExpressCheckout(billingType, returnURL, cancelURL, price, description) @api = PayPal::SDK::Merchant::API.new if billingType == "credit-card" billingType = "Billing" else billingType = "Login" end @set_express_checkout = @api.build_set_express_checkout({ SetExpressCheckoutRequestDetails: { ReturnURL: returnURL, CancelURL: cancelURL, LocaleCode: "US", LandingPage: billingType, PaymentDetails: [{ NotifyURL: returnURL, OrderTotal: { currencyID: "EUR", value: price }, ShippingTotal: { currencyID: "EUR", value: "0" }, TaxTotal: { currencyID: "EUR", value: "0" }, PaymentDetailsItem: [{ Name: description, Quantity: 1, Amount: { currencyID: "EUR", value: price }, }], PaymentAction: "Authorization" # To authorize and retain the funds, and when booking is confirmed capture them. }], BillingAgreementDetails: [{ BillingType: "MerchantInitiatedBillingSingleAgreement", BillingAgreementDescription: description }] } }) # Make API call & get response @express_checkout_response = @api.set_express_checkout(@set_express_checkout) # Access Response if @express_checkout_response.success? @token = @express_checkout_response.Token puts "setExpressCheckout completed OK :)" @paypal_url = @api.express_checkout_url(@express_checkout_response) else puts "setExpressCheckout KO :(" @express_checkout_response.Errors puts "@express_checkout_response=" + @express_checkout_response.inspect end @express_checkout_response end 

However, I get this error:

 @LongMessage="Merchant not enabled for reference transactions", @ErrorCode="11452" 

Clearly, you just need to contact Paypal support resellers and ask them to include transaction links in my sandbox Paypal account. Correctly? I have already done this, and I'm just waiting.

However, I am really worried that I called Paypal support and they told me that this approach would not work in Spain. Although it is in the document, it only works in the UK. It's true?

If this is true, I really have problems because, as far as I know, Paypal does not support variable subscriptions.

+1
ruby-on-rails paypal express-checkout
source share
1 answer

Paypal Technical Assistant has enabled my sandbox account for transaction links. I developed the logic and it works. At least in the Sandbox and in Spain.

So, suppose this works.

The bad Paypal guy on the phone who told me this was not possible.

+1
source share

All Articles