[GH-ISSUE #680] OAuth1.0 in SwiftUI #440

Closed
opened 2026-03-03 16:48:42 +03:00 by kerem · 1 comment
Owner

Originally created by @ZhannySunny on GitHub (Oct 27, 2021).
Original GitHub issue: https://github.com/OAuthSwift/OAuthSwift/issues/680

Hi. I need to implement OAuth1 without authorization to get some data from localhost. Could you please say can I do OAuth1.0 like in your example but in SwiftUI.

// create an instance and retain it
oauthswift = OAuth1Swift(
consumerKey: "",
consumerSecret: "
"
)
// do your HTTP request without authorize
oauthswift.client.get("https://api.example.com/foo/bar") { result in
switch result {
case .success(let response):
//....
case .failure(let error):
//...
}
}

I didn't understand where I should handle URL. In SwiftUI there's no UISceneDelegate.

Originally created by @ZhannySunny on GitHub (Oct 27, 2021). Original GitHub issue: https://github.com/OAuthSwift/OAuthSwift/issues/680 Hi. I need to implement OAuth1 without authorization to get some data from localhost. Could you please say can I do OAuth1.0 like in your example but in SwiftUI. // create an instance and retain it oauthswift = OAuth1Swift( consumerKey: "********", consumerSecret: "********" ) // do your HTTP request without authorize oauthswift.client.get("https://api.example.com/foo/bar") { result in switch result { case .success(let response): //.... case .failure(let error): //... } } I didn't understand where I should handle URL. In SwiftUI there's no UISceneDelegate.
kerem closed this issue 2026-03-03 16:48:42 +03:00
Author
Owner

@mesopelagique commented on GitHub (Oct 28, 2021):

do you know search feature https://github.com/OAuthSwift/OAuthSwift/search?q=SwiftUI&type=issues

<!-- gh-comment-id:953800809 --> @mesopelagique commented on GitHub (Oct 28, 2021): do you know search feature https://github.com/OAuthSwift/OAuthSwift/search?q=SwiftUI&type=issues
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#440
No description provided.