oauth2
Generated by tinox doc
tinox.core.oauth2, split out of the bundled stdlib as a standalone tinox-central package.
| Module | Version | Group |
|---|---|---|
crypto (no local docs) | 1.1.4 | tinox.core |
http (no local docs) | 1.3.3 | tinox.core |
json (no local docs) | 1.1.5 | tinox.core |
class OAuth2AuthorizeRequest
Fields
url | String | |
state | String | |
codeVerifier | String |
class OAuth2Client
Fields
authorizeUrl | String | |
tokenUrl | String | |
clientId | String | |
clientSecret | String | |
redirectUri | String |
Methods
fn new(authorizeUrl: String, tokenUrl: String, clientId: String, clientSecret: String, redirectUri: String) → OAuth2Client
fn buildAuthorizeUrl(scope: String) → OAuth2AuthorizeRequest
fn exchangeCode(code: String, codeVerifier: String) → OAuth2TokenResponse
fn refresh(refreshToken: String) → OAuth2TokenResponse
fn postToken(url: String, body: String) → OAuth2TokenResponse
class OAuth2TokenResponse
Fields
accessToken | String | |
refreshToken | String | |
tokenType | String | |
expiresIn | Int64 | |
idToken | String | |
ok | Bool | |
errorMessage | String |