Get total list of topics and their view counts from Discourse API

Hello there,

I’m trying to see if there’s a way to reverse-engineer getting a complete list of topics and views for each of those topics via the Discourse API.

Ideally, something as simple as the landing page of a Discourse server with topic names and views in JSON format would be perfect, but from what I can tell from the API documentation there doesn’t seem to be an endpoint that can provide this high level overview.

Is there such a way to get this data in a nice format that I could pipe through to an analytics dashboard API?

Thanks in advance.

1 Like

Would Data Explorer work? It’s possible to make SQL queries with Data Explorer and then get the results with the API.

3 Likes

Would https://meta.discourse.org/latest.json be good enough? That includes topic titles, and view count. Docs can be found here.

If you need more advanced filtering, then data explorer is also a good choice as @j127 mentioned :+1:

4 Likes

Thank you both for the suggestions - I’ll start checking out both of them this morning to see what might work. I appreciate it!

3 Likes