

Activate Virtual Environment source venv/Bin/activate.Create Virtual Environment python3 -m venv venv.Create a new folder to store your JSON data and the Python files mkdir medium-analysis.How to use the browser console to scrape and save data in a file with JavaScriptĪ while back I had to crawl a site for links, and further use those page links to crawl data using selenium or… We will need to use the script I provided earlier. The following article talks about downloading your Medium Stories. Run the script in your console and it will download a JSON file with all your stats. The JSON file will basically be an array of objects having the above properties.īasically, we will have to go to and scroll all the way to the bottom, i.e scroll till you see all your articles. Publication the article was published in.However, if you want more metrics/stats about your articles, you will have to tinker around with the script. You don’t need to know JavaScript, you can run the script as-is. Check this article to see how you can access your browser’s console. We will essentially be scraping the stats, we will have to do it using JavaScript since it will have to run in your browser’s console. Unfortunately Medium doesn’t seem to have any easy-to-use API publicly available so we will have to use a slightly hacky solution. You can find the repo here Getting Medium Stats in a JSON format

Display the charts on a UI created using Streamlit.Use Pandas and Plotting libraries to plot charts.How to get a JSON file of your Medium Stats and create a Dashboard using Streamlit
