Tuesday, August 2, 2011

PayPal: Why their mobile integration grinds my gears

Sometimes it is frustrating to see a company or business excel at something and then be so bad at advertising it! PayPal's mobile integration makes that list because it doesn't show up in the first page of google search results.

Why would you have something so awesome but fail to show-up when people search for you? Perhaps they are protected against search engine crawlers? Anyway, allow me to break it down for you the reader, who found this blog through a google search ... and let you know what I think is the best way to get up and running with the PayPal iPhone in-app payment awesomeness:
  1. The 1st 4 slides are enough to put a smile on any face: Mobile Express Checkout - best practices
  2. Here's the landing pad for mobile devs. Let me make it even simpler, get this reading material in the following order:
    1. Mobile Payments Library Developer Guide and Reference – iOS Edition
    2. Sandbox User Guide
    3. PayPal Express Checkout Integration Guide
  3. Only importing the PayPal header files and libPayPalMEP.a is not enough. There are a few indirect dependencies too, you can figure out what they are by looking at the configuration for the Simple and Interactive demos ... so make sure to add them to your project as well:
    • libz.dylib
    • libxml2.dylib
    • Security.framework
  4. You will probably have no trouble with the simple integration but as your business model and transactions become more & more complex, you'll run into error codes which will be hard to make heads or tails of. At that time sign-in to your PayPal developer account and refer to
    DOC-1412 for the meaning behind the cryptic codes.
    • One example of such a cryptic code is 589023, which maps to: "If a fractional amount is rounded due to currency conversion, funds could be lost"
    • Now this is confusing on a whole different level because there may not be any currency conversion involved in the transaction at all! So the error might seem to make no sense at all BUT it turns out that PayPal just wants your app to submit NSDecimalNumbers that do not have more than 2 decimal places. I didn't understand this simple requirement until I came across this post. Luckily, this blog makes it clearer on how to apply such a policy when you have made a decision.

Happy coding!


Post a Comment