{"id":3674,"date":"2013-10-27T21:05:32","date_gmt":"2013-10-28T04:05:32","guid":{"rendered":"http:\/\/www.digitalaccesspass.com\/doc\/?p=3674"},"modified":"2015-06-12T10:57:47","modified_gmt":"2015-06-12T17:57:47","slug":"stripe-integration","status":"publish","type":"post","link":"http:\/\/digitalaccesspass.com\/doc\/stripe-integration\/","title":{"rendered":"Stripe Integration"},"content":{"rendered":"<h3>DAP\/Stripe Integration<\/h3>\n<p><iframe loading=\"lazy\" src=\"\/\/www.youtube.com\/embed\/SqawDsjYIA4?rel=0&amp;vq=hd720\" width=\"480\" height=\"271\" frameborder=\"0\" allowfullscreen=\"allowfullscreen\"><\/iframe><\/p>\n<p><a href=\"http:\/\/stripe.com\" target=\"_blank\" rel=\"nofollow\">Stripe<\/a> is quickly gaining popularity as the go-to payment processor. It wins points for its incredible ease of use.\u00a0Stripe charges a fee of 2.9% + $0.30 <strong>per successful charge<\/strong>.<\/p>\n<p>Starting DAP v4.5, you can hook up the DAP Shopping Cart to Stripe.com for payments.<\/p>\n<p>This document explains how to connect Stripe to the DAP Cart.<\/p>\n<p><strong><span style=\"color: #ff0000;\">Please NOTE (IMPORTANT) :<\/span><\/strong><\/p>\n<p><strong>1. Subscription Product:<\/strong><\/p>\n<p>If you sell subscription products using DAP + Stripe, <span style=\"color: #ff0000;\">you MUST define a PLAN with the EXACT same name as the DAP product, in your Stripe Account<\/span>.\u00a0 <span style=\"color: #ff0000;\">Both the PLAN ID as well as the PLAN NAME in Stripe MUST match the DAP product name. The plan ID in stripe cannot be a number.<\/span> It needs to match the product name in dap otherwise Stripe will not charge the user&#8217;s credit card automatically every recurring cycle.<\/p>\n<p><strong>2. Coupon Code<\/strong><\/p>\n<p>If you use coupons, make sure to<span style=\"color: #ff0000;\"> create coupon codes both in DAP and in Stripe,<\/span> including for one-time paid DAP products, and even if Stripe says that Coupons are for Subscriptions.<\/p>\n<h3>API Key &amp; Webhooks Setup<\/h3>\n<ol>\n<li>Go to\u00a0<a href=\"http:\/\/stripe.com\/\" target=\"_blank\">http:\/\/stripe.com\/<\/a> and sign up for a stripe account if you do not already have one.<\/li>\n<li>Login to Stripe.com and visit this page in a browser &#8211;\u00a0 https:\/\/manage.stripe.com\/account<a href=\"http:\/\/www.digitalaccesspass.com\/doc\/wp-content\/uploads\/2013\/10\/apikey1.png\"><img loading=\"lazy\" class=\"alignnone  wp-image-2379\" style=\"border: 1px solid black;\" title=\"api_key\" src=\"http:\/\/www.digitalaccesspass.com\/doc\/wp-content\/uploads\/2013\/10\/apikey1.png\" alt=\"\" width=\"449\" height=\"199\" \/><\/a><\/li>\n<li>Click on API Keys tab and copy the Secret Key and Publishable key and save it somewhere. You will need to update the DAP admin -&gt; setup -&gt; config -&gt; Stripe section with these keys. If you want to test with Stripe in test mode, copy the test version of these keys. Otherwise copy the Live version of these keys. <strong>Please note:<\/strong> whenever you are ready to switch from test to live mode, you will need to use the live secret key and publishable key in DAP config.<\/li>\n<li>Click on Webhooks tab and update the webhooks URL to http:\/\/<strong>YOURSITE.com<\/strong>\/dap\/dap-stripe.php (Replace <strong>YOURSITE.com<\/strong> with the name of your site).<a href=\"http:\/\/www.digitalaccesspass.com\/doc\/wp-content\/uploads\/2013\/10\/webhooks.png\"><img loading=\"lazy\" class=\"alignnone  wp-image-2379\" style=\"border: 1px solid black;\" title=\"webhooks\" src=\"http:\/\/www.digitalaccesspass.com\/doc\/wp-content\/uploads\/2013\/10\/webhooks.png\" alt=\"\" width=\"449\" height=\"199\" \/><\/a><\/li>\n<\/ol>\n<h3>Save Stripe keys in DAP Config<\/h3>\n<ol>\n<li>Enter the Stripe keys in DAP Setup &gt; Config -&gt; Payment Processing &#8211; Stripe.com<a href=\"http:\/\/www.digitalaccesspass.com\/doc\/wp-content\/uploads\/2013\/10\/stripekeys.png\"><img loading=\"lazy\" class=\"alignnone  wp-image-2379\" style=\"border: 1px solid black;\" title=\"webhooks\" src=\"http:\/\/www.digitalaccesspass.com\/doc\/wp-content\/uploads\/2013\/10\/stripekeys.png\" alt=\"\" width=\"449\" height=\"199\" \/><\/a><\/li>\n<\/ol>\n<h3>One-time Product Setup<\/h3>\n<p><iframe loading=\"lazy\" src=\"\/\/www.youtube.com\/embed\/OAPvCOSO1_U?rel=0&amp;vq=hd720\" width=\"480\" height=\"271\" frameborder=\"0\" allowfullscreen=\"allowfullscreen\"><\/iframe><br \/>\nIf you only want to sell one-time purchase products, then you just need to create the product as a one-time product in DAP products page (set recurring to &#8220;NO&#8221; in price&amp;recurring tab). You do not have to create product in Stripe.<\/p>\n<h3>Subscription \/ Recurring Product Setup<\/h3>\n<p>If you only want to sell one-time purchase products, then you can skip this step. If you want to sell Subscription\/Recurring products using Stripe, then please read this section.<\/p>\n<ul>\n<li>Visit the <a href=\"https:\/\/manage.stripe.com\/test\/plans\">Plans<\/a> page and click on <strong>NEW <\/strong>to setup a Subscription plan.<br \/>\n<a href=\"http:\/\/www.digitalaccesspass.com\/doc\/wp-content\/uploads\/2013\/10\/plansetup.png\"><img loading=\"lazy\" class=\"alignnone  wp-image-2379\" style=\"border: 1px solid black;\" title=\"webhooks\" src=\"http:\/\/www.digitalaccesspass.com\/doc\/wp-content\/uploads\/2013\/10\/plansetup.png\" alt=\"\" width=\"449\" height=\"199\" \/><br \/>\n<\/a><\/li>\n<li><strong> Create NEW plan in Stripe :<\/strong><\/li>\n<\/ul>\n<p><a href=\"http:\/\/www.digitalaccesspass.com\/doc\/wp-content\/uploads\/2013\/10\/newplan.png\"><img loading=\"lazy\" class=\"alignnone  wp-image-2379\" style=\"border: 1px solid black;\" title=\"webhooks\" src=\"http:\/\/www.digitalaccesspass.com\/doc\/wp-content\/uploads\/2013\/10\/newplan.png\" alt=\"\" width=\"449\" height=\"199\" \/><\/a><strong>ID\/Name<\/strong> Both ID and Name should eXactly match the &#8216;Product Name&#8217; in DAP. So if the DAP product name is GOLD SUBSCRIPTION, then the Stripe plan Id = GOLD SUBSCRIPTION and the Stripe plan name should also be GOLD SUBSCRIPTION.<\/p>\n<p>If the product name in DAP is EXAMPLE SUBSCRIPTION PRODUCT, then create a plan in your Stripe account with :<br \/>\n<strong>Stripe plan id:<\/strong> EXAMPLE SUBSCRIPTION PRODUCT<br \/>\n<strong>Stripe plan name:<\/strong> EXAMPLE SUBSCRIPTION PRODUCT<\/p>\n<p><span style=\"color: #ff0000;\">The plan Id in Stripe <strong>cannot<\/strong> be a number. It needs to match the dap product name.<\/span><\/p>\n<p><strong>Trial Period Days: <\/strong> If you want to offer trial for 7 days, set trial period to 7 and set initial recurring cycle in DAP to 7 days.. The actual trial amount can be set in DAP products page -&gt; Price tab.<strong>Interval <\/strong>: If you set it to monthly, set the &#8216;Subsequent recurring cycle&#8217; in DAP to 30 days.<strong>Amount: <\/strong> This should be set to &#8216;Subscription \/ Recurring&#8217; amount. If you want to charge a different trial \/ initial amount, you can set that in DAP products page -&gt; price tab -&gt; Trial Amount.You can&#8217;t set that in Stripe because Stripe only allows for subscription amount.But the good news is&#8230; if you use DAP with Stripe, you can set the trial \/ initial amount in DAP and DAP will make sure the user gets charged the trial\/initial amount first and then the recurring amount will be charged at the end of trial period.Lets take a look at DAP products -&gt; Price&amp;Recurring tab setup for 3 usecases:<br \/>\n&#8211; $0 Trial + $49.99 Monthly Subscription<br \/>\n&#8211; $10 Trial (14 day) + $29.99 Monthly Subscription<br \/>\n&#8211; No Trial + $9.99 Monthly Subscription<\/p>\n<p><strong>$0 trial for 7 days + $49.99 monthly (30 day) subscription<\/strong><br \/>\nDAP setup :<\/p>\n<p><a href=\"http:\/\/www.digitalaccesspass.com\/doc\/wp-content\/uploads\/2013\/10\/dap-recurring-setup-7day.png\"><img loading=\"lazy\" class=\"alignnone  wp-image-2379\" style=\"border: 1px solid black;\" title=\"webhooks\" src=\"http:\/\/www.digitalaccesspass.com\/doc\/wp-content\/uploads\/2013\/10\/dap-recurring-setup-7day.png\" alt=\"\" width=\"449\" height=\"199\" \/><\/a><\/p>\n<p>Trial Price: $0<br \/>\nNOTE: If you do NOT want to offer trial OR if you want to offer $0 (FREE) trial, in both cases, set the Trial price = 0. During the payment button generation, you will be asked if the trial amount is set to 0 because it&#8217;s a FREE ($0) trial or if there is NO Trial. The button will be generated based on your input.<\/p>\n<p>Recurring Price: $49.99<br \/>\nRecurring Count: 999<br \/>\nNOTE: The recurring count should be 999 or more (unlimited) because Stripe does not support limited recurring.<\/p>\n<p>Recurring Cycle #1 : 7<br \/>\nNOTE: Set Recurring Cycle #1 (initial) to 7 for a &#8216;7 day&#8217; trial. If there is no trial, then if you want to charge users every 30 days, set it to 30.<\/p>\n<p>Subsequent Recurring Cycles: 30<br \/>\nSet subsequent recurring cycle to 30 for billing every 30 days (month)<\/p>\n<p><strong>$10 trial for 14 days + $29.99 monthly (30 day) subscription<\/strong><br \/>\nDAP setup :<br \/>\nTrial Price: $10<br \/>\nRecurring Price: $29.99<br \/>\nRecurring Count: 999<br \/>\nNOTE: The recurring count should be 999 or more (forever\/unlimited) because Stripe does not support limited recurring. The user will be charged every month until cancellation.<\/p>\n<p>Recurring Cycle #1 : 14<br \/>\nSubsequent Recurring Cycles: 30<\/p>\n<p><strong>No Trial + $9.99 Monthly Subscription<\/strong><br \/>\nDAP setup :<br \/>\nTrial Price: $0<br \/>\nIf there is NO trial and you want to charge the user $9.99 upfront + 9.99 every month, then set trial price = 0 and during button generation when you are prompted with &#8216;do you want to offer free trial&#8217;, you can say NO and button will be setup correctly.<\/p>\n<p>Recurring Price: $9.99<br \/>\nRecurring Count: 999<br \/>\nNOTE: The recurring count should be 999 or more (forever\/unlimited) because Stripe does not support limited recurring. The user will be charged every month until cancellation.<\/p>\n<p>Recurring Cycle #1 : 14<br \/>\nSubsequent Recurring Cycles: 30<\/p>\n<p><strong>Please NOTE: <\/strong> Make sure to first test each payment button before you go live.<\/p>\n<h3>DAP Cart Installation<\/h3>\n<p>Please <a href=\"http:\/\/www.digitalaccesspass.com\/doc\/dap-shopping-cart-installation\/\">read this <\/a>document on DAP Cart Installation.<\/p>\n<h3>Generate Payment Button<\/h3>\n<p><iframe loading=\"lazy\" src=\"\/\/www.youtube.com\/embed\/G3NuTiz8kaI?rel=0&amp;vq=hd720\" width=\"480\" height=\"271\" frameborder=\"0\" allowfullscreen=\"allowfullscreen\"><\/iframe><\/p>\n<p>You can generate &#8216;BuyNow&#8217; button OR generate &#8216;AddToCart&#8217; button.<br \/>\nIf you want to allow users to purchase individual products directly, create Buy-Now button.<br \/>\nIf you want to allow users to purchase add multiple items to a CART first and then checkout, use Add-To-Cart button.<\/p>\n<p>Please <a href=\"http:\/\/www.digitalaccesspass.com\/doc\/dap-shopping-cart-buynow-setup\/\">see this document<\/a> for more on buynow button generation.<\/p>\n<p>Please<a href=\"http:\/\/www.digitalaccesspass.com\/doc\/dap-shopping-cart-addtocart-setup\/\"> see this document <\/a>for more on add-to-cart button generation.<\/p>\n<h3>What makes DAP-&gt;Stripe integration unique?<\/h3>\n<p><strong>1)\u00a0\u00a0 Trial Amount allowed<\/strong><\/p>\n<p>Normally Stripe prevents users from setting a trial amount that is different from \u2018Subscription amount\u2019. If you want to sell a subscription product where say your users pay $100 upfront and then $30 every month, you cannot do that with Stripe.\u00a0 Normally you only have 2 options with Stripe &#8211;<\/p>\n<p>Free trial followed by subscription payments<\/p>\n<p>OR<\/p>\n<p>No trial, just subscription payments.<\/p>\n<p>So you can do $0 for 30 days and then $30\/month OR you can do $30 every month including first month.<\/p>\n<p>But the GOOD NEWS is that with DAP -&gt; Stripe integration, we will make it possible to do Trial + Subscription. You can do $0 free trial or you can do a trial with ANY AMOUNT of your choice for your subscription products.\u00a0 The \u2018trial amount\u2019 can be different from the \u2018subscription amount\u2019 because dap will make it possible.<\/p>\n<p><strong>2)\u00a0 Instant Charge\u00a0 <\/strong><\/p>\n<p>If you sell subscription products with Stripe,\u00a0Stripe will store the credit card info and ensure it can be charged before returning a response. BUT it can take up to one hour for the invoice to be actually charged.\u00a0 If you have a membership site where you want to allow INSTANT access to content after purchase and you want to make sure you received payment BEFORE you allowed access, then DAP will make it possible with Stripe by making sure the users are charged the first\/initial fee INSTANTLY without delay before the access is granted to the product\/content.<\/p>\n<p><strong>3) Access extended only upon\u00a0 successful subscription payment<\/strong><\/p>\n<p>DAP uses pay-as-you-go-model with Stripe. Users get access <em>only<\/em> to what they paid for. If it\u2019s a monthly subscription, they will get access only to the first month\u2019s content upon initial payment. DAP integrates with Stripe Webhooks for subscription payments. When the next subscription payment goes through successfully, dap will automatically extend access by another 30 days (recurring cycle).<\/p>\n<p>If a user cancels payment, DAP will no longer extend access as no more payments will come in, so the user will automatically lose access to product\/content at the end of current recurring cycle.<\/p>\n<p><strong>4) Coupons<\/strong><\/p>\n<p>You can use the DAP Cart\u2019s coupon feature and integrate it with Stripe coupons so users will see the discounted amount in the shopping cart after they apply a coupon and then Stripe will charge the correct discounted amount. You just have to match the coupon names and discount amounts in DAP and in Stripe. The DAP cart will support coupons for both multiple-items purchase (add-to-cart button) as well as single-item purchase (buy-now button).<\/p>\n<p><strong>5) Unlimited 1-click upsells \/ downsells<\/strong><\/p>\n<p>You can do an Unlimited number of Upsells and Downsells, and increase your sales by up to 30% with your <em>existing<\/em> products. Easy to configure. This feature offers Unlimited options and potential to grow your business.<\/p>\n<p><strong>6) Payment on your site <\/strong><\/p>\n<p>Users will stay on your site for Credit Card Payments. They will not get transferred to another site to make the payment.<\/p>\n<p><strong>7) PCI Compliance<\/strong><\/p>\n<p>DAP does not store the Credit Card information on your site so you do not have to worry about PCI compliance issues.<\/p>\n<p><strong>8) Paypal Integration<\/strong><\/p>\n<p>Integrated Credit Card (via Stripe) and Paypal (via Paypal Standard) payment option on the Checkout page. The users can pay using their Paypal account or using their Credit Card. So you will not lose sales from people that do not want to pull out a Credit Card for making the payment.<\/p>\n<p><strong>9) Pick your password<\/strong><\/p>\n<p>Allow your buyers to pick their OWN password for their membership account <em>before<\/em> purchase. DAP will use the user-picked password instead of generating a password for them.<\/p>\n<p><strong>10) Pre-registration \/ Capture email<br \/>\n<\/strong><\/p>\n<p>Allow Pre-Registration (User account will be created with a status of \u201cP\u201d) even if the payment fails so you will still have a way to communicate with these users.<\/p>\n<p><strong>11) Automated card expiration email <\/strong><\/p>\n<p>The email will get sent \u2018configured number of days\u2019 before the card expires. DAP will now allow you to proactively communicate with a customer when their card is about to expire. DAP will pre-determine when a card is going to expire and send an automated e-mail to inform the member it is time to update their credit card info on file.<\/p>\n<p><strong>12) Customer facing interface for \u201cUpdate CC and Billing\u201d<\/strong><\/p>\n<p>Your users can update their Credit Card and Billing Info themselves without having to hand it to you to update. It will take you just a couple minutes to set this up on your site.<\/p>\n<p><strong>13) Single and Multiple item purchases<\/strong><\/p>\n<p>Multiple items can be added to cart (via Add-To-Cart button) before final checkout. Or you can create simple buy now buttons for single-item purchases.<\/p>\n<p><strong>14) Custom fields<\/strong><\/p>\n<p>Add any number of Custom Fields to your Checkout Page. As long as these fields have been defined as custom fields in DAP, you can capture them in the checkout page. It will be stored in the user\u2019s profile.<\/p>\n<p><strong>15) Automated login<\/strong><\/p>\n<p>Users do not have to wait for \u2018welcome email\u2019 for their login \/ download credentials. They will get auto-logged-in to the member\u2019s area upon purchase, and can be sent straight to the downloads page or welcome page.<\/p>\n<p><strong>16) Existing users login<\/strong><\/p>\n<p>Allow existing users to \u2018log in\u2019 on the checkout page itself, so the new product purchase can be attached to their existing membership account. Their existing billing and profile info gets pre-populated on the checkout page upon login.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>DAP\/Stripe Integration Stripe is quickly gaining popularity as the go-to payment processor. It wins points for its incredible ease of use.\u00a0Stripe charges a fee of 2.9% + $0.30 per successful charge. Starting DAP v4.5, you can hook up the DAP Shopping Cart to Stripe.com for payments. This document explains how to connect Stripe to the [&hellip;]<\/p>\n","protected":false},"author":4,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[20],"tags":[],"_links":{"self":[{"href":"http:\/\/digitalaccesspass.com\/doc\/wp-json\/wp\/v2\/posts\/3674"}],"collection":[{"href":"http:\/\/digitalaccesspass.com\/doc\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/digitalaccesspass.com\/doc\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/digitalaccesspass.com\/doc\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"http:\/\/digitalaccesspass.com\/doc\/wp-json\/wp\/v2\/comments?post=3674"}],"version-history":[{"count":111,"href":"http:\/\/digitalaccesspass.com\/doc\/wp-json\/wp\/v2\/posts\/3674\/revisions"}],"predecessor-version":[{"id":4981,"href":"http:\/\/digitalaccesspass.com\/doc\/wp-json\/wp\/v2\/posts\/3674\/revisions\/4981"}],"wp:attachment":[{"href":"http:\/\/digitalaccesspass.com\/doc\/wp-json\/wp\/v2\/media?parent=3674"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/digitalaccesspass.com\/doc\/wp-json\/wp\/v2\/categories?post=3674"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/digitalaccesspass.com\/doc\/wp-json\/wp\/v2\/tags?post=3674"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}