simplify token issuer/verifier interface

This commit is contained in:
David Zhao
2020-12-27 20:53:07 -08:00
parent 353f35443a
commit 46dadc25c2
13 changed files with 245 additions and 338 deletions
+6 -2
View File
@@ -1,7 +1,11 @@
package auth
type GrantClaims struct {
type VideoGrant struct {
RoomCreate bool `json:"room_create,omitempty"`
RoomJoin bool `json:"room_join,omitempty"`
Room string `json:"room"`
Room string `json:"room,omitempty"`
}
type ClaimGrants struct {
Video *VideoGrant `json:"video,omitempty"`
}