mirror of
https://github.com/ramsayleung/rspotify.git
synced 2026-04-26 07:55:55 +03:00
[PR #418] [MERGED] Add token fetch callback #442
Labels
No labels
Stale
bug
discussion
enhancement
good first issue
good first issue
help wanted
pull-request
question
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/rspotify#442
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/ramsayleung/rspotify/pull/418
Author: @ramsayleung
Created: 5/27/2023
Status: ✅ Merged
Merged: 6/18/2023
Merged by: @ramsayleung
Base:
master← Head:ramsay/add_token_callback_support📝 Commits (10+)
6de9fb3Add token fetch callback support9eb5336Add token callback function support for AuthCodeSpotifya2347deAdd token callback function for AuthCodePkceSpotify9babacbAdd token callback support for ClientCredSpotify50dc9bfAdd example to test13b4b13Update CHANGELOG365b74dcargo fmt coded0ba817fix clippy error8c71294Update gitignoref8ffc61Change the function signature of callback function📊 Changes
9 files changed (+158 additions, -3 deletions)
View changed files
📝
.gitignore(+1 -1)📝
CHANGELOG.md(+1 -0)📝
Cargo.toml(+5 -0)📝
clippy.toml(+1 -1)➕
examples/with_token_callback_fn.rs(+100 -0)📝
src/auth_code.rs(+10 -0)📝
src/auth_code_pkce.rs(+10 -0)📝
src/client_creds.rs(+5 -0)📝
src/lib.rs(+25 -1)📄 Description
Description
Add a user-customized callback function support which is invoked whenever client succeeds to request or refresh a token, so it provides users an opportunity to save token into file, store into database etc.
Motivation and Context
#400
Dependencies
None
Type of change
Please delete options that are not relevant.
How has this been tested?
with_token_callback_fn.rsIs this change properly documented?
Please make sure you've properly documented the changes you're making.
Don't forget to add an entry to the CHANGELOG if necessary (new features, breaking changes, relevant internal improvements).
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.