stencila/executa

refactor(Claims): Rename and reshape User to Claims

Closed this issue · 0 comments

Currently we have a interface User,

export interface User {
id?: string
client?: {
type: Transport
id: string
}
session?: SoftwareSession
}

which carries verified information about the user and their rights. After a brief discussion we thought that it would be more accurate to rename this Claims (the JWT parlance for such pieces on info) and refactor to have userId instead of id, and allow for other arbitrary claims e.g. projectId and iat by having [key: string]: unknown at end of the interface definition.