Enrolment: Stripe Payment with SCA and Coupon

enrol_stripepayment
Maintained by Picture of DualCube TeamDualCube Team
Now avail the much-awaited coupon functionality while enrolling students in Moodle courses using a Stripe payment gateway for paid courses with Strong customer authentication (SCA). Stripe Receipt sent to customers for any successful transaction. This plugin will help the admins and webmasters to offer their students a percent-off or amount-off discount for the paid courses. This plugin helps admins and webmasters use Stripe as the payment gateway.
745 sites
847 downloads
42 fans
Current versions available: 2

Stripe Payment: 

Introducing the newest offering from Team Dualcube: Stripe Payment!

Now avail the much-awaited coupon functionality while enrolling students in Moodle courses using Stripe payment gateway for paid courses with Strong customer authentication (SCA).

This plugin will help the admins and webmasters to offer their students a percent-off or amount-off discount for the paid courses.


Stripe Payment:


1. Registered users can login to the Moodle site and happily apply the promo codes for a discount before payment. On successful payment, they can access the course.

2. Admins and Webmasters, now, can create, manage and keep track of all promotional codes directly in their Stripe dashboard.

3. Strong customer authentication (SCA) implemented with 4 layers of complex security to comply with EU Revised Directive on Payment Services (PSD2) on payment service providers within the European Economic Area.

4. The first of it's kind to use Payment intent method for Stripe-coupon. 

5. Works with all stable versions of Moodle till v 3.8.1

6. Latest Stripe SDK


Stripe Payment Documentation:



This plugin has all the settings for development as well as for production usage. Its easy to install, set up and effective.

Creating Merchant Account :

1) Create account at https://stripe.com.

2) Complete your merchant profile details from https://dashboard.stripe.com/account.

3) Now set up secret key and publishers key at https://dashboard.stripe.com/account/apikeys.

4) For test mode use test api keys and for live mode use live api keys.

Now you are done with merchant account set up.

Installation Guidance : 

Login to your moodle site as an “admin user” and follow the steps.

1) Upload the zip package from Site administration > Plugins > Install plugins. Choose Plugin type 'Enrolment method (enrol)'. Upload the ZIP package, check the acknowledgement and install.

2) Go to Enrolments > Manage enrol plugins > Enable 'Stripe' from list

3) Click 'Settings' which will lead to the settings page of the plugin

4) Provide merchant credentials for Stripe. Note that, you will get all the details from your merchant account. Now select the checkbox as per requirement. Save the settings.

5) Select any course from course listing page.

6) Go to Course administration > Users > Enrolment methods > Add method 'Stripe' from the dropdown. Set 'Custom instance name', 'Enrol cost' etc and add the method.

Adding coupons:

Go to your Stripe Dashboard >  Billing > Coupons > Create a coupon.

Type in the coupon’s name: it can be anything and for your reference only.
Type in the Coupon’s ID : This is the Coupon code which your students will need to enter if they want to avail the discount.

Choose Coupon Type: 
1. Percentage discount : offers % off on the course price 
2. Fixed amount discount : Offers a fixed amount off on the course price.

Duration: For duration, when using the value repeating, also specify duration in months as the number of months for which the coupon should repeatedly apply. Otherwise the coupon can be set to apply only to a single invoice or to them all.

Redemption : The max_redemptions and redeem_by values apply to the coupon across every customer you have. For example, you can restrict a coupon to the first 50 customers that use it, or you can make a coupon expire by a certain date. If you do the latter, this only impacts when the coupon can be applied to a customer. If you set a coupon to last forever when used by a customer, but have it expire on January 1st, any customer given that coupon will have that coupon’s discount forever, but no new customers can apply the coupon after January 1st.

If a coupon has a max_redemptions value of 50, it can only be applied among all your customers a total of 50 times, although there’s nothing preventing a single customer from using it multiple times. (You can always use logic on your end to prevent that from occurring.)


 

This completes all the steps from the administrator end. Now registered users can login to the Moodle site and view the course after a successful payment of the discounted price. 


Screenshots

Screenshot #0
Screenshot #1
Screenshot #2
Screenshot #3
Screenshot #4

Contributors

Picture of DualCube Team
DualCube Team (Lead maintainer)
Please login to view contributors details and/or to contact them

Comments RSS

Comments

  • Picture of Plugins bot
    Thu, Dec 10, 2015, 12:11 AM
  • Picture of DualCube Team
    Thu, Dec 10, 2015, 8:59 PM
    The errors have been fixed and wee have re-uploaded a version of this plugin. Please check and let us know.
  • Picture of David Mudrák
    Tue, Dec 15, 2015, 4:05 AM

    Thanks guys for sharing yet another plugin with the Moodle community. While checking the code, I noticed two issues that should be checked and fixed before we can approve the plugin here (see #1 and #2 in your tracker). Thanks for you patience with the review and approval process.

  • Picture of DualCube Team
    Tue, Dec 15, 2015, 3:08 PM
    Hi David,

    Thanks for your feedback! Sure, we will get these fixed and notify you when done. Thanks again for your co-operation, much appreciated smile

    Thanks and Regards,
    Arindam
  • Picture of DualCube Team
    Wed, Dec 16, 2015, 5:08 PM
    Hi David,

    We have submitted the plugin with the fixes you mentioned. Kindly let me know if you would like to suggest or notify anything.

    Thanks and Regards,
    Arindam
  • Picture of DualCube Team
    Tue, Jan 5, 2016, 8:08 PM
    Hi David,

    Hope you all are dong good! We wish you a very happy and prosperous new year from team Dualcube smile
    I am checking in to see if you guys had the chance to check this plugin.

    Thanks and Regards,
    Arindam
  • Picture of David Mudrák
    Fri, Jan 8, 2016, 8:20 PM

    Thanks for the updates guys, and sorry for the delay with the review caused by the holiday break. I have not studied the payment API in details so I just must hope it follows the best practises there in terms of security etc (when dealing with real money and payment card numbers, extra attention must be paid). I left some findings from the code review in your issues tracker to be considered in further updates of the plugin. For now, you are cleared to land. Welcome to the Plugins directory.

  • CPDO Clock
    Fri, Jan 22, 2016, 4:06 AM
    Very streamlined and conversion friendly plugin. Thank you! I was able to change the default text in the "enrol.html" file but when I tried to reference an image url in the "data_image" field, it shows as a broken link in the credit card input window, at the top where the 128x128 pixel image would show. It might make sense to have a file upload window, much like the windows for uploading course materials. These can be set to check the specs of the image and post instant error messages if they don't fit. Any ideas as to what the image url would look like or which folder I should upload the image to? I would like this popup to appear branded.
  • Picture of DualCube Team
    Sat, Jan 23, 2016, 4:10 PM
    Hi Sean,

    Thanks for using our plugin and the appreciating words! Please us e the following to display logo,
    <?php p($PAGE->theme->setting_file_url('logo', 'logo')) ?>
    Let me know if that works.

    Thanks and Regards,
    Arindam
  • CPDO Clock
    Sun, Jan 24, 2016, 12:06 AM
    Thank you Arindam. You are magical.
  • Picture of Andrew Lian
    Mon, Feb 8, 2016, 1:00 PM
    Hello,

    before I go to the trouble of installing this, would you please tell me if there is a facility in the plugin for expiring access to a course after a certain time (e.g. 30 days)? Or does it just let users get access but does not exclude them after a certain amount of time has elapsed?

    Thanks
    Andrew
  • CPDO Clock
    Wed, Feb 10, 2016, 1:08 AM
    Is there a way to show the short name for the course in the gateway window and subsequently in the Stripe dashboard. My payments show as "Charge For Course Enrolment Cost" in the dashboard. It would be good for reporting if the course name showed instead.
  • Picture of DualCube Team
    Wed, Feb 10, 2016, 7:54 PM
    Hi Sean,

    Thanks for reaching out to us!

    Go to stripepayment plugins folder, then open enrol.html file, you will see
    data-name="Moodle Course Enrolment"
    data-description="Enrolment Cost (<?php p($instance->currency) ?><?php p($cost) ?>)"

    You can change both the above text as you like.

    Thanks and Regards,
    Arindam
  • Picture of DualCube Team
    Wed, Feb 10, 2016, 7:56 PM
    Hi Andrew,

    In the stripe enrolment settings (Enrolment expiration action), if you select "keep user enrol" then even after expiry time the user can access the courses, if you select "unenrol from course" then user is unenrolled after expiry time. or if you select "disable course enrol and remove roles" then user is still enrolled in the course but disabled. Then is the default enrolment settings like paypal.

    Let me know if this helps!

    Thanks and Regards,
    Arindam
Please login to post comments