Skip to content

Releases: treeben77/discord-oauth2.py

v1.2.1

27 May 09:00
ebf21d6
Compare
Choose a tag to compare

Updated Client.generate_uri

  • Fixed types for some parameters
  • Added skip_prompt parameter, which sets prompt=none when True.

v1.2.0 - URI Generator

23 May 13:20
8db2d3d
Compare
Choose a tag to compare

Added URI Generator

  • Added Client.uri_generator which generates an OAuth2 uri from provided inputs request in #6 - View documentation

v1.1.0 - Linked Roles & Token Revocation

05 Feb 16:48
a783d63
Compare
Choose a tag to compare

Changelog

Added Linked Roles Support

  • Added Client.update_linked_roles_metadata(metadata) which takes a list of application role connection metadata
  • Added PartialAccessToken.update_metadata(platform_name=None, username=None, **metadata) platform name and username are strings, and metadata is a keyword args mapping metadata keys to values, accepting the types: bool, int, datetime or a str (only for iso time).

Added Token Revocation Support

  • Added PartialAccessToken.revoke() shorthand to revoke an access token.
  • Added AccessToken.revoke_refresh_token() shorthand to revoke a refresh token.
  • Added Client.revoke_token(token, token_type=None) to revoke any oauth2 token related to the client.

v1.0.1

17 Dec 13:06
cea3ff9
Compare
Choose a tag to compare

Fixed a bug that broke PartialAccessToken.join_guild. It now requires a user_id parameter along with a guild_id parameter.

v1.0.0

03 Dec 17:01
ac9418f
Compare
Choose a tag to compare

I rewrote the library and uploaded it a pypi!!!

added a new function for client_credentails_grant which will generate an AccessToken for the owners account and much more. I'll update the README.md in a moment.

This should automatically trigger a workflow to publish the library onto pypi if im not mistaken.

happy coding!

v0.4-beta

14 Apr 11:13
ed25303
Compare
Choose a tag to compare
v0.4-beta Pre-release
Pre-release
  • Added webhook property to access_token, will be a webhook object if the webhook scope is provided otherwise it will be None.
  • Added guild property to access_token, will be a guild object that the bot joined if the bot scope was provided otherwise it will be None
  • Exception is raised if an HTTP error occurs in discordoauth2.exchange_code or discordoauth2.refresh_token

No code should break this release, but it may next release.

v0.3-beta

28 Jan 06:23
c1ecfbe
Compare
Choose a tag to compare
  • Added guilds.members.read support
  • Added refresh_token(), the ability to refresh an access token.
  • Removed gdm.join as it is no longer supported by discord
  • exchange_code() now returns a access_token object. (this will break all code using an older version)

Access tokens have three properties:

  • access: token_instance object (exchange_code() used to return a token_instance object)
  • expires: how many seconds until access will expire.
  • refresh_token: this can be used with refresh_token() once access has expired

v0.2-alpha.1

04 Jul 05:39
209fba5
Compare
Choose a tag to compare

Changed core structure to use classes instead. Code much cleaner.

v0.1-alpha.2

04 Jul 05:24
fa1d4b0
Compare
Choose a tag to compare
v0.1-alpha.2 Pre-release
Pre-release

First build, this was created a month ago but publishing today. It works but the code is clunky.