Exclude / Suppress (Automatically) Closed Topics from the Homepage?

AI-generated summary

The discussion explores whether closed topics should be automatically excluded from the Discourse homepage to reduce clutter, specifically for time-sensitive API-generated content. mr8 requests an admin setting to suppress closed topics, noting that current workarounds like moving them to archival categories are cumbersome. mcwumbly suggests using the existing “Make Unlisted” feature via the API, proposing a delay (e.g., 24 hours) after closure to maintain transparency before topics become invisible. They also recommend a category setting to automatically unlist closed topics after a set duration. However, riking questions if this is a genuine problem, arguing that keeping closed topics visible aids future archival searches. cpradio clarifies that unlisted topics are hidden from normal members and no longer indexed by Google. Later, balthatrix seeks a specific API example using the Discourse gem to implement this. riking directs them to a guide on reverse-engineering the API, which balthatrix appreciates for its comprehensive nature.

We have a couple of topics that we create through the API that automatically get closed after a week due to the time sensitivity of the content. Although this works great for us, we’ve noticed that those closed topics still sort of clutter our homepage (which is set to Latest) when scrolling down a couple of pages.

I supposed we could have another script move those topics via the API to an archival category that is suppressed from the homepage, but it would be great if there were an admin setting to suppress or exclude automatically closed topics (or even just regular closed topics) from the Homepage.

From the Admin wrench within a topic you can “Make Unlisted”.

That could be done via the API too, without breaking categorization.

You might consider having that happen 24+ hours after the topic is closed, so there is some transparency about the fact that a topic was closed before it becomes invisible.

Perhaps a category setting to “unlist closed topics after N hours” would be a worth considering…

You could also consider whether or not this is really a problem - being able to easily search for & view those topics may be valuable as an archive later.

1 Mi Piace

Does unlisting make it not show up in search? I hadn’t considered that…

For normal members, yes, and unlisted is no longer indexed by Google.

5 Mi Piace

Hey there,

I’m trying to figure out how to do this with an api call. Can you provide an example? Preferably, one using the discourse gem if possible. I’ve tried a number of things that don’t seem to work… Thanks!

Please see this topic:

3 Mi Piace

Thanks, I like it! Specific question → General encompassing answer