Sessions exist to hold all state associated with your requests.
Right now that's just Auth data, but I think this could also be a great place for cached data to live as well.
The Session
{ authToken : String
, expiration : Basics.Int
}
Data related to an authenticated session
checkSessionExpiration : Time.Posix -> SessionData -> Result SessionFailure SessionData
Check if session is expired
checkError : Http.Error -> Maybe SessionFailure
Check if a request failure was caused by the session
Result of the Creation of a Session