How I Built a Python Scraper and WeChat Mini‑Program for Zhihu & Weibo Hot Lists
After months of trial and error, I share my step‑by‑step journey of creating a Python web scraper that collects Zhihu and Weibo hot‑list data, exposing it via a Django REST API, and integrating the results into a functional WeChat mini‑program, while outlining the challenges and future improvements.
Two months ago I wrote a short article about crawling Zhihu and Weibo hot lists; the conclusion was that obtaining data is only the first step, and processing it adds real value.
My plan was to turn the scraped data into an API and develop a WeChat mini‑program to display the hot‑list information.
After a fragmented development process, I now have a prototype consisting of two basic pages: a Zhihu hot‑list display and a Weibo hot‑list display.
The current roadmap includes removing raw links, making each item clickable to view details, and refining the UI based on WeChat mini‑program design guidelines.
Technical steps I followed:
Define the target functionality; the scraper is the first step to obtain data for the mini‑program.
Expose the scraped data via a RESTful API built with Django and Django REST framework.
Deploy the API to a server so it can be accessed remotely.
Configure a domain name, obtain an ICP license, and install an HTTPS certificate to satisfy WeChat’s requirement for secure requests.
Develop the WeChat mini‑program pages that fetch the API data and render it.
At present the above stages are completed; next I will focus on UI optimization and adding more features. Feedback and suggestions are welcome.
Signed-in readers can open the original source through BestHub's protected redirect.
This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactand we will review it promptly.
Python Crawling & Data Mining
Life's short, I code in Python. This channel shares Python web crawling, data mining, analysis, processing, visualization, automated testing, DevOps, big data, AI, cloud computing, machine learning tools, resources, news, technical articles, tutorial videos and learning materials. Join us!
How this landed with the community
Was this worth your time?
0 Comments
Thoughtful readers leave field notes, pushback, and hard-won operational detail here.
