[GH-ISSUE #385] Streaming connection #245

Closed
opened 2026-03-03 16:47:01 +03:00 by kerem · 1 comment
Owner

Originally created by @shanehartman on GitHub (Jun 27, 2017).
Original GitHub issue: https://github.com/OAuthSwift/OAuthSwift/issues/385

Description:

I'm trying to make a request using OAuthSwift that is equivalent to URLSessionTask method uploadTask(withStreamedRequest:) see Apple Docs. I saw https://github.com/OAuthSwift/OAuthSwift/issues/60 discusses OAuthSwiftClient.authorizationHeaderForMethod and this is a possible workaround but this class method on OAuthSwiftClient no longer exists. It must have been deprecated. Any suggestions on how to make a request to initiate a streaming connection using OAuthSwift? Also, I'm interested in possibly contributing to OAuthSwift please tell me how and perhaps I can create an http request to satisfy this use case. The big issue is that there needs to be a delegate method similar to Apple's URLSessionDataTaskDelegate so that as new data is passed via the streaming connection the delegate method ingesting the data gets called.

OAuth Provider (Tw)itter, Github, ..):

Twitter

OAuth Version:

  • [x ] Version 1
  • Version 2

OS (Please fill the version) :

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

Installation method:

  • [ x] Carthage
  • CocoaPods
  • Manually

Library version:

  • head
  • [x ] v1.0.0
  • v0.6
  • other: (Please fill in the version you are using.)

Xcode version:

  • [ x] 8.0 (Swift 3.0)

  • 8.0 (Swift 2.3)

  • 7.3.1

  • other: (Please fill in the version you are using.)

  • objective c

Originally created by @shanehartman on GitHub (Jun 27, 2017). Original GitHub issue: https://github.com/OAuthSwift/OAuthSwift/issues/385 ### Description: I'm trying to make a request using OAuthSwift that is equivalent to URLSessionTask method uploadTask(withStreamedRequest:)[ see Apple Docs](https://developer.apple.com/documentation/foundation/urlsession/1410934-uploadtask). I saw https://github.com/OAuthSwift/OAuthSwift/issues/60 discusses OAuthSwiftClient.authorizationHeaderForMethod and this is a possible workaround but this class method on OAuthSwiftClient no longer exists. It must have been deprecated. Any suggestions on how to make a request to initiate a streaming connection using OAuthSwift? Also, I'm interested in possibly contributing to OAuthSwift please tell me how and perhaps I can create an http request to satisfy this use case. The big issue is that there needs to be a delegate method similar to Apple's URLSessionDataTaskDelegate so that as new data is passed via the streaming connection the delegate method ingesting the data gets called. ### OAuth Provider (Tw)itter, Github, ..): Twitter ### OAuth Version: - [x ] Version 1 - [ ] Version 2 ### OS (Please fill the version) : - [x] iOS : - [ ] OSX : - [ ] TVOS : - [ ] WatchOS : ### Installation method: - [ x] Carthage - [ ] CocoaPods - [ ] Manually ### Library version: - [ ] head - [x ] v1.0.0 - [ ] v0.6 - [ ] other: (Please fill in the version you are using.) ### Xcode version: - [ x] 8.0 (Swift 3.0) - [ ] 8.0 (Swift 2.3) - [ ] 7.3.1 - [ ] other: (Please fill in the version you are using.) - [ ] objective c
kerem closed this issue 2026-03-03 16:47:01 +03:00
Author
Owner

@phimage commented on GitHub (Jun 29, 2017):

you could look at OAuthSwiftAlamofire
https://github.com/OAuthSwift/OAuthSwiftAlamofire/blob/master/Sources/OAuthSwiftRequestAdapter.swift

there is some code to update an URLRequest
The code to sign has moved to OauthSwiftCredential intead of OauthSwiftclient

<!-- gh-comment-id:311991658 --> @phimage commented on GitHub (Jun 29, 2017): you could look at OAuthSwiftAlamofire https://github.com/OAuthSwift/OAuthSwiftAlamofire/blob/master/Sources/OAuthSwiftRequestAdapter.swift there is some code to update an URLRequest The code to sign has moved to OauthSwiftCredential intead of OauthSwiftclient
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#245
No description provided.