twitch-bot-streak/struct.go

26 lines
693 B
Go
Raw Permalink Normal View History

2024-03-24 01:57:46 +00:00
package main
type (
botResponse struct {
Type string `json:"type"`
Attributes map[string]any `json:"attributes"`
}
streakUser struct {
TwitchID uint64 `db:"twitch_id"`
Username string `db:"username"`
StreamsCount uint64 `db:"streams_count"`
CurrentStreak uint64 `db:"current_streak"`
MaxStreak uint64 `db:"max_streak"`
StreakStatus status `db:"streak_status"`
}
status string
)
const (
statusBroken status = "broken" // Streak is broken and must be started anew
statusPending status = "pending" // Streak is pending to be broken and can be continued
statusActive status = "active" // Streak is active (renewed in current stream)
)