Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(OAuth2API): add revokeToken method #10440

Merged
merged 8 commits into from
Aug 20, 2024
Merged

Conversation

Larsundso
Copy link
Contributor

@Larsundso Larsundso commented Aug 9, 2024

Please describe the changes this PR makes and why it should be merged:
This change completes the OAuth2 Authorization flow by supporting the Token Revocation URL

Fixes #10439

This PR relies on:

Status and versioning classification:

  • Code changes have been tested against the Discord API, or there are no code changes
  • I know how to update typings and have done so, or typings don't need updating
  • This PR changes the library's interface (methods or parameters added)

@Larsundso Larsundso requested a review from a team as a code owner August 9, 2024 11:30
Copy link

vercel bot commented Aug 9, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

2 Skipped Deployments
Name Status Preview Comments Updated (UTC)
discord-js ⬜️ Ignored (Inspect) Visit Preview Aug 20, 2024 8:57am
discord-js-guide ⬜️ Ignored (Inspect) Visit Preview Aug 20, 2024 8:57am

Copy link
Member

@almeidx almeidx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The linter is going to fail here. You should run pnpm fmt

packages/core/src/api/oauth2.ts Outdated Show resolved Hide resolved
packages/core/src/api/oauth2.ts Outdated Show resolved Hide resolved
packages/core/src/api/oauth2.ts Outdated Show resolved Hide resolved
@almeidx almeidx changed the title feat(OAuth2API): add 'revokeToken' method feat(OAuth2API): add revokeToken method Aug 17, 2024
@almeidx almeidx added this to the core 1.3.0 milestone Aug 17, 2024
Larsundso and others added 5 commits August 17, 2024 22:24
Co-authored-by: Almeida <github@almeidx.dev>
Co-authored-by: Almeida <github@almeidx.dev>
Co-authored-by: Almeida <github@almeidx.dev>
Copy link
Member

@kyranet kyranet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One little nitpick

packages/core/src/api/oauth2.ts Show resolved Hide resolved
@kodiakhq kodiakhq bot merged commit 69adc6f into discordjs:main Aug 20, 2024
6 checks passed
nyapat pushed a commit to nyapat/discord.js that referenced this pull request Sep 9, 2024
* feat(OAuth2API): add 'revokeToken' method

* Buffer => btoa

Co-authored-by: Almeida <github@almeidx.dev>

* Response is empty, dont return

Co-authored-by: Almeida <github@almeidx.dev>

* Redundant override

Co-authored-by: Almeida <github@almeidx.dev>

* chore: fmt

---------

Co-authored-by: Almeida <github@almeidx.dev>
Co-authored-by: Almeida <almeidx@pm.me>
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

OAuth2 method for token revoke endpoint
5 participants