AppAuth iOS 實作 3-實作解析OAuth2.0串接第三方取得帳號資訊

(AppAuth iOS, openid, OAuth)

AppAuth 原理&執行專案 請參考

實作解析OAuth2.0串接第三方登入 請參考



取資訊之前,authState?.performAction() 會先執行performActionWithFreshTokens,token檢查有效性並且自動更換token

取得的Token跟authState?.lastTokenResponse?.accessToken 比對


authState.lastAuthorizationResponse.request.configuration.discoveryDocument也可以取得一些資訊,例如:authorizationEndpoint, tokenEndpoint等






Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Peggy Tsai 

Peggy Tsai 

iOS & Golang 隨手記 歡迎+Linkedin交流~

More from Medium

IOS Unit Testing in Swift

5 Epiphanies from My First [Digital] WWDC

Method dispatch in Swift protocols

Lets coding with together MVVM + RxSwift ( Approach of function in view model )