git-point
git-point copied to clipboard
Add the subscribe/unsubscribe issue button
Can you add the option the show notification of the issue?
Hi @mittalyashu, can you explain a bit more? Do you mean the red message dot on app icon?
Sure.
For example, we have created a new issue or subscribed to the issue which is already created.
Basically github sends us an email for each new cooments of the issue (the issues you have subscribed). Isn't it would be great, if we could get the notifications on the mobile application itself.
Possibly a duplicate of #101? Correct me if I'm wrong and I'll reopen!
@andrewda I think it is not. This issue just wants to add the subscribe/unsubscribe button. I reopen with the issue title updated.
No @chinesedfan , you got me wrong. I am not talking about notifications of the repo we are watching. I am talking about the notifications of the issues, we create on GitHub.
Can you join this chat, so that we can discuss it properly?
@mittalyashu Can we chat on Gitter? Sorry, in China, it is hard to visit flock.com due to network issues.
Oh! I see.
I would like to take this issue 😄
Great!
Just to avoid confusion giving the prior conversation, the idea is to give the ability to the end-user to subscribe/unsubscribe from an issue thread.
I was wandering around github v3 api docs but couldn't find where to get subscription status and then update the status... 😢
As far as I understand, here are the involved endpoints:
- Check subscription status: https://developer.github.com/v3/activity/notifications/#get-a-thread-subscription
- Change subscription status: https://developer.github.com/v3/activity/notifications/#set-a-thread-subscription
- The thread ID would be the
id
property returned in the Issue object (for example, this very issue thread id is 266856405)
This is what I tried using those API. The response is kinda weird.
Btw this is the link to that Issue: https://github.com/facebook/react-native/issues/17935
Are you authenticated?
Yes, here are my headers I even changed the thread id to this particular issue but the response is still the same
The thread ID would be the id property returned in the Issue object
@machour I am afraid that the thread id is different with the issue id. Because I got the same response with you. The Github document says,
Notifications come back as "threads". A Thread contains information about the current discussion of an Issue/PullRequest/Commit.
So for example, even for the same issue, different threads will be generated for different users. That's why Github always complains about no admin rights.
I found a usable thread id, 268248680, in my notifications. But it should not work for you guys. 😄
Edited: Or maybe we are in the same thread.
Interesting.. so how would someone get a working thread id? 🤔