API for archiving a notification (marking as done) #50224
Replies: 5 comments 3 replies
-
This would be particularly nice as the current UI does not have great UX for tasks like "archive all notifications for closed PRs" |
Beta Was this translation helpful? Give feedback.
-
Maybe this is implied, but it'd also be helpful to filter on this status when retrieving notifications. The UI currently defaults to "not done" notifications, distinctly separate from "unread". |
Beta Was this translation helpful? Give feedback.
-
@aspiers I took a look at their beta endpoint but I believe it requires a different kind of authentication token than is provided by the official api so we can't use the unofficial one as a hack, will need to wait for it to be implemented. @joshbeard yes if we can retrieve the "done" state from the api we can provide filters and searches on that field. If you'd like to see this feature I recommend contacting github customer support and requesting the api be made public, the more people that ask, the most likely it will happen. |
Beta Was this translation helpful? Give feedback.
-
This API has been introduced: https://docs.github.com/en/rest/activity/notifications?apiVersion=2022-11-28#mark-a-thread-as-done However, there still doesn't seem to be an API parameter to filter notifications using |
Beta Was this translation helpful? Give feedback.
-
Create a saved search with "type:pull_request state:merged,closed" for quick archiving. Alternatively, use "state:merged,closed inbox:true starred:false" as a search termed "Archivable" for efficient management of pull requests. |
Beta Was this translation helpful? Give feedback.
-
Select Topic Area
Product Feedback
Body
The GitHub website and mobile app are both able to mark individual notifications as done; however there does not appear to be any API mechanism documented which allows this, either in the REST API or the GraphQL API.
The REST API only allows marking notifications as read, not as done:
https://docs.github.com/en/rest/activity/notifications?apiVersion=2022-11-28#mark-notifications-as-read
and I can't find anything about notifications in the GraphQL API at all (maybe they're there, but just not easily discoverable).
However, sniffing the network traffic when archiving a notification from https://github.com/notifications reveals a beta API:
It would be great if this was brought out of beta and fully documented!
Beta Was this translation helpful? Give feedback.
All reactions