How I Use Huginn - Syncing Xlog to Discord#
What is Huginn#
Create agents that monitor and act on your behalf. Your agents are standing by!
https://github.com/huginn/huginn
How to Deploy Huginn (Docker)#
mkdir huginn && cd huginn
vi docker-compose.yml
Here we use the built-in storage directly
docker-compose.yml
version: '3.8'
services:
app:
image: ghcr.io/huginn/huginn
ports:
- "3000:3000"
restart: always
docker compose up -d
Browse
http://localhost:3000
Default account admin/password
Syncing Xlog RSS to Discord#
- Create a new "Agent" and select the RSS plugin as the Trigger.
- In the configuration options of the "RSS Agent", set the "Feed URL" to the URL of your Xlog RSS Feed.
- Configure the "Post Agent" plugin as the Action and follow Discord's instructions to create a new Webhook to submit the RSS Feed data to Discord.
- Copy the "Webhook URL" to the configuration option of "Webhook".
{
"post_url": "your discord webhook url",
"expected_receive_period_in_days": "1",
"content_type": "form",
"method": "post",
"payload": {
"key": "value",
"something": "the event contained {{ somekey }}"
},
"headers": {},
"emit_events": "false",
"no_merge": "false",
"output_mode": "clean"
}
- Configure the "Webhook Payload" option to convert each item you get from the RSS Feed into a format that Discord can understand.
- Edit the "Webhook Payload" option and set it to JSON format containing the appropriate data. For example:
{
"embeds": [{
"title": "{{title}}",
"description": "{{description}}",
"url": "{{url}}",
"author": {"name": "Xlog RSS"},
"timestamp": "{{pubDate}}"
}]
}
Test and enable your Agent.