2022-01-10 21:07:57 +00:00
|
|
|
export type User = {
|
2022-01-10 23:52:03 +00:00
|
|
|
id: string
|
2022-01-18 07:18:38 +00:00
|
|
|
createdTime: number
|
|
|
|
|
2022-01-10 23:52:03 +00:00
|
|
|
name: string
|
|
|
|
username: string
|
2022-05-06 18:29:15 +00:00
|
|
|
avatarUrl?: string
|
2022-01-18 07:18:38 +00:00
|
|
|
|
2022-02-18 01:16:58 +00:00
|
|
|
// For their user page
|
|
|
|
bio?: string
|
|
|
|
bannerUrl?: string
|
|
|
|
website?: string
|
|
|
|
twitterHandle?: string
|
|
|
|
discordHandle?: string
|
|
|
|
|
2022-01-10 23:52:03 +00:00
|
|
|
balance: number
|
2022-01-19 03:36:46 +00:00
|
|
|
totalDeposits: number
|
2022-01-17 21:39:26 +00:00
|
|
|
totalPnLCached: number
|
|
|
|
creatorVolumeCached: number
|
2022-05-12 15:07:10 +00:00
|
|
|
|
2022-06-22 16:05:54 +00:00
|
|
|
followerCountCached: number
|
|
|
|
|
2022-05-12 15:07:10 +00:00
|
|
|
followedCategories?: string[]
|
2022-01-10 23:52:03 +00:00
|
|
|
}
|
2022-01-18 07:18:38 +00:00
|
|
|
|
|
|
|
export const STARTING_BALANCE = 1000
|
2022-01-19 03:36:46 +00:00
|
|
|
export const SUS_STARTING_BALANCE = 10 // for sus users, i.e. multiple sign ups for same person
|
|
|
|
|
|
|
|
export type PrivateUser = {
|
|
|
|
id: string // same as User.id
|
|
|
|
username: string // denormalized from User
|
|
|
|
|
|
|
|
email?: string
|
|
|
|
unsubscribedFromResolutionEmails?: boolean
|
2022-02-23 01:35:25 +00:00
|
|
|
unsubscribedFromCommentEmails?: boolean
|
2022-02-23 06:05:04 +00:00
|
|
|
unsubscribedFromAnswerEmails?: boolean
|
2022-05-11 15:51:58 +00:00
|
|
|
unsubscribedFromGenericEmails?: boolean
|
2022-01-19 03:36:46 +00:00
|
|
|
initialDeviceToken?: string
|
|
|
|
initialIpAddress?: string
|
2022-05-16 03:41:07 +00:00
|
|
|
apiKey?: string
|
2022-06-06 17:36:59 +00:00
|
|
|
notificationPreferences?: notification_subscribe_types
|
2022-01-19 03:36:46 +00:00
|
|
|
}
|
2022-06-06 17:36:59 +00:00
|
|
|
|
|
|
|
export type notification_subscribe_types = 'all' | 'less' | 'none'
|