feat(tags) Add minimal tag management to miniflux#4289
Conversation
Extend PUT /v1/entries/{entryID} to accept an optional tags field
that replaces the entry tag list. Preserve existing title/content update
behavior and allow an empty tag list to clear tags.
Update the Go client request type and API examples.
Add a hidden /tags page that lists all tags with entry and unread counts. Reuse the category list item template for categories and tags, and add a tag-specific mark-all-as-read action. Add AI translations for new keys, alert.no_tag and page.tags.title.
|
Making search work with tags via api ( I know about opionated nature of this project, but having tags and not using them in api is strange. |
|
Looks like this PR needs a rebase. It doesn't compile. |
- the tag list page now uses GetNavMetadata - added KR translation (AI-assisted)
|
Rebased! |
|
Not related to this change -- .devcontainer/docker-compose.yml needs version updates |
fguillot
left a comment
There was a problem hiding this comment.
If I'm not mistaken, tags written through the new API endpoint appear to be overwritten during the next feed refresh that updates existing entries. The refresh path unconditionally replaces entries.tags with the tags parsed from the feed.
|
Shoot, you're right, I missed that! I want your take before I implement a fix. Here are three paths I see:
I lean toward 2 or 3. My use case only adds tags, so 3 works fine for me (I'm building a sidecar service called 'sentinel' that will add tags like Which behavior would you prefer? Edit: or a fourth option, add a config value to choose between 2 and 3. |
Have you followed these guidelines?
auto make runto verify that /tags and /categories workThis pull request allows mutating entry
tagsthrough the API (currently only title & content may be mutated) and viewing them from/tags(refactored/categoriesto a shared item_list control).About 2.5 years ago I submitted feature request #2245 for adding upvote/downvote buttons to train AI on news that I care (or do not care) about. I understand that you closed it because it does not fit with the philosophy of miniflux. The idea of this PR is that an external service or reader client or greasmonkey script can interact with miniflux, saving metadata as tags. This keeps miniflux as a central feed repository, and any AI/LLM client has a way to interact with the storage model. No changes to the database, so no migrations required. No bloat of miniflux features.
Code Summary
This PR adds tag management support in two places:
PUT /v1/entries/{entryID}so API clients can replace an entry’s tags with an optionaltagsfield./tagsUI page that lists all tags, reusing the category list layout and supporting tag-specific “mark all as read” actions.Details
The API update keeps existing title/content behavior intact while allowing:
tags: leave tags unchanged"tags": []: clear tags"tags": ["foo", "bar"]: replace tagsThe UI update adds a read-only tag listing page at
/tags, with entry counts, unread counts, links to each tag’s entries, and localized labels. It does not add a top-level navigation item.