mirror of
https://github.com/zoriya/Kyoo.git
synced 2026-08-15 18:45:24 +00:00
Add apikey support to /jwt
This commit is contained in:
@@ -1,3 +1,20 @@
|
||||
-- name: GetApiKey :one
|
||||
select
|
||||
*
|
||||
from
|
||||
apikeys
|
||||
where
|
||||
name = $1
|
||||
and token = $2;
|
||||
|
||||
-- name: TouchApiKey :exec
|
||||
update
|
||||
apikeys
|
||||
set
|
||||
last_used = now()::timestamptz
|
||||
where
|
||||
pk = $1;
|
||||
|
||||
-- name: ListApiKeys :many
|
||||
select
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user