D
Knowledge Bases

Discourse

Index forum topics, replies, and accepted answers from Discourse

What is Discourse?

Discourse is the leading open-source discussion platform used by developer communities, support teams, and enterprise intranets. It organizes knowledge into topics and replies, often with a 'solved' answer marked by the community. BeforeQuery indexes this structure so AI answers can draw on the collective intelligence already captured in your Discourse forum.

Integration

How BeforeQuery works with Discourse

Everything you can do once the integration is connected.

Topic and reply indexing

BeforeQuery indexes every topic title, first post, and reply. Accepted (solved) answers are given higher weight during retrieval so the best community answers surface first.

Category and tag filters

Restrict indexing to specific Discourse categories or tags — for example, only your 'How-To' and 'Support' categories. Exclude off-topic boards like 'General Discussion' or 'Meta'.

Incremental sync

BeforeQuery polls your Discourse API or responds to webhook events to pick up new topics and replies on a schedule you control. Solved-answer status updates are re-indexed automatically.

Private category support

Provide a Discourse API key scoped to the categories you want indexed. BeforeQuery can index private or staff-only categories without exposing them publicly through the widget.

Setup

How to set it up

1

In the BeforeQuery dashboard, add a source of type discourse. Enter your Discourse forum base URL and a read-only API key from your Discourse admin panel.

2

Configure category and tag filters so only relevant boards are indexed. Optionally enable solved-answer boosting to prioritize accepted community answers in retrieval.

3

Set a sync schedule (daily or hourly) or configure a Discourse webhook pointing to your BeforeQuery sync endpoint so new solved topics are indexed automatically.

Discourse — Frequently Asked Questions

Common questions about connecting BeforeQuery to Discourse.

By default BeforeQuery indexes all topics and their replies in your configured categories. You can use category and tag filters to restrict indexing to specific boards, and you can exclude threads below a minimum reply or vote threshold to focus on high-quality content.
Yes. BeforeQuery identifies posts marked as the accepted solution in Discourse and boosts their retrieval weight. When a user asks a question that matches a solved topic, the accepted answer is more likely to be cited in the AI response.
Yes. Provide a Discourse API key that has read access to the private categories you want indexed. Content from private categories is indexed and retrievable only through authenticated BeforeQuery surfaces (portal, dashboard) — not through public widget deployments unless you explicitly allow it.
You can configure a scheduled sync (hourly, daily) from the BeforeQuery dashboard. For near-real-time updates, configure a Discourse webhook that calls your BeforeQuery project sync endpoint whenever a topic is created or a post is marked as solved.
Yes. The Discourse source configuration accepts both category slugs and tag names as inclusion or exclusion filters. For example, you can index only topics tagged 'faq' or 'tutorial' across any category.

Ready to connect Discourse?

Start free. No credit card required. Connect your first integration in under 5 minutes.