Unable to mark notifications as read via API calls #2977
Loading…
x
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Description
I'm currently trying to write a small program to send notifications to Gotify. While getting the notifications seems to work just fine, marking them as read is giving me some troubles.
I've tried it with both curl and a Golang program.
It doesn't really matter what permissions the API token has, even with all permissions, it doesn't seem to work.
Example to mark a specific notification as read:
So this just acts as a
GET
it seems.When trying to mark all notifications as read:
Vikunja Version
0.24.6
Browser and version
No response
Can you reproduce the bug on the Vikunja demo site?
Yes
Screenshots
No response
This sounds like a bug. I'll take a look.
Does this happen only with a fixed api token? (As opposed to a login token)
I'm not sure what you mean with a
login token
.I'm loging in via OIDC (Authelia) so I'm not sure if I can create such token?
When you're using the Frontend, Vikunja will request a login token after you signed in. That's regardless of the Auth method used.
I see!
I found the token and retried to mark a notification as read via the API, which succeeded this time. So this bug only applies to the API token.
Does it work when you add the
Notifications
permission from theOther
category to a created api token?Unfortunately it does not.
I have a token with all checkboxes ticked that does not work:
Now fixed in
45ec1a4c47
. Please check with the next unstable build or ony the demo (ready in ~45min).It seems that something is not working yet.
On the demo site, I now can't list the notifications anymore either:
This is a token with all permissions for the
demo:demo
user:Using a login token still works.
I've now moved the "mark all as read" permission to the notifications group in
abae6f05e0
- that should fix the problem. Please check again with the next unstable build or on try. You'll need to regnerate the token.This works, thanks!