Stripe configuration for Tutor, Juniper Open edX release

Hi,

I have set up an education web platform using Tutor with Open edX Juniper release. Can I please have the steps to set up Stripe payments next?

#tutor

Thank you.

RG

1 Like

Hello @rvgi2904,

You can use the Ecommerce plugin for the payment in the tutor.

And ecommerce of Open edX provides stripe as payment gateway by default. You can refer this documentation for Open edX ecommerce stripe payment gateway.

2 Likes

Thanks @jramnai for this

We use the Stripe as Payment Processor.

  1. Create an account or test account in Stripe, and get the api keys.

https://dashboard.stripe.com/test/dashboard

  1. Create ecommerce-config.yml

Fill in the details of the api keys. Keep the file secure.

stripe:
  publishable_key: pk_test_XXXX
  secret_key: sk_test_XXX
  country: db
  1. Set up the payment processor in tutor.
tutor config save --set "ECOMMERCE_PAYMENT_PROCESSORS=$(cat ecommerce-config.yml)" \
 --set 'ECOMMERCE_ENABLED_PAYMENT_PROCESSORS=["stripe"]' \
 --set 'ECOMMERCE_ENABLED_CLIENT_SIDE_PAYMENT_PROCESSORS=["stripe"]'
tutor local init --limit=ecommerce
  1. Create Commerce Configuration in Django LMS Dashboard

In the django administration dashboard, section “Home › Commerce › Commerce configurations”

https://tutor.yoursite.com/admin/commerce/commerceconfiguration/

Add Commerce Configuration

Enabled: True
Checkout on ecommerce service: True
Basket checkout page:	/basket/add/
Cache Time To Live: 360
Receipt page: /checkout/receipt/?order_number=
Enable automatic refund approval: True
  1. Create waffle flag in Django Ecommerce Dashboard

In the django administration dashboard, section “Home › django-waffle › Flags › enable_client_side_checkout”

https://ecommerce.tutor.yoursite.com/admin/waffle/flag/

Add:

Name: enable_client_side_checkout
Everyone: Yes
Superusers: True
Staff: True
Authenticated: True
Note: This flag determines if the integrated/client-side checkout flow should be enabled.

More info in: Stripe ecommerce checkout errors - #7 by Headhurts - Tutor - Overhang.IO

  1. Create a course in the E-Commerce Courses page

Get the course key from the LMS by navigating to a course and examining its URL. The course key should look something like course-v1:edX+DemoX+Demo_Course.

Navigate to the E-Commerce Courses page (https://ecommerce.tutor.yoursite.com/courses/) to add the two test courses that are on your LMS instance to E-Commerce. Configure one course as a “Verified” course.

e.g.: https://ecommerce.tutor.yoursite.com/courses/course-v1:edX+DemoX+Demo_Course

Check different types of enrollment tracks in the documentation resources below.

  1. Enroll in a Paid Course in the LMS

e.g.: With a student account, go to the configured paid course:

https://tutor.yoursite.com/courses/course-v1:edX+DemoX+Demo_Course/about

and click on “Enroll Now”

That will redirect to the ecommerce module in: https://ecommerce.tutor.yoursite.com/basket/

  1. Use a test card to complete the checkout.

Get a Test Card from: https://stripe.com/docs/testing#cards

  1. Check the Ecommerce Dashboard to get an overview of the payments:

With an administrator account go to:

https://ecommerce.tutor.yoursite.com/dashboard/

  1. Check the status of the payments in the stripe dashboard:

https://dashboard.stripe.com/test/payments?status[]=successful

Documentation used to configure the ecommerce module

https://edx.readthedocs.io/projects/edx-installing-configuring-and-running/en/open-release-juniper.master/glossary.html?highlight=fees#e

https://edx.readthedocs.io/projects/open-edx-building-and-running-a-course/en/named-release-cypress/running_course/manage_course_fees.html#set-the-price-of-the-course

https://edx.readthedocs.io/projects/edx-installing-configuring-and-running/en/latest/ecommerce/test_ecommerce.html

PD:
Tutor has his own discuss instance: discuss.overhang.io

4 Likes

Thank you @Juan_M_Mendez for your reply. I will be following these steps while I set it up today.

1 Like

Hello @Juan_M_Mendez

I tried all the steps you mentioned. When I enter the stripe test card details on the payment page. Then error is thrown.

It generates token but it expects payment_intent_id and hence the error.
Do you know how I can solve it??
Thanks

I am sorry that I am not familiar with that error.
My thoughts are that since this was 3 years ago. The versions you are using are probably different.
That was done with GitHub - overhangio/tutor: The Docker-based Open edX distribution designed for peace of mind
with the Juniper Release. Might be you should open a new issue for your used Release.

Thanks for the reply.