Fetch Discourse Topics and Categories

This Python script is designed to help Discourse forum administrators and data enthusiasts gather, analyze, and manipulate important forum data like topics, categories, views, likes, and more. With powerful filtering options and output formats such as .txt, .csv, and .json, this tool allows you to reverse engineer and explore your forum data in ways that can unlock deeper insights and help in optimizing community engagement.

Key Features:

  • List Categories: Fetch and display all categories from your Discourse forum.
  • Filter Topics by Date or Keyword: Allows you to fetch topics within a specific date range or based on keywords in the topic titles.
  • User Details: Optionally retrieve details about the users who last posted in a topic, including post count and registration date.
  • Topic Descriptions: Include topic descriptions when available, offering more context.
  • Last Post Timestamps: Optionally include the timestamp of the last post for each topic.

The Primary Intention:

This script was created with the aim to enhance data analysis and integration. It helps in exploring and understanding various aspects of your Discourse forum, such as engagement trends and activity patterns. Key use cases include:

  • Advanced Analytics: Leverage topic and user data to generate insights about community engagement. Analyze which topics are driving the most activity, or track trends over time.
  • Integration with Other Systems: The script can be integrated with custom analytics platforms or other tools to manipulate data as needed for specific use cases.
  • Custom Metrics: Alter or simulate metrics like views and likes to test different scenarios and assess how changes in user behavior or content affect engagement. This can be especially useful when testing content strategies or new features.

The goal is to empower forum administrators, marketers, and community managers to experiment with data-driven decisions without the need for complex setups or third-party services.

Important Note on Ethical Use:

While the script offers the flexibility to manipulate views, likes, and other engagement metrics, it is important to remember that these features should be used for analysis, testing, and optimization purposes only.

This tool is not designed for artificially inflating metrics or attempting to mislead users with fake data. The core objective is to provide insights into genuine user activity and community health. For sustained growth, it is always best to focus on creating valuable content and fostering real community engagement.

Use Cases:

  1. Marketing & Campaign Analysis: Evaluate how marketing campaigns are impacting engagement by simulating changes in topic views and likes.
  2. Content Optimization: Test how altering engagement metrics might affect the visibility of content across your community.
  3. Forum Testing & Experimentation: Experiment with simulated data to understand how changes to topics or user behavior could impact overall forum performance.
  4. Customer Insights: Use the script to gain a deeper understanding of which topics drive the most engagement, helping you better cater to your community’s interests.
  5. Competitor Analysis: Track topics and activity levels in competing communities and gain valuable insights for your own community strategies.
  6. Community Growth & Development: Explore how changes to your content or community structure might impact user activity, leading to more informed decisions for growth.

Example Output:

  • Text File: Comprehensive list of topics, categories, and metrics, with optional detailed information like descriptions and user data.
  • CSV: Structured data for analysis, useful for importing into spreadsheets or other tools for deeper analysis.
  • JSON: A machine-readable format for easy integration with other systems or for further manipulation.

Installation & Setup:

  1. Clone the repository:
    git clone https://github.com/mihirranjan7/fetch-discourse-categories-and-id.git
    cd fetch-discourse-categories-and-id
    
  2. Install dependencies:
    pip install -r requirements.txt
    
  3. Set up your .env file with your Discourse API credentials.
  4. Run the script:
    python discourse_topic_fetcher.py
    

Repository:

You can find the full project on GitHub: fetch-discourse-categories-and-id


1 Like