Get Topic
discourse.get_topic
ActionBusiness appsconnection required
Calls the Discourse API with the connection's credentials.
Read a topic and the first chunk of its posts.
Connection
- Required
- Yes — the node will not save without one
- Auth type
- API key
- Providers
- Discourse
- Secret shape
- the API key, or {"api_key": "…"}
- Config it needs
- base_url, api_username
- Resolved by
- config.connection_id, else node.connection_id
Configuration
1 field, 1 required. A dotted path is a nested object and name[] an array of objects — the editor renders the same tree.
| Field | Type | Required | Default | Constraints | Example |
|---|---|---|---|---|---|
topic_id The topic's numeric Discourse id, the number in a /t/slug/<id> URL. | string | Yes | — | — | 1234 |
Example configuration
Every value below is the contract’s own example or default — nothing invented.
{
"topic_id": "1234"
}Output
One shape.
result
| Field | Type | Example |
|---|---|---|
topic The topic record Discourse returned, in full. | object | — |
id The topic's id. | number | — |
title The topic's title. | string | — |
slug The topic's URL slug. | string | — |
category_id The category the topic sits in. | number | — |
posts_count How many posts the topic has in total. | number | — |
posts The posts in this chunk of the topic's post stream. | array | — |
closed True when the topic is closed to new replies. | boolean | — |
archived True when the topic is archived. | boolean | — |
{
"archived": false,
"category_id": 0,
"closed": false,
"id": 0,
"posts": [],
"posts_count": 0,
"slug": "",
"title": "",
"topic": {}
}Related Discourse nodes
See Get Topic run in a workflow.
In a technical demo we add the Discourse connection, drop the node on the canvas and let Workflow Health pre-flight it before the first real run.