forked from Mirrors/oauth2
docs: ImpersonateTokenSource description
The refactor made ImpersonateTokenSource public. Short explanation of each fields. Updates #515
This commit is contained in:
parent
121de73b38
commit
2fca3adf8d
|
@ -29,11 +29,17 @@ type impersonateTokenResponse struct {
|
||||||
ExpireTime string `json:"expireTime"`
|
ExpireTime string `json:"expireTime"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// ImpersonateTokenSource uses a source credential, stored in Ts, to request an access token to the provided Url
|
||||||
|
// Scopes can be defined when the access token is requested.
|
||||||
type ImpersonateTokenSource struct {
|
type ImpersonateTokenSource struct {
|
||||||
|
// execution context
|
||||||
Ctx context.Context
|
Ctx context.Context
|
||||||
Ts oauth2.TokenSource
|
// source credential
|
||||||
|
Ts oauth2.TokenSource
|
||||||
|
|
||||||
Url string
|
// impersonation url to request an access token
|
||||||
|
Url string
|
||||||
|
// scopes to include in the access token request
|
||||||
Scopes []string
|
Scopes []string
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue