Support both web and Android sessions

This commit is contained in:
Zed
2025-02-25 05:46:18 +00:00
parent 4f9ba9c7d6
commit 661be438ec
4 changed files with 47 additions and 18 deletions

View File

@@ -31,10 +31,20 @@ type
remaining*: int
reset*: int
SessionKind* = enum
oauth
cookie
Session* = ref object
case kind*: SessionKind
of oauth:
oauthToken*: string
oauthSecret*: string
of cookie:
ct0*: string
authToken*: string
id*: int64
oauthToken*: string
oauthSecret*: string
pending*: int
limited*: bool
limitedAt*: int