{"id":21115563,"url":"https://github.com/webu/dalec-discourse","last_synced_at":"2025-08-03T03:07:04.302Z","repository":{"id":176963473,"uuid":"658685227","full_name":"webu/dalec-discourse","owner":"webu","description":" DALEC -- Aggregate a lot of discourse content for django ","archived":false,"fork":false,"pushed_at":"2024-02-23T15:09:09.000Z","size":49,"stargazers_count":1,"open_issues_count":2,"forks_count":4,"subscribers_count":3,"default_branch":"main","last_synced_at":"2024-06-11T17:42:01.026Z","etag":null,"topics":["aggregator","dalec","discourse","django"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/webu.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":"AUTHORS","dei":null}},"created_at":"2023-06-26T09:36:01.000Z","updated_at":"2024-02-23T15:04:10.000Z","dependencies_parsed_at":"2024-02-21T10:28:46.235Z","dependency_job_id":"a760cb5b-d070-48f4-9df6-44237536af3c","html_url":"https://github.com/webu/dalec-discourse","commit_stats":null,"previous_names":["webu/dalec-discourse"],"tags_count":8,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/webu%2Fdalec-discourse","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/webu%2Fdalec-discourse/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/webu%2Fdalec-discourse/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/webu%2Fdalec-discourse/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/webu","download_url":"https://codeload.github.com/webu/dalec-discourse/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":225454440,"owners_count":17476822,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["aggregator","dalec","discourse","django"],"created_at":"2024-11-20T02:01:05.143Z","updated_at":"2024-11-20T02:03:47.707Z","avatar_url":"https://github.com/webu.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 🗣 dalec-discourse\n\n[![Stable Version](https://img.shields.io/pypi/v/dalec-discourse?color=blue)](https://pypi.org/project/dalec-discourse/)\n[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)\n[![Imports: isort](https://img.shields.io/badge/%20imports-isort-%231674b1?style=flat\u0026labelColor=ef8336)](https://pycqa.github.io/isort/)\n[![semver](https://img.shields.io/badge/semver-2.0.0-green)](https://semver.org/)\n[![Documentation Status](https://readthedocs.org/projects/dalec-discourse/badge/?version=latest)](https://dalec-discourse.readthedocs.io/en/latest/?badge=latest)\n\n\nDjango Aggregate a Lot of External Content -- Discourse\n\nAggregate last discourse post from a given discourse instance.\n\nPlugin of [🤖 dalec](https://github.com/webu/dalec).\n\n## Installation\n\nInstall the module:\n\n```\npip install dalec-discourse\n```\n\nIn django settings `INSTALLED_APPS`, add:\n\n```\nINSTALLED_APPS = [\n    ...\n    \"dalec\",\n    \"dalec_prime\",\n    \"dalec_discourse\",\n    ...\n    ]\n```\n\n\n## Usage\n\nGeneral usage:\n```django\n{% load dalec %}\n\n{% dalec \"discourse\" content_type [channel=None] [channel_object=None] [template=None] %}\n```\n\nReal examples:\n\n### Topics\n\nRetrieves latest topics:\n```django\n{% dalec \"discourse\" \"topic\" %}\n```\n\nRetrieves latest topics from a category:\n```django\n{% dalec \"discourse\" \"topic\" channel=\"category\" channel_object=\"15\" %}\n```\n\n### Categories\n\nRetrieves discourse categories:\n```django\n{% dalec \"discourse\" \"category\" %}\n```\n\n### User topics and replies\n\nRetrieves user topics and replies:\n\n```django\n{% dalec \"discourse\" \"user_topic_and_reply\" channel=\"user\" channel_object=\"zorro\" %}\n```\n\n\n## Settings\n\nDjango settings must define:\n\n  - `DALEC_DISCOURSE_BASE_URL` : discourse instance url (ex: `https://discourse.org/`)\n  - `DALEC_DISCOURSE_API_USERNAME` : discourse username (ex: `admin`)\n  - `DALEC_DISCOURSE_API_TOKEN` : discourse api token (ex: `azeazeaezdfqsmlkrjzr`)\n\nIt could also define the login/password attribute, and then this auth method will be used\n(may be usefull for htaccess access for instance):\n\n  - `DISCOURSE_AUTH_USERNAME`\n  - `DISCOURSE_AUTH_PASSWORD`\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwebu%2Fdalec-discourse","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwebu%2Fdalec-discourse","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwebu%2Fdalec-discourse/lists"}