Refreshable connections, refactoring, access-token endpoint
- Aded /users/@me/connections/:connection_name/:connection_id/access-token - Replaced `access_token` property on ConnectedAccount with `token_data` object for refreshing tokens - Made a common interface for connection things like ComonOAuthTokenResponse - Added `RefreshableConnection` class - Added token refresh to Spotify connection (disabled)
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
export interface ConnectedAccountCommonOAuthTokenResponse {
|
||||
access_token: string;
|
||||
token_type: string;
|
||||
scope: string;
|
||||
refresh_token?: string;
|
||||
expires_in?: number;
|
||||
}
|
||||
|
||||
export interface ConnectedAccountTokenData {
|
||||
access_token: string;
|
||||
token_type?: string;
|
||||
scope?: string;
|
||||
refresh_token?: string;
|
||||
expires_in?: number;
|
||||
expires_at?: number;
|
||||
}
|
||||
@@ -17,7 +17,8 @@
|
||||
*/
|
||||
|
||||
export * from "./Activity";
|
||||
export * from "./Presence";
|
||||
export * from "./Interaction";
|
||||
export * from "./ConnectedAccount";
|
||||
export * from "./Event";
|
||||
export * from "./Interaction";
|
||||
export * from "./Presence";
|
||||
export * from "./Status";
|
||||
|
||||
Reference in New Issue
Block a user