[GH-ISSUE #685] The operation couldn’t be completed. (OAuthSwiftError error -10.) #442

Closed
opened 2026-03-03 16:48:43 +03:00 by kerem · 0 comments
Owner

Originally created by @underthestars-zhy on GitHub (Nov 25, 2021).
Original GitHub issue: https://github.com/OAuthSwift/OAuthSwift/issues/685

Description:

OAuth Provider? (Twitter, Github, ..):

OneDrive

OAuth Version:

  • Version 1
  • Version 2

OS (Please fill the version) :

  • iOS :
  • OSX :
  • TVOS :
  • WatchOS :

Installation method:

  • Carthage
  • CocoaPods
  • Swift Package Manager
  • Manually

Library version:

  • head
  • v2.1.0
  • v2.0.0
  • v1.4.1
  • other: (Please fill in the version you are using.)

Xcode version:

  • 11.4 (Swift 5.2)

  • 11.x (Swift 5.1)

  • 10.x (Swift 5.0)

  • 13.x (Swift 5.5)

  • objective c

let oauth = OAuth2Swift(consumerKey: appId, consumerSecret: appSecret, authorizeUrl: authorizeUrl, accessTokenUrl: accessTokenUrl, responseType: responseType, contentType: nil)
        oauth.allowMissingStateCheck = true
        oauth.renewAccessToken(withRefreshToken: refreshToken, parameters: tokenParameters) { result in
            switch result {
            case .success(let token):
                completion(.success(token))
            case .failure(let error):
                completion(.failure(error))
            }
        }
        self.oauth = oauth

The i got this error: The operation couldn’t be completed. (OAuthSwiftError error -10.)
appId: "xxxxxxxxxxxxxxxx"
appSecret: ""
accessTokenUrl: "https://login.microsoftonline.com/common/oauth2/v2.0/authoriz"
responseType: code

Originally created by @underthestars-zhy on GitHub (Nov 25, 2021). Original GitHub issue: https://github.com/OAuthSwift/OAuthSwift/issues/685 ### Description: ### OAuth Provider? (Twitter, Github, ..): OneDrive ### OAuth Version: - [ ] Version 1 - [X] Version 2 ### OS (Please fill the version) : - [x] iOS : - [ ] OSX : - [ ] TVOS : - [ ] WatchOS : ### Installation method: - [ ] Carthage - [X] CocoaPods - [ ] Swift Package Manager - [ ] Manually ### Library version: - [X] head - [ ] v2.1.0 - [ ] v2.0.0 - [ ] v1.4.1 - [ ] other: (Please fill in the version you are using.) ### Xcode version: - [ ] 11.4 (Swift 5.2) - [ ] 11.x (Swift 5.1) - [ ] 10.x (Swift 5.0) - [X] 13.x (Swift 5.5) - [ ] objective c ```swift let oauth = OAuth2Swift(consumerKey: appId, consumerSecret: appSecret, authorizeUrl: authorizeUrl, accessTokenUrl: accessTokenUrl, responseType: responseType, contentType: nil) oauth.allowMissingStateCheck = true oauth.renewAccessToken(withRefreshToken: refreshToken, parameters: tokenParameters) { result in switch result { case .success(let token): completion(.success(token)) case .failure(let error): completion(.failure(error)) } } self.oauth = oauth ``` The i got this error: `The operation couldn’t be completed. (OAuthSwiftError error -10.)` `appId`: `"xxxxxxxxxxxxxxxx"` `appSecret`: `""` `accessTokenUrl`: `"https://login.microsoftonline.com/common/oauth2/v2.0/authoriz"` `responseType`: `code`
kerem closed this issue 2026-03-03 16:48:43 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/OAuthSwift#442
No description provided.