We have an Auth SDK at work that exposes a simple function:
public func addAuthentication(to request: Request, completion: (TypedResult<Request, TokenStorageError>) -> Void)
(since we don't want clients to have access to the access tokens directly)
Since this API works asynchronously, we can't add this to preProcessRequest (which is synchronous) or to middleware (since that doesn't have access to the request). Is there a "right" way to do this?
Hi Vadym!
We have an Auth SDK at work that exposes a simple function:
(since we don't want clients to have access to the access tokens directly)
Since this API works asynchronously, we can't add this to preProcessRequest (which is synchronous) or to middleware (since that doesn't have access to the request). Is there a "right" way to do this?