Add apikey support to /jwt

This commit is contained in:
2025-04-23 19:41:42 +02:00
parent 85186a74c8
commit a72ecdb21b
9 changed files with 154 additions and 26 deletions
+17
View File
@@ -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
*