
Research
Malicious npm Packages Impersonate Flashbots SDKs, Targeting Ethereum Wallet Credentials
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
gatsby-source-discourse-topic-list
Advanced tools
Source topic lists from the Discourse discussion forum platform and transform it into Gatsby nodes.
gatsby-source-discourse-topic-list helps you source topic lists from the Discourse discussion forum platform and transform it into Gatsby nodes.
In addition to the topic list provided by the Discourse api, the plugin also fetches the raw text for each topic.
yarn add gatsby-source-discourse-topic-list
module.exports = {
plugins: [
{
resolve: "gatsby-source-discourse-topic-list",
options: {
url: "https://my-discourse-server.com"
endPoint: 'top.json',
}
}
]
};
Name | Type | Description |
---|---|---|
url | object or string | Required. Url of your Discourse installation as a string. If you have two different APIs for development and production, define an object with the keys production and development . |
endPoint | string | Required. Any Discourse API endpoint returning a topic_list . |
rootKey | string | Optional. Name your API. |
Latest topics in a category:
options: {
url: "https://meta.discourse.org"
endPoint: 'c/1.json',
}
Latest topics in a category, filtered by tag:
options: {
url: "https://meta.discourse.org"
endPoint: 'tags/c/bug/1/pr-welcome.json',
}
Top topics in a category:
options: {
url: "https://meta.discourse.org"
endPoint: 'c/support/6/l/top.json',
}
See the Discourse API documentation for a full list of endpoints.
Note the added raw
field containing the full unprocessed post topic text.
{
"users": [
{
"id": 0,
"username": "string",
"avatar_template": "string"
}
],
"topic_list": {
"can_create_topic": true,
"draft": {},
"draft_key": "string",
"draft_sequence": 0,
"for_period": "string",
"per_page": 0,
"topics": [
{
"id": 0,
"title": "string",
"fancy_title": "string",
"slug": "string",
"raw": "The full unprocessed topic text in markdown format",
"posts_count": 0,
"reply_count": 0,
"highest_post_number": 0,
"image_url": {},
"created_at": "string",
"last_posted_at": "string",
"bumped": true,
"bumped_at": "string",
"unseen": true,
"last_read_post_number": 0,
"unread": 0,
"new_posts": 0,
"pinned": true,
"unpinned": {},
"visible": true,
"closed": true,
"archived": true,
"notification_level": 0,
"bookmarked": true,
"liked": true,
"views": 0,
"like_count": 0,
"has_summary": true,
"archetype": "string",
"last_poster_username": "string",
"category_id": 0,
"pinned_globally": true,
"posters": [
{
"extras": "string",
"description": "string",
"user_id": 0
}
]
}
]
}
}
If you would like to fetch multiple endpoints in your project, just instantiate the plugin multiple times. Just be sure to set a different rootKey
for every instance.
This plugin builds on the excellent gatsby-source-custom-api by Andreas Faust. 🙏
Every contribution is very much appreciated. Feel free to file bugs, feature- and pull-requests.
❤️ If this plugin is helpful for you, star it on GitHub.
FAQs
Source topic lists from the Discourse discussion forum platform and transform it into Gatsby nodes.
We found that gatsby-source-discourse-topic-list demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
Security News
Ruby maintainers from Bundler and rbenv teams are building rv to bring Python uv's speed and unified tooling approach to Ruby development.
Security News
Following last week’s supply chain attack, Nx published findings on the GitHub Actions exploit and moved npm publishing to Trusted Publishers.