I have more than approx. 600 course enrolled on Udemy, it is very pain to browse my courses, since Udemy shows only 12 course per page therefore I have to browse more than 50 page to see all the course I have, I messaged Udemy but they are not responding to my request, I’m sure many people are facing this issues.
I want to list all my enrolled course of Udemy account so that I can planned my studies according to my available recourses, since sometimes I forget I already have course that I have to learn.
I’m amateur programmer, I had made the script to get the title, video content length, rating, and no of user enrolled tag to sort the best course for me to start learning and export them to excel, but problem is I get stuck in pagination.
Can anyone help/provide me the Python/JavaScript script to list all the enrolled course of Udemy in single Excel sheet.
Traceback (most recent call last):
File “C:\Users\Username\OneDrive\Desktop\udemy.py”, line 1, in
import requests
ModuleNotFoundError: No module named ‘requests’
Thanks for your share. Your script is working nice. I tried 2 times it’s import 201 courses from 1000 courses enrolled. Showing following ERROR
–
Traceback (most recent call last):
File “E:\Wp-Projects#3-WebTools\Udemy-CL\udemy.py”, line 39, in
writer.writerow([courseName, courseUrl])
File “C:\Python\Python38\lib\encodings\cp1252.py”, line 19, in encode
return codecs.charmap_encode(input,self.errors,encoding_table)[0]
UnicodeEncodeError: ‘charmap’ codec can’t encode characters in position 12-15: character maps to
Need your kind help. I need whole list of enrolled courses.
P.S. I am using " Python 3.8.1"
Hey can u tell from where you get the documentatioin for the Udemy’s API? I searched for it and https://www.udemy.com/developers/affiliate/ one does not seem to mention the paths that you have accessed from your code.
I modified the code to get many features of the course in csv file title, author, rating, length, last_update, badge.
Thank you @pankaj260 for giving ray of hope.
cmd/terminal:
Download the folder and navigate to file in folder in cmd/terminal
run: pip install -r requirements.txt
run: python udemyEnrolled.py
Paste the access_token of Udemy
or
jupyter/colab:
open python notebook and follow the flow.
note: some data are not available, because of Udemy’s new page design please feel free to modify the code according to your need.
edit: fix minor bugs
@Saitama Excellent script.Works just fine.But you made a small typo in your code. You saved the txt file as req.txt but in code you accessed requirements.txt. Hope you fix it. Great work.