-
-
Notifications
You must be signed in to change notification settings - Fork 5
feat(Threads): API v9, add rest support for Threads #31
base: beta
Are you sure you want to change the base?
Conversation
|
There have been a couple of changes since that PR as well, did you go through relevant doc commits after that as well? |
I took into consideration the link I put in the PR description and the discord documentation which should be updated |
bsian03
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We're not using src folder. Also endpoint descriptions should just be how they are named on Discord
| public static THREAD(channelID: string) { | ||
| return `/channels/${channelID}/thread-members/@me`; | ||
| } | ||
| /** | ||
| * `/channels/{channel.id}/thread-members/{user.id}` | ||
| * - PUT - Adds another member to a thread | ||
| * - DELETE - Removes another member from a thread | ||
| */ | ||
| public static THREAD_MEMBER(channelID: string, userID: string) { | ||
| return `/channels/${channelID}/thread-members/${userID}`; | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm tempted to say combine these, cc @Khaaz?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure, what did we do for other similar endpoints?
I'm not against specific /@me endpoint, although I do agree it's legitimate to combine.
| public static THREAD(channelID: string) { | ||
| return `/channels/${channelID}/thread-members/@me`; | ||
| } | ||
| /** | ||
| * `/channels/{channel.id}/thread-members/{user.id}` | ||
| * - PUT - Adds another member to a thread | ||
| * - DELETE - Removes another member from a thread | ||
| */ | ||
| public static THREAD_MEMBER(channelID: string, userID: string) { | ||
| return `/channels/${channelID}/thread-members/${userID}`; | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure, what did we do for other similar endpoints?
I'm not against specific /@me endpoint, although I do agree it's legitimate to combine.
Khaaz
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
other than that seems good so far?
bsian03
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Again, endpoint descriptions should be the endpoint name on Discord, i.e. POST START_THREAD_WITH_MESSAGE be Start Thread with Message
|
Apart from the naming and Bsian point, this PR seems globally ready I think. Do we have anything else to change for API v9? |
bsian03
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you revert all the src/ changes
This PR
ws\constants.ts.structures\Guild.tsandsrc\util\Constants.ts.src\Client.tsandrest\Endpoints.ts.rest\RESTClient.tsNotes:
src\util\Constants.tsis outdated and needs to be updated in another PR.