integration-0.1.0
Safe HaskellNone
LanguageGHC2021

Test.OAuth

Synopsis

Documentation

testOAuthScopeTiersAreSeparate :: HasCallStack => App () Source #

The tiers of a scope are separate: a token that may write may not read, and the other way round. This is about conversations:cnv/code, the one location in the integration nginx.conf that uses oauth_scopes.

accessTokenFor :: (HasCallStack, MakesValue user, MakesValue cid) => user -> cid -> [String] -> App String Source #

The access token, which is the part nginz gets to see.

refreshTokenId :: (HasCallStack, MakesValue user) => user -> App UUID Source #

The id of the one session the user has.

accessTokenClaims :: HasCallStack => String -> App Value Source #

The claims of an access token, read without verifying anything: we only want to see what brig put in.

generateAccessToken :: (MakesValue cid, MakesValue user) => user -> cid -> [String] -> String -> App Value Source #