This weekend we were all set for a soft invitation-only launch. Until we realized we couldn’t get paid. That’s bad for business.
It’s all my fault. I was charged with the task of enabling users to leave us with their sweet bundles of cash. Easy enough, I thought.
Since we are hosting our backend with Parse.com (an excellent «Backend as a Service»), we would ideally use Stripe.com for payments, since they are nicely integrated with Parse.com. Only problem is, you need a US or UK registered business and bank account to use Stripe.com.
We have neither. Yet.
We decided to go for PayPal’s new REST API instead. It has a beautiful little SDK for Node.js. I had to build a little payment proxy outside of Parse.com, since Parse.com doesn’t allow using just any package, only ones they have pre-approved.
A few hundred lines of code later it all works in sandbox mode, and we are good to go.
Until we test it in our production environment. Nothing works as expected. After some intense debugging, I finally go to PayPal’s developer portal to triple-check the settings. That’s when I see the fine print:
«PayPal’s new REST API is not available outside of the US.»
Actually, the print isn’t all that fine. It’s staring at my face – and I wonder why I didn’t see this before.
Let this be a reminder to all of you, to make absolutely sure that a service will work for you before you spend your precious hours implementing it.
In the meantime, we will have to do PayPal’s standard payment and manually update users’ credit balances on a regular basis.