https://kotlinlang.org logo
#http4k
Title
# http4k
p

pabl0rg

07/01/2020, 4:31 PM
Hi, does anyone know of an example app using http4k and oauth2 where the app uses the user's oauth token not only to identify/authorize the user but also to make requests to remote web services?
d

dave

07/01/2020, 4:33 PM
no, but it should be quite easy to compose that from the parts we have. What are you having trouble with?
p

pabl0rg

07/01/2020, 5:08 PM
I just found the
api
property in
OAuthProvider
. If I use that, will the token get added to requests?
d

dave

07/01/2020, 5:21 PM
if you want access to the bearer token, isn't it available on all incoming requests?
p

pabl0rg

07/01/2020, 11:25 PM
Thanks! I get it now. The token gets added to the request by
OAuthPersistence
. It would be great to have an expert example but I'm sure I can hack something together. 👍
3 Views