Files
inventory-plus-plus/database_migrations/000009_etsy_oauth_requests.up.sql

12 lines
290 B
SQL

CREATE TABLE etsy_oauth_requests (
account_id INTEGER NOT NULL,
state BYTEA NOT NULL,
code_verifier BYTEA NOT NULL,
expiration TIMESTAMPTZ NOT NULL,
PRIMARY KEY (state),
FOREIGN KEY (account_id) REFERENCES accounts
);
CREATE UNIQUE INDEX ON etsy_oauth_requests (state);