ezidam/crates/database/migrations/20230316213207_authorization_codes.up.sql

12 lines
331 B
SQL

create table if not exists authorization_codes
(
-- info
code TEXT not null primary key,
app TEXT not null references apps (id),
user TEXT not null references users (id),
-- timings
created_at TEXT not null default CURRENT_TIMESTAMP,
expires_at TEXT not null,
used_at TEXT
);