Last active
July 17, 2017 19:13
-
-
Save jeroenr/3caa0ccd56d855894f97eb06647909c0 to your computer and use it in GitHub Desktop.
Sample auth info claim
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sealed trait ClaimModel | |
case class AuthInfo( | |
referenceToken: String, // unique token | |
userId: String, // id of the user entity | |
permissions: List[String], // list of permission ids | |
groupIds: List[String], // list of group ids | |
expirationDate: Option[Long] // expiration date of the user account | |
) extends ClaimModel | |
object ClaimModel extends DefaultJsonProtocol { | |
implicit val authInfoFormat = jsonFormat5(AuthInfo) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment