nidus-sync/migrations/00006_add_oauth_refresh_expires.sql
Eli Ribble 109495b702
Track access token and refresh token expiry
Also make a bunch more progress on actually updating the tokens when we
need them updated.
2025-11-07 05:46:41 +00:00

7 lines
333 B
SQL

-- +goose Up
ALTER TABLE oauth_token RENAME COLUMN expires TO access_token_expires;
ALTER TABLE oauth_token ADD COLUMN refresh_token_expires TIMESTAMP NOT NULL DEFAULT current_timestamp;
-- +goose Down
ALTER TABLE oauth_token DROP COLUMN refresh_token_expires;
ALTER TABLE oauth_token RENAME COLUMN access_token_expires TO expires;