Successfully reported this slideshow.

Monetize with PayPal X Payments Platform

18,529 views

Published on

A workshop on monetization with PayPal Payments Platform

Monetize with PayPal X Payments Platform

  1. 1. www.x.com<br />Show me the money!<br />A workshop on monetization with PayPal Payments Platform<br />Praveen Alavilli, Aalap Parikh, Carolyn Mellor<br />PayPal Developer Network<br />Feb, 24th 2010<br />
  2. 2. agenda<br />Monetization<br />Payments 101<br />PayPal Services and APIs<br />Development Process<br />PayPal API Basics<br />SDKs and Tools<br />Implementation walk through<br />eCommerce<br />Subscriptions and Recurring Payments<br />Disbursements<br />mCommerce<br />Advanced Use cases with Adaptive Platform<br />Instant Payment Notifications (IPN)<br />Going Live<br />Tips on Security and Fraud<br />
  3. 3. Building and running an app is cheap<br />
  4. 4. a successful and profitable company needs<br />Good Monetization Strategy<br />
  5. 5. Advertising ?<br />What else ?<br />
  6. 6. eCommerce<br />Virtual Goods<br />Premium Content<br />Value added Services<br />Memberships<br />Subscription<br />License of Content, Brand and Services<br />
  7. 7. Before we get our hands dirty<br />A quick overview of what payments are.<br />
  8. 8. Payments 101<br />exchange of value from one party to another<br />As a developer, the sender and receiver may have many different names, depending on their role and objective.<br />
  9. 9. Payment Methods<br />Travelers checks<br />Bill payments<br />Check or draft<br />ACH payment<br />Cards, cards, cards<br />Net-based payments<br />Many others<br /><ul><li>each payment method has unique features and attributes
  10. 10. different technology to interface</li></ul>As a developer, you select the forms of payments that best fit your application and target the consumer experience.<br />
  11. 11. Credit Cards<br />usage of the card is authorized by the issuer in real time<br />PaymentSystem<br />Acquirer<br />Issuer<br />Consumer<br />Merchant<br />
  12. 12. How the Money moves<br />authorizations are captured immediately and settled in batch<br />PaymentSystem<br />Acquirer<br />Issuer<br />Consumer<br />Merchant<br />
  13. 13. Chargebacks<br />Consumers have the right to chargeback transactions.<br />PaymentSystem<br />Acquirer<br />Issuer<br />Consumer<br />Merchant<br />
  14. 14. Chargebacks<br />Consumers have the right to chargeback transactions.<br />The funds are withdrawn from the merchant’s account and credited to the consumer’s account.<br />PaymentSystem<br />Acquirer<br />Issuer<br />Consumer<br />Merchant<br />
  15. 15. Debit Cards<br />PaymentSystem<br />Acquirer<br />Issuer<br />Consumer<br />Merchant<br />
  16. 16. Debit Card differences<br />PaymentSystem<br />With debit cards, processed as a debit card, the authorization transaction and the settlement (capture) transaction are the same.<br />Money movement is in real time.<br />Acquirer<br />Issuer<br />Consumer<br />Merchant<br />
  17. 17. Bank Accounts & ACH<br />PaymentSystem<br />ODFI<br />RDFI<br />Consumer<br />Merchant<br />
  18. 18. PaymentSystem<br />With Automated Clearing House (ACH), there is no authorization transaction.<br />Money movement is batch.<br />ODFI<br />RDFI<br />Consumer<br />Merchant<br />Bank Accounts & ACH<br />
  19. 19. PayPal X Payments Platform<br />
  20. 20. Pay Anyone and Receive from Anyone<br />Really !<br />(an email address or a phone number)<br />
  21. 21. Facilitate Payments<br />Manage Accounts<br /> <br />Information and Reporting<br />
  22. 22. Simple to Advanced<br />enabling different kind of payments…<br />
  23. 23. Simple/Parallel/Chained Payments<br />Preapprovals<br />Subscriptions<br />Reference Transactions<br />Disbursements<br />Micropayments<br />Rewards<br />Donations<br />Digital Goods<br />Gift Certificates<br />
  24. 24. (while taking care of things that you don’t want to manage yourself)<br />Risk and Fraud Management<br />Security<br />Compliance<br />Settlements<br />Refunds/Charge backs<br />
  25. 25. How simple can it go ?<br />
  26. 26. Email Payments<br />(old school)<br />invoice over email from PayPal<br />Virtual Terminal<br />POS terminal on the Cloud !<br />accept payments over phone, mail, & fax<br />Website Payments Standard<br />(aka WPS or “cut & paste payments”)<br />buttons, buttons, buttons<br />
  27. 27. Simple but Powerful<br />Sell Single/Multiple Items (cart)<br />Subscriptions<br />Donations<br />Inventory Control<br />UI Customization<br />Fraud/Risk Controls<br />
  28. 28. Express Checkout<br />“all it takes is 3 API Calls”<br />a checkout solution & BML<br />Payflow <br />a payment gateway<br />Website Payments Pro<br />Direct Payments + Express Checkout<br />Mass Payments<br />disbursements <br />
  29. 29. Adaptive Platform<br />(Adaptive Payments & Adaptive Accounts)<br />for Web 2.0 and Web.Next applications<br />Parallel and Chained Payments<br />
  30. 30. chained<br />Parallel<br />Primary<br />Sender Visibility<br />Sender Visibility<br />
  31. 31. Adaptive Platform<br />Pre-approvals<br />Disbursements<br />Simplified Account Creation<br />Flexible APIs allow tighter integration<br />
  32. 32. PayPal X Platform<br />Checkout products <br />Express Checkout<br />Website Payments Pro<br />Website Payments Standard<br />Virtual Terminal<br />PayFlow Gateway<br />Adaptive APIs<br /><ul><li>Adaptive Payments
  33. 33. Adaptive Accounts</li></ul>Others<br /><ul><li>eMailPayments
  34. 34. Mass Pay</li></li></ul><li>Development Process To Integrate PayPal<br />
  35. 35. Submit for application review (only AP/AA)<br />Get API credentials<br />Go Live<br />Design and build application<br />Create Sandbox account<br />Get APP ID<br />Signup on<br />x.com<br />
  36. 36. X.com<br /><ul><li>Technical Docs for all products
  37. 37. SDKs and Sample code
  38. 38. Forums – non-moderated content
  39. 39. Blogs – PayPal and developers
  40. 40. Connected with PayPal Site
  41. 41. Docs rating and commenting
  42. 42. Instant feedback from developers
  43. 43. Videos</li></li></ul><li>Sandbox<br />developer.paypal.com<br /><ul><li>Manage Sandbox test accounts
  44. 44. Manage Sandbox API Credentials
  45. 45. Monitor Sandbox payment confirmation emails
  46. 46. IPN Simulator</li></ul><browser walk through><br />
  47. 47. PayPal API Basics<br /><ul><li>Traditional PayPal APIs
  48. 48. SOAP
  49. 49. NVP
  50. 50. XMLPay
  51. 51. Adaptive Platform APIs
  52. 52. SOAP
  53. 53. NVP
  54. 54. XML/JSON-RPC</li></li></ul><li>Traditional PayPal NVP API Basics<br />
  55. 55. Traditional PayPal NVP API - example<br />
  56. 56. Traditional XMLPay API Basics<br />
  57. 57. Traditional XMLPay - Example<br /><?xml version="1.0" encoding="UTF-8"?><br /><XMLPayRequest Timeout="30" version = "2.0” xmlns="http://www.paypal.com/XMLPay"><br /><RequestData><br /> <Vendor>vendor</Vendor><br /> <Partner>partner</Partner><br /><Transactions><Transaction><Authorization><br /> <PayData><Invoice><BillTo><Address><br /> <Street>123 4th street</Street><City>San Jose</City><State>CA</State><Zip>95032</Zip><br /> <Country>USA</Country><br /> </Address></BillTo><br /> <TotalAmt>24.97</TotalAmt><br /> </Invoice><br /> <Tender><Card><CardType>visa</CardType><br /> <CardNum>5105105105105100</CardNum><br /> <ExpDate>200911</ExpDate><br /> <NameOnCard/></Card><br /> </Tender><br /> </PayData><br /></Authorization></Transaction></Transactions><br /></RequestData><br /><RequestAuth><UserPass><br /> <User>user</User><br /> <Password>password</Password><br /></UserPass></RequestAuth><br /></XMLPayRequest><br />
  58. 58. Traditional XMLPay - Example<br /><?xml version="1.0" encoding="UTF-8"?><br /><XMLPayResponse><br /> <ResponseData><br /> <Vendor>vendor</Vendor><br /> <Partner>partner</Partner><br /> <TransactionResults><TransactionResult><br /> <Result>0</Result><br /> <AVSResult><br /> <StreetMatch>Service Not Available</StreetMatch><br /> <ZipMatch>Service Not Available</ZipMatch><br /> </AVSResult><br /> <CVResult>Service Not Requested</CVResult><br /> <Message>Approved</Message><br /> <PNRef>V63A09910356</PNRef><br /> <AuthCode>747PNI</AuthCode><br /> <HostCode>00</HostCode><br /> <OrigResult>0</OrigResult><br /> </TransactionResult></TransactionResults><br /> </ResponseData><br /></XMLPayResponse><br />
  59. 59. All SOAP API Basics – Request Format<br />
  60. 60. Adaptive API Basics – API RESPONSE FORMAT - SOAP<br />
  61. 61. Adaptive API Basics – Non SOAP<br /><ul><li>Request Authentication Headers
  62. 62. X-PAYPAL-SECURITY-USERID
  63. 63. X-PAYPAL-SECURITY-PASSWORD
  64. 64. X-PAYPAL-SECURITY-SIGNATURE
  65. 65. X-PAYPAL-SECURITY-SUBJECT
  66. 66. Data Format
  67. 67. X-PAYPAL-REQUEST-DATA-FORMAT (NV, XML, JSON)
  68. 68. X-PAYPAL-RESPONSE-DATA-FORMAT (NV, XML, JSON)
  69. 69. Application and Device identification
  70. 70. X-PAYPAL-APPLICATION-ID
  71. 71. Request Body contains API related objects (JSON/XML/NV)</li></li></ul><li>Adaptive API Basics – Non SOAP Sample<br />JSON: {"returnUrl":"http://example.com/returnURL.htm", "requestEnvelope":{"errorLanguage":"en_US"},"currencyCode":"USD", "receiverList":{"receiver":[{"email":”david@example.com”, "amount":"10.00",}]},"cancelUrl":”http://example.com/cancelURL.htm”, "actionType":"PAY"}<br />NVP: &actionType=PAY&cancelUrl=http:xample.comcancel.htm&currencyCode=USD&receiverList.receiver(0).amount=9.00&receiverList.receiver(0).email=andrea@example.com&receiverList.receiver(1).amount=5.00&receiverList.receiver(1).email=linda@example.com&requestEnvelope.errorLanguage=en_US&returnUrl=http:xample.com eturn.htm<br />XML: <br /><PayRequest><br /> <requestEnvelope><errorLanguage>en_US</errorLanguage> </requestEnvelope><br /> <cancelUrl>http://exammple.com/cancelURL.htm</cancelUrl><br /> <currencyCode>USD</currencyCode><br /> <receiverList><br /> <receiver><amount>100</amount><email>frank@example.com</email><primary>true</primary></receiver><br /> <receiver><amount>75</amount><email>yvonne@example.com</email><br /><primary>false</primary></receiver><br /> </receiverList><br /> <returnUrl>http://example.com/returnURL.htm</returnUrl><br /></PayRequest><br />
  72. 72. SDKs and Toolkits<br /><ul><li>Kick start integration
  73. 73. Minimize integration complexity
  74. 74. Offer stable interface
  75. 75. Focus on application logic</li></ul>PayPal Services<br />PayPal SDK<br />Your Application<br />
  76. 76. SDK Features<br />Live<br />Sandbox<br />Beta Sandbox<br /><ul><li>Sample code and applications for quick ramp up
  77. 77. Source code included
  78. 78. Bundled with test token and API credentials</li></ul>SSL Connection<br />SOAP<br />JSON<br />NVP<br />Authorization Setup<br />Logging<br />Error Handling <br />Configuration<br />API 1<br />API 2<br />API 3<br />Other<br />.NET<br />Java<br />PHP<br />Your Application<br />
  79. 79. MERCHANT SDKs<br />APIs<br />AddressVerify<br />BillOutstandingAmount<br />CreateRecurringPaymentsProfile<br />DoAuthorization<br />DoCapture<br />DoDirectPayment<br />DoExpressCheckoutPayment<br />DoNonReferencedCredit<br />DoReauthorization<br />DoReferenceTransaction<br />DoVoid<br />GetBalance<br />GetBillingAgreementCustomerDetails<br />GetExpressCheckoutDetails<br />GetRecurringPaymentsProfileDetails<br />GetTransactionDetails<br />ManageRecurringPaymentsProfileStatus<br />ManagePendingTransactionStatus<br />MassPayment<br />RefundTransaction<br />SetCustomerBillingAgreement<br />SetExpressCheckout<br />TransactionSearch<br />UpdateRecurringPaymentsProfile<br />Express Checkout & WPP<br />SOAP SDK Language Support <br />Java, .NET, PHP<br />NVP SDK Language Support<br />Java, .NET, PHP, Ruby, ColdFusion<br />Bindings<br />SOAP, NVP<br />Download: www.x.com/sdks<br />
  80. 80. PAYFLOW PRO SDK<br />Credit card processing<br />Language support<br />Java, .NET<br />Bindings<br />NVP, XML<br />Download: www.x.com/sdks<br />APIs<br />DoDirectPayment<br />Sale<br />Authorization<br />Void<br />Delayed Capture<br />Credit<br />SetExpressCheckoutGetExpressChedout<br />DoExpressCheckoutReferenceTransationRecurringPayment<br />
  81. 81. WEBSITE PAYMENTS STANDARD TOOLKIT<br />Payment buttons for your websites<br />Language support<br />Java, .NET, PHP, Ruby<br />Download: www.x.com/sdks<br />Utilities<br />Button Encryption<br />Payment Data Transfer<br />Instant Payment Notification<br />
  82. 82. ADAPTIVE API SDK<br />Adaptive Payments<br />Setup preapproval agreements<br />Simple Send Money<br />Split payments<br />Refund<br />Currency conversion<br />Adaptive Accounts<br />Create account<br />Language Support<br />Java, .NET, PHP<br />Internal Binding<br />SOAP<br />Download: www.x.com/sdks<br />APIs<br />PreapprovalDetails<br />PaymentDetails<br />Pay<br />Preapproval<br />CancelPreapproval<br />Refund<br />ConvertCurrency<br />CreateAccount<br />
  83. 83. Design and build !<br />
  84. 84. Sample Implementations<br /><ul><li>eCommerce
  85. 85. Subscriptions
  86. 86. Disbursements
  87. 87. mCommerce
  88. 88. Split Payments
  89. 89. Preapprovals</li></li></ul><li>eCommerce<br />selling of products online<br /><ul><li>Single Items
  90. 90. Multiple Items
  91. 91. Donations
  92. 92. Gift Certificates</li></li></ul><li>eCommerce with Website Payments Standard<br />buttons, buttons, buttons<br />
  93. 93. Website Payments Standard (WPS)<br />Programmatically create, manage, edit, and <br />delete buttons<br /> Hosted buttons<br /> Encrypted buttons<br /> Clear text buttons<br />Inventory Management<br /> Physical Goods (button wizard and API)<br /> Digital Downloads (with API)<br /> Low inventory alerts<br />
  94. 94. WPS – How it works ?<br />
  95. 95. WPS - Implementation<br />Go to www.paypal.com Business  Products and Services<br />Select Website Payments Standard<br />Click on “Try it Now” button<br />
  96. 96. WPS –HTML<br /><form action="https://www.paypal.com/cgi-bin/webscr" method="post"><br /> <!-- Identify your business so that you can collect the payments. --><br /> <input type="hidden" name="business" value="herschelgomez@xyzzyu.com"><br /> <!-- Specify a Buy Now button. --><br /> <input type="hidden" name="cmd" value="_xclick"><br /> <!-- Specify details about the item that buyers will purchase. --><br /> <input type="hidden" name="item_name" value="Hot Sauce-12 oz. Bottle"><br /> <input type="hidden" name="amount" value="5.95"><br /> <input type="hidden" name="currency_code" value="USD"><br /> <!-- Display the payment button. --><br /> <input type="image" name="submit" border="0"<br />src="https://www.paypal.com/en_US/i/btn/btn_buynow_LG.gif"<br />alt="PayPal - The safer, easier way to pay online"><br /> <img alt="" border="0" width="1" height="1"<br />src="https://www.paypal.com/en_US/i/scr/pixel.gif" ><br /></form><br />
  97. 97. When simple isn’t enough<br />Developers always want :<br /><ul><li>a programmatic approach
  98. 98. For handling thousands & millions of products
  99. 99. For tighter integration with their app
  100. 100. Ex. “Buy Now” might not make sense for use case
  101. 101. better control on payment process
  102. 102. more customization of UI
  103. 103. non hosted solution</li></li></ul><li>eCommerce with Express Checkout<br />a checkout solution<br />
  104. 104. Express Checkout (EC)<br />“all it takes is 3 API Calls”<br />user convenience<br />reduces friction in buyer’s experience<br />only PayPal accounts<br />recurring payments<br />multiple settlement options<br />issue refunds programmatically<br />The shortest path with the least hassle for PayPal users to checkout.<br />
  105. 105. EC – How it works ?<br />Confirm Order<br />(optional)<br />Shopping Cart <br />Login<br />Review Info<br />Confirmation<br />Usability Testing Findings <br /><ul><li>Users feel confident about clicking on the Checkout with PayPal button.
  106. 106. Users are familiar with the button and expect it in the flow.
  107. 107. Users feel the process is streamlined and quicker due to the reduced amount of data entry.</li></li></ul><li>EC – API<br /><ul><li>SetExpressCheckout - Sets up the Express Checkout transaction
  108. 108. customize the look and feel
  109. 109. information displayed
  110. 110. return/cancel urls
  111. 111. total amount
  112. 112. GetExpressCheckout – returns information about the buyer from PayPal, including shipping information
  113. 113. DoExpressCheckoutPayment - Completes the Express Checkout transaction
  114. 114. actual total amount of the order.</li></li></ul><li>EC – Implementation<br /><code><br />
  115. 115. eCommerce with Payflow<br />A payment gateway<br />
  116. 116. Payflow<br />accept Credit and Debit Cards in your own application (PayFlow Pro)<br /><ul><li>Flexible, reliable & scalable payment API
  117. 117. Submit transactions and manage your payments
  118. 118. you are responsible for PCI compliance</li></ul>(or) <br />a fully customizable page hosted on paypal.com (Payflow Link)<br /><ul><li>PCI-compliant solution with Payflow Link.
  119. 119. Cut and paste HTML code onto your website</li></ul>You need your own Internet Merchant Account<br />Variety of payment options - PayPal, credit cards, purchase cards, debit cards<br />search, reports, and virtual point-of-sale terminal<br />
  120. 120. Payflow Link – How it works ?<br />Checkout Page<br />Thank You!<br />Pay<br />PayPal Hosted Pages<br />
  121. 121. Payflow Link – Implementation<br /><form method="POST" action="https://payflowlink.paypal.com"> <br /><input type="hidden" name="LOGIN" value=“login"> <br /><input type="hidden" name="PARTNER" value=“PayPal"> <br /><input type="hidden" name="AMOUNT" value="1.00"> <br /><input type="hidden" name="TYPE" value="S"> <br /><input type="hidden" name="DESCRIPTION" value=“Hat"> <br /><p><input type="submit" value="Click Here to Checkout"></p> <br /></form><br />
  122. 122. Payflow Pro– How it works ?<br />Your Application<br />NVP-XMLPay/HTTPS<br />Payflow API Server<br />
  123. 123. Payflow Pro – API<br /><ul><li>Credit Card Processing</li></ul>Sale<br />Authorization<br />delayed capture<br />Credit<br />Void<br />Inquiry<br />Voice Authorization<br /><ul><li>Reference Transactions
  124. 124. Address Verification and Card Security Code Validation</li></li></ul><li>Payflow Pro – Implementation<br /><code><br /><ul><li>Connection parameters
  125. 125. HostAddress, HostPort, Timeout, Proxy Info, ParmList
  126. 126. User parameters
  127. 127. User, Vendor, Partner, API Password
  128. 128. Parameters specific to the type of the transaction, such as a sale or an authorization
  129. 129. TRXType, Tender, Acct, Amt, Expdate</li></li></ul><li>Payflow Pro – Sample Request/Response<br />USER=user&PWD=passorwd&VENDOR=vendor&PARTNER=PayPal&TRXTYPE=S&TENDER=C&ACCT=5105105105105100&EXPDATE=0112&CVV2=123&AMT=1.00&FIRSTNAME=John&LASTNAME=Smith&STREET=1_Main_Street&CITY=Austin&STATE=TX&ZIP=78704&COMMENT1=Reservation&INVNUM=123<br />HTTP/1.1 200 OK<br />Connect: close <br />Server: VPS-3.032.00 <br />X-VPS-Request-ID: ae66ec694cea474002cba0025659946d <br />X-VPS-Response-ID: V1sMZIeBBmr<br />Content-type: text/namevalue<br />Content-length: 189<br />RESULT=0&PNREF=V18A0BAB041A&RESPMSG=Approved&AUTHCODE=823PNI&AVSADDR=Y&AVSZIP=Y&CVV2MATCH=Y&HOSTCODE=A&PROCAVS=Y&PROCCVV2=M&IAVS=N&PREFPSMSG=No_Rules_Triggered&POSTFPSMSG=No_Rules_Triggered <br />
  130. 130. eCommerce with Website Payments Pro<br />accept both credit cards and PayPal payments<br />
  131. 131. Website Payments Pro (WPP)<br />Direct Payment lets you accept credit cards on your website<br />Express Checkout lets you accept PayPal payments on your website<br />
  132. 132. WPP – How it works ?<br />
  133. 133. WPP – DoDirectPayment API<br />Arguments:<br /><ul><li>Method: DoDirectPayment
  134. 134. PaymentAction: Authorization or Sale
  135. 135. IPAddress
  136. 136. ReturnFMFDetails
  137. 137. CreditCard Fields:
  138. 138. CreditCardType, Acct, ExpDate, CVV2, StartDate, IssueNumber
  139. 139. Payer Info Fields:
  140. 140. Email, PayerID, PayerStatus, CountryCode, Business
  141. 141. Payer Name Fields:
  142. 142. Salutation, FirstName, MiddleName, LastName, Suffix
  143. 143. Address Fields
  144. 144. Payment Details Type Fields:
  145. 145. AMT, CurrencyCode, ItemAMT, etc…</li></li></ul><li>WPP – Implementation<br /><code><br />
  146. 146. WPP – Sample Request/Response<br />Request: https://api-3t.sandbox.paypal.com/nvp<br />POST Parameters: METHOD=doDirectPayment&VERSION=60.0&PWD=QFZCWN5HZM8VBG7Q&USER=sdk-three_api1.sdk.com&SIGNATURE=A.d9eRKfd1yVkRrtmMfCFLTqa6M9AyodL0SJkhYztxUi8W9pCXF6.4NI&PAYMENTACTION=Sale&AMT=1.00&CREDITCARDTYPE=Visa&ACCT=4032193587292399&EXPDATE=012012&CVV2=962&FIRSTNAME=John&LASTNAME=Doe&STREET=1+Main+St&CITY=San+Jose&STATE=CA&ZIP=95131&COUNTRYCODE=US&CURRENCYCODE=USD<br />Response:<br />TIMESTAMP=2010%2d02%2d22T07%3a22%3a52Z&CORRELATIONID=d64bd3c9ac968&ACK=Success&VERSION=60%2e0&BUILD=1195961&AMT=1%2e00&CURRENCYCODE=USD&AVSCODE=X&CVV2MATCH=M&TRANSACTIONID=3L887465VP729712C <br />
  147. 147. Subscriptions<br />Customer pays a subscription price to have access to the product/service<br />Ex.<br /><ul><li>purchase of a series of things
  148. 148. an agreement to receive or be given access to content/services online
  149. 149. value added services
  150. 150. Premium content
  151. 151. Virtual Goods</li></li></ul><li>Subscriptions with Website Payments Standard<br />
  152. 152. WPS – How it works ?<br />
  153. 153. WPs– Implementation<br />Go to www.paypal.com Business  Products and Services<br />Select Website Payments Standard<br />Click on Try it Now button<br /><Demo><br />
  154. 154. WPs– HTML<br /><form action="https://www.paypal.com/cgi-bin/webscr" method="post"><br /> <!-- Identify your business so that you can collect the payments. --><br /> <input type="hidden" name="business" value="alice@mystore.com"><br /> <!-- Specify a Subscribe button. --><br /> <input type="hidden" name="cmd" value="_xclick-subscriptions"><br /> <!-- Identify the subscription. --><br /> <input type="hidden" name="item_name" value="Alice's Weekly Digest"><br /> <input type="hidden" name="item_number" value="DIG Weekly"><br /> <!-- Set the terms of the regular subscription. --><br /> <input type="hidden" name="currency_code" value="USD"><br /> <input type="hidden" name="a3" value="5.00"><br /> <input type="hidden" name="p3" value="1"><br /> <input type="hidden" name="t3" value="M"><br /> <!-- Display the payment button. --><br /> <input type="image" name="submit" border="0"<br />src="https://www.paypal.com/en_US/i/btn/btn_subscribe_LG.gif"<br />alt="PayPal - The safer, easier way to pay online"><br /> <img alt="" border="0" width="1" height="1"<br />src="https://www.paypal.com/en_US/i/scr/pixel.gif" ><br /></form><br />
  155. 155. Subscriptions with Express Checkout<br />Recurring payments<br />
  156. 156. EC – How it works ?<br />3<br />1<br />4<br />2<br />Merchant sets up recurring payment items.<br />Customer selects Express Checkout and agrees to payment terms.<br />At subsequent billing cycles, PayPal charges customer on behalf of merchant. <br />Merchant can view, modify, or suspend payments.<br />
  157. 157. EC – API<br /><ul><li>SetExpressCheckout - Sets up the Express Checkout transaction
  158. 158. customize the look and feel
  159. 159. information displayed
  160. 160. return/cancel urls
  161. 161. total amount
  162. 162. Recurring payment agreement
  163. 163. GetExpressCheckout – returns information about the buyer from PayPal, including shipping information
  164. 164. CreateRecurringPaymentsProfile – creates the recurring profile</li></li></ul><li>EC – Implementation<br /><code><br />
  165. 165. EC – Sample Request/Response<br />Request:<br />METHOD=CreateRecurringPaymentsProfile&VERSION=60.0&PWD=QFZCWN5HZM8VBG7Q&USER=sdk-three_api1.sdk.com&SIGNATURE=A.d9eRKfd1yVkRrtmMfCFLTqa6M9AyodL0SJkhYztxUi8W9pCXF6.4NI&AMT=1.00&CREDITCARDTYPE=Visa&ACCT=4781568468637361&EXPDATE=012011&CVV2=962&FIRSTNAME=John&LASTNAME=Doe&STREET=1+Main+St&CITY=San+Jose&STATE=CA&ZIP=95131&COUNTRYCODE=US&CURRENCYCODE=USD&PROFILESTARTDATE=2010-03-21T00%3A00%3A00Z&DESC=Welcome+to+the+world+of+shopping+where+you+get+everything&BILLINGPERIOD=Week&BILLINGFREQUENCY=4&TOTALBILLINGCYCLES=<br />Response:<br />PROFILEID=I%2d8STY14R2YVVJ&PROFILESTATUS=ActiveProfile&TIMESTAMP=2010%2d02%2d22T07%3a34%3a07Z&CORRELATIONID=967863e017837&ACK=Success&VERSION=60%2e0&BUILD=1198898 <br />
  166. 166. Disbursements<br />PayPal disbursement products allow you to send payments to multiple customers at the same time. <br />Who is target customer?<br />Businesses who disburse money to their customers or clients<br />Product is a replacement for payouts via check, direct debit, and gift cards<br />Some key segments<br />
  167. 167. Disbursements with MassPay<br />
  168. 168. Mass Payments<br />About Mass Payments<br /><ul><li>Allows sending of money to multiple recipients in one batch
  169. 169. Two ways to use: MassPay API (250) or upload (5000)
  170. 170. Sender pays the transaction fee, not the receiver
  171. 171. 2% per payment with a maximum $1.00 per payment
  172. 172. Payment made from account balance</li></ul>Primary benefits to sender<br /><ul><li>An easy and efficient way to send a large number of payments at once
  173. 173. Great way to send payments cross-border
  174. 174. Low cost to disburse money
  175. 175. Provide a payout choice to your customer
  176. 176. Get money to your customers quickly</li></li></ul><li>MassPay– How it works ?<br />1. Introduction<br />3. Final Approval<br />2. File Upload<br />5. Email Confirmation<br />Sample File<br />4. Confirmation<br />
  177. 177. MassPay– API<br />Each payment is in the format L_{Field}n<br /><ul><li>{Field}is the field being populated (AMT, EMAIL, and so on)
  178. 178. n is the counter of the request (starting with 0 (zero))</li></ul>https://api-3t.sandbox.paypal.com/nvp?{VERSION & CREDENTIALS}&<br />METHOD=MassPay&<br />RECEIVERTYPE=EmailAddress&<br />CURRENCYCODE=USD&<br />L_AMT0=5.00&<br />L_EMAIL0=masspay1%40mikeblanton.com&<br />L_AMT1=5.00&<br />L_EMAIL1=otheraccount%40me.com&<br />L_AMT2=5.00&<br />L_EMAIL2=friend%40hotmail.com<br />
  179. 179. MassPay– Implementation<br /><code><br />
  180. 180. MassPay– Sample Request/Response<br />Request:<br />METHOD=MassPay&VERSION=60.0&PWD=QFZCWN5HZM8VBG7Q&USER=sdk-three_api1.sdk.com&SIGNATURE=A.d9eRKfd1yVkRrtmMfCFLTqa6M9AyodL0SJkhYztxUi8W9pCXF6.4NI&L_EMAIL0=user1%40paypal.com&L_Amt0=1.00&L_UNIQUEID0=&L_NOTE0=&L_EMAIL1=user2%40paypal.com&L_Amt1=1.00&L_UNIQUEID1=&L_NOTE1=&L_EMAIL2=user3%40paypal.com&L_Amt2=1.00&L_UNIQUEID2=&L_NOTE2=&EMAILSUBJECT=You+have+money%21&RECEIVERTYPE=EmailAddress&CURRENCYCODE=USD<br />Response:<br />TIMESTAMP=2010%2d02%2d22T07%3a35%3a36Z&CORRELATIONID=b72f8f569219&ACK=Success&VERSION=60%2e0&BUILD=1205804<br />
  181. 181. mCommerce<br />Comparison shopping applications are the top downloads.<br />Number of Mobile Transactions<br />10X<br />Red Laser<br />4 million downloads<br />$380 million in sales (Jan-Sep 2009)<br />
  182. 182. The mobile way<br />Clients (Mobile Embedded Payment Toolkit)<br />Mobile Web<br />Pre-approval (Apple)<br />Entirely client-based experience leveraging APIs and plug & play interface<br />Utilized WAP infrastructure and reskinning techniques for seamless integration<br />Web onboarding for a mobile billing agreement<br />
  183. 183. Mobile Checkout<br />Similar to Express Checkout but with Mobile UI<br />Supports Phone/Pin login<br />(User sets phone/pin with PayPal)<br />To access mobile checkout, a device, mobile<br />carrier, and browser must support the following:<br /> WAP 2.0 phones (not WAP 1.0)<br />xHTML or HTML markup language<br /> SSL connections<br /> Cookies enabled<br /> No carrier "WAP gap"<br />
  184. 184. Mobile Checkout – How it works ?<br />
  185. 185. Mobile Checkout – API<br /><ul><li>SetMobileCheckout
  186. 186. DoMobileCheckout</li></li></ul><li>ONLINE BILLING AGREEMENTS<br /><ul><li>Billing agreements can be set up online or on the phone.
  187. 187. Agreements can then be used on the phone.
  188. 188. These are the same agreements used with Adaptive Payments.</li></li></ul><li>Mobile Embedded Payments (MEP)<br />Provides an easy way to enable payments in iPhoneapplications<br />Customers never leave the application to pay<br />No worries about collecting or handling financial information<br />Example use cases<br />Restaurant chain application for ordering and payment<br />Plumbing service application for booking and paying<br />Charity application for donation collection<br />Selling merchandise in games and social applications<br />
  189. 189. MEP – How it works ?<br />
  190. 190. MEP – API<br />(PayPal*)initializeWithAppID:(NSString*)PayPalApplicationID (Optional:) forEnvironment:PAYPAL_ENVIRONMENT)env;<br />-(void)setPayButton:(UIViewController *)target buttonType:(PayPalButtonType)buttonTypestartCheckOut:(SEL)payWithPayPal<br />withLeft:(int)left<br />withTop:(int)top;<br />-(void)Checkout:(NSString*)currency <br />Amount:(NSString*)inAmount<br /> Description: (NSString*)inItemDesc<br />Recipient:(NSString*)inRecipient<br />Tax:(NSString*)inTax<br />Shipping:(NSString *)inShipping<br />PaymentType:(PayPalPaymentType)paymentType;<br />
  191. 191. MEP – Implementation<br />// initialize paypalMEPppMEP = [PayPal initializeWithAppID:@"APP-80W284485P519543T" forEnvironment:ENV_SANDBOX];[[PayPalgetInstance] setPayButton:self buttonType:BUTTON_294x43 startCheckOut:@selector(payWithPayPal) withLeft:10 withTop:352];<br />-(void)payWithPayPal {[ppMEPEnableShipping];<br /> //setting whether the payment type is hard goods or servicePayPalPaymentTypepaymentType = HARD_GOODS;<br />NSString *desc = [NSStringstringWithFormat:@"Photo Print (%@)", photoId];<br /> [ppMEP SetSenderEmailorPhone:@"ppalav_1260941775_per@yahoo.com"];<br /> [ppMEP Checkout:@"USD" <br />Amount:[NSString stringWithString:@"5.0"] Description:desc Recipient:@"pd_1265515509_biz@yahoo.com" <br />Tax:[NSString stringWithString:@"0.0"] <br />Shipping:[NSString stringWithString:@"0.41"] PaymentType:paymentType];<br />}<br />-(void)paymentSuccess:(NSString*)transactionID{<br />UIAlertView *alert = [[UIAlertViewalloc] initWithTitle:@"Order successful" <br />message:@"Your picture is on it's way!" <br />delegate:nilcancelButtonTitle:@"OK" otherButtonTitles:nil];<br /> [alert show];<br /> [alert release];<br />}<br />
  192. 192. PayPal Platform (Adaptive Suite of APIs)<br /><ul><li>Payments platform for external developers
  193. 193. First Suite of APIs
  194. 194. Adaptive Payments: Highly configurable payment APIs
  195. 195. Adaptive Accounts: API-based PayPal account creation</li></li></ul><li>Adaptive Payments (AP)<br /><ul><li> A money movement service that is "Adaptive" to allow innumerable use cases</li></ul>Configurable service suite for any type of payment or transfer<br />Not limited to web eCommerce payments<br /><ul><li>Simple Single Sender – Single Receiver model (to)</li></ul> Single Sender - Multiple receivers model<br /><ul><li>Advanced features
  196. 196. Pre-approved payments</li></ul>Pre-approval for one-time, multi-use, and subscription payments<br />Configurable personal identification number (PIN) support<br /><ul><li>Parallel and chained (Split) payments</li></ul>Allows single payment to multiple receivers<br />Facilitates multiple use cases: marketplace payments, service fees, multi-merchant checkout, and so on<br />
  197. 197. AP – How it works ?<br />API<br />WEB<br />Business<br />Pay API<br />Pay Key<br />Redirect User to PayPal<br />Return URL<br />109<br />User Name = P_Mart_admin.api Currency = USD<br />Password = keep$secret Receiver email = Business@P_Mart.com<br />Signature = 23KJHO5AS09I32SDROR Tracking ID = 234235986<br />Sender Email = john_m@mail.comCancel URL = www.P_Mart.com/home<br />Amount = 100 Return URL = www.P_Mart.com/apstore<br />Pay Key = PA-84HK2A57FCOP3RW <br />Response<br />Request<br />109<br />Confidential and Proprietary<br />109<br />
  198. 198. PAYMENT APPROVAL on WEB<br />1. Login<br />Payment Confirmation<br />2. Review Your Payment<br />3. Redirect<br />
  199. 199. Adaptive Payments - API<br /><ul><li>Payment APIs
  200. 200. Pay: Transfer funds between parties. Supports simple, chained, parallel, preapproved payments, etc.
  201. 201. PaymentDetails: Get details of a payment
  202. 202. Preapproval APIs
  203. 203. Preapproval: Preapproval agreement signup
  204. 204. PreapprovalDetails: Get details of a preapproval
  205. 205. CancelPreapproval: Cancel an existing preapproval
  206. 206. Refund: Refund a payment (complete, partial, etc.)
  207. 207. ConvertCurrency: Get currency conversion (foreign exchange) rates for a list of amounts and currencies (PayPal-supported currencies).</li></li></ul><li>Adaptive Payments – Implementation<br /><code><br />
  208. 208. Adaptive Payments – Sample Request/Response<br />Request (NVP - formatted):<br />actionType=PAY&<br />requestEnvelope.errorLanguage=en_US&<br />returnUrl=http://www.return.com&<br />cancelUrl=http://www.cancel.com&<br />currencyCode=USD&<br />feesPayer=EACHRECEIVER&<br />memo=Payment for service&<br />receiverList.receiver(0).email=receiver@x.com&<br />receiverList.receiver(0).amount=100.00<br />Response (NVP – formatted):<br />responseEnvelope.timestamp=2010-02-20T19%3A35%3A41.368-08%3A00&<br />responseEnvelope.ack=Success&<br />responseEnvelope.correlationId=87b9285584b68&<br />responseEnvelope.build=1193935&<br />payKey=AP-1F95034641369115U&<br />paymentExecStatus=CREATED<br />
  209. 209. Adaptive Accounts<br /><ul><li>Programmatic interface to PayPal account creation
  210. 210. Account created can be used with any PayPal APIs, including Adaptive Payment APIs
  211. 211. Currently supports creation of Personal and Premier accounts. Business account creation to come soon.
  212. 212. Benefits:
  213. 213. Streamline user experience
  214. 214. Increase conversion</li></li></ul><li>Adaptive Accounts – How it works ?<br />
  215. 215. Adaptive Accounts – API<br /><ul><li>CreateAccount: PayPal account creation API</li></ul>Personal and Premier account creation (Business account creation to come soon).<br />API Request (required fields in bold): <br />Account Type (valid values are Personal, Premier)<br />Name: First, Last<br />Address: Address Line 1, Line 2, City, Zip<br />Country: Country Code<br />Email<br />Phone<br />Preferred Language Code<br />Return URL<br />Registration Type (valid value is Web)<br />Other fields are also dependent on the country<br />DOB<br />Citizenship Country Code<br />API Response:<br />execStatus<br />Redirect URL: The user needs to be redirected to this URL for finishing the account signup process (password and Add Funding Sources flow).<br />
  216. 216. Adaptive Accounts – Implementation<br /><code><br />
  217. 217. Adaptive Accounts – Sample Request/Response<br />Request:<br />accountType=PERSONAL&registrationType=Web&name.salutation=Dr.&name.firstName=Bonzo&name.middleName=Simore&name.lastName=Zaius&emailAddress=bzaius@email.com&dateOfBirth=1968-01-01Z&address.line1=1968 Ape Way&address.line2=Apt 123&address.city=Austin&address.state=TX&address.postalCode=78750&address.countryCode=US&contactPhoneNumber=512-691-4160&currencyCode=USD&citizenshipCountryCode=US&preferredLanguageCode=en_US&createAccountWebOptions.returnUrl=http://www.success.com<br />Response:<br />responseEnvelope.timestamp=2010-02-22T21%3A47%3A09.833-08%3A00&responseEnvelope.ack=Success&responseEnvelope.correlationId=9e107273d5330&responseEnvelope.build=1149875&createAccountKey=AA-7NU425523H556874S&execStatus=COMPLETED&redirectURL=https%3A%2F%2Fwww.sandbox.paypal.com%2Fus%2Fcgi-bin%2Fwebscr%3Fcmd%3D_hostedua-flow%26encrypted_second_auth_code%3DAgPLMEgZKZSFz7ve8rViM9pjBZLK86wyV3suJtaHV4nku.Q7huKEMZms2zN6bVpWzQY%26encrypted_id%3DH24VPCELGVF4N<br />
  218. 218. a few more important things<br />
  219. 219. Instant Payment Notifications (IPN)<br />
  220. 220. Instant Pay Notifications (IPN)<br />Message service that notifies you of events related to: <br />New transactions<br />Updates to previous transactions<br />Dispute management and chargebacks<br />Provides status on pending, cancelled, or failed transactions<br />Allows merchants and developers to integrate payments and automate back-end operations<br />
  221. 221. COMMON IPN TYPES<br />Instant payments, such as Express Checkout <br />eCheck payments <br />Pending payments<br />Recurring payments and subscriptions<br />Authorizations<br />Chargebacks<br />Disputes<br />Reversals<br />
  222. 222. IPN IN ACTION<br />PayPal posts IPN to seller<br />Seller posts back IPN message to PayPal<br />Buyer clicks Buy Now button<br />PayPal sends VERIFIED/INVALID response<br />
  223. 223. IPN MESSAGE<br />IPN is HTTP POST with POST variables consisting of:<br />Information about Seller<br />Information about the Transaction<br />Information about your Buyer<br />Information about the Payment<br />
  224. 224. IPN - Sample<br />mc_gross=19.95&protection_eligibility=Eligible&address_status=confirmed&pay<br />er_id=LPLWNMTBWMFAY&tax=0.00&address_street=1+Main+St&payment_date=20%3A12%<br />3A59+Jan+13%2C+2009+PST&payment_status=Completed&charset=windows-<br />1252&address_zip=95131&first_name=Test&mc_fee=0.88&address_country_code=US&<br />address_name=Test+User&notify_version=2.6&custom=&payer_status=verified&add<br />ress_country=United+States&address_city=San+Jose&quantity=1&verify_sign=Atk<br />OfCXbDm2hu0ZELryHFjY-Vb7PAUvS6nMXgysbElEn9v-<br />1XcmSoGtf&payer_email=user123%40yahoo.com&txn_id=61E67681CH32<br />38416&payment_type=instant&last_name=User&address_state=CA&receiver_email=g<br />pmac__biz%40gmail.com&payment_fee=0.88&receiver_id=S8XGHLYDW9T3S<br />&txn_type=express_checkout&item_name=&mc_currency=USD&item_number=&residenc<br />e_country=US&test_ipn=1&handling_amount=0.00&transaction_subject=&payment_g<br />ross=19.95&shipping=0.00<br />https://www.sandbox.paypal.com/cgi-bin/webscr?cmd=_notifyvalidate&<br />mc_gross=19.95&protection_eligibility=Eligible&address_status=conf<br />irmed&payer_id=LPLWNMTBWMFAY&tax=0.00&...&payment_gross=19.95&shipping=0.00<br />VERIFIED or INVALID<br />
  225. 225. ENABLING IPN<br /><ul><li>Listener can be enabled from Profile-> Instant Payment Notification
  226. 226. Per Transaction Listener (Notify URL) can be used from buttons and API requests</li></ul>* Requires subscription. <br /> Contact Customer Service for access<br />
  227. 227. IPN HISTORY: RESENDING IPN<br />History->IPN History<br />
  228. 228. IPN BEST PRACTICES<br />Once IPN is received:<br />Always validate the incoming IPN.<br />Send the response as soon as possible.<br />Check for duplicate IPNs.<br />Respond to all the IPNs or the IPN will be resent.<br />IPN is designed as an asynchronous notification. Never wait for IPN synchronously.<br />Disable any listeners that are not in use. PayPal detects and disables malfunctioning listeners.<br />Where necessary get, transaction information from other methods in addition to using IPN.<br />
  229. 229. Development Process<br />Submit for application review<br />Get API credentials<br />Go Live<br />Design and build application<br />Create Sandbox account<br />Get APP ID<br />Signup on<br />x.com<br />
  230. 230. Submitting your non-Adaptive API APP<br /><ul><li>Get live API credentials from your profile page
  231. 231. Go live !</li></li></ul><li>Submitting your Adaptive APIs app for review<br />Upgrade to a PayPal Business Account<br />Get Verified<br />Obtain Live API Credentials<br />Submit App<br />App description<br />Kind of Payments it provisions<br />Test URL and related testing info<br />Services you use (simple/adanced)<br />A few screenshots<br />Answer a few questions to make sure your app is Secure, and doesn’t violate any regulations.<br />
  232. 232. Things to note<br />1. The PayPal X Developer Agreement is your friend.<br />Clearly and concisely explains what is and is not allowed<br />Describes confidentiality and intellectual property rights<br />2. Your application will be reviewed for:<br />Compliance with payment regulations<br />Acceptable use policy compliance<br />Information security<br />Risk<br />Functionality<br />3. Applications using only standard functionality go through a less involved review.<br />
  233. 233. Going Live<br />Once your app get’s approved, you will receive your Live APP ID.<br />Update your app to use Live APP ID and API Credentials<br />Launch your application <br />Start accepting payments!<br />
  234. 234. WHEN TRANSACTIONS GO RIGHT<br />Order<br />Payment<br />Shipment<br />/Delivery<br />
  235. 235. When Security Fails<br />
  236. 236. SECURITY WITH PayPal PRODUCTS<br /><ul><li>Always use HTTPS when talking to PayPal.
  237. 237. Always integrate with web flows and APIs using POST, not GET.
  238. 238. Always integrate with PayPal using an HTTP(s) library, not raw sockets.
  239. 239. Pay attention to HTTP(s) error codes
  240. 240. Validate IPNs properly.
  241. 241. Use saved or encrypted Website Payments Standard buttons to prevent tampering attacks.
  242. 242. Don’t rely on the referrer header during a checkout flow to assume a person has been paid.</li></li></ul><li>Securing your applications <br /><ul><li>Be careful about handling input to your application.
  243. 243. Prevent Common shopping cart attacks like Price tampering & Fake referrer header attack
  244. 244. Stay current on security vulnerabilities.
  245. 245. Harden your servers, frameworks, and applications and keep them up to date.
  246. 246. By following best practices, your applications will be both more robust and more secure.</li></ul>The Open Web Application Security Project (http://www.owasp.org)<br />The Web Application Security Consortium (http://www.webappsec.org/)<br />Security Focus (http://www.securityfocus.com)<br />
  247. 247. Fighting Fraud<br />Consumer fraud <br />Merchant fraud<br />Phishing<br />Social engineering<br />
  248. 248. BEST PRACTICES<br />Be vigilant<br />Authenticate each transaction<br />Real-time authorizations <br />Reduce customer errors<br />Manual review <br />Robust risk rules customized for your business<br />Comprehensive and dynamic fraud scoring <br />Bayesian filters<br />Neural nets<br />Cross merchant and buyer data analysis for patterns <br />Cross channel data analysis patterns<br />
  249. 249. Managing your Risk using PayPal<br />
  250. 250. Watch out for illegal transactions<br />Certain transactions are illegal. Therefore, the payment and processing of the payment is also illegal.<br />Some examples:<br />Sales of narcotics <br />Child pornography<br />Internet gambling transactions<br />Underage alcohol/tobacco sales<br />All payment mechanisms prohibit payments that violate law.<br />As a developer, creating an application that violates law or enables the violation of law could subject you to criminal and civil liability.<br />
  251. 251. A few useful urls<br /><ul><li>PayPal X Developer Network: https://www.x.com
  252. 252. API Documentation: https://www.x.com/community/ppx/dev-tools
  253. 253. SDKs & Toolkits: https://www.x.com/community/ppx/sdks
  254. 254. Business Account SignUp: https://www.paypal.com
  255. 255. Sandbox: https://developer.paypal.com/
  256. 256. IPN Simulator: https://developer.paypal.com/devscr?cmd=_ipn-link-session
  257. 257. Contact Us: https://www.x.com/community/ppx/support</li></li></ul><li>LEARN AND SHARE<br />www.x.com<br />Twitter: @paypalx, @ppalavilli, @aalapparikh, @carolynmellor<br />www.facebook.com/paypalx<br />

×