# Top topics this week on a Discourse forum, with replies

**Use case:** 

Reads a Discourse forum's Top list for the current week and returns one row per topic — title, category, tags, reply and view counts, dates and the starting username — plus up to 5 posts per topic as Markdown, one row each. Point it at any public Discourse forum by changing the URL, switch the period to monthly or all-time, or set includePosts to false for a topic index only.

## Input

```json
{
  "forumUrl": "https://forum.obsidian.md",
  "mode": "top",
  "period": "weekly",
  "category": "",
  "tag": "",
  "query": "",
  "topicIds": [],
  "maxTopics": 30,
  "includePosts": true,
  "maxPostsPerTopic": 5,
  "postFormat": "markdown",
  "keywords": [],
  "includeCategories": false,
  "maxConcurrency": 3,
  "maxRunSecs": 240,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}
```

## Output

```json
{
  "title": {
    "label": "Title",
    "format": "string"
  },
  "categoryName": {
    "label": "Category name",
    "format": "string"
  },
  "tags": {
    "label": "Tags",
    "format": "array"
  },
  "postsCount": {
    "label": "Posts",
    "format": "integer"
  },
  "views": {
    "label": "Views",
    "format": "integer"
  },
  "likeCount": {
    "label": "Likes",
    "format": "integer"
  },
  "lastPostedAt": {
    "label": "Last posted at",
    "format": "string"
  },
  "originalPosterUsername": {
    "label": "Original poster",
    "format": "string"
  },
  "url": {
    "label": "URL",
    "format": "string"
  }
}
```

## About this Actor

This example demonstrates how to use [Discourse Forum API — Topics, Posts & Categories](https://apify.com/insight.solutions/discourse-forum-api.md) with a specific input configuration. Visit the [Actor detail page](https://apify.com/insight.solutions/discourse-forum-api.md) to learn more, explore other use cases, and run it yourself.


## How to integrate an Actor?

This Task's input is already configured above. Use it as-is rather than inventing a new one.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For full API examples (JavaScript, Python, CLI, MCP, OpenAPI), see this Task's Actor page: https://apify.com/insight.solutions/discourse-forum-api.md

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).
