Files
Apoorv Dixit 2005d3df9f feat(users): setup user authentication methods schema and apis (#4999)
Co-authored-by: hyperswitch-bot[bot] <148525504+hyperswitch-bot[bot]@users.noreply.github.com>
Co-authored-by: Mani Chandra Dulam <mani.dchandra@juspay.in>
2024-06-21 10:59:17 +00:00

17 lines
614 B
SQL

-- Your SQL goes here
CREATE TABLE IF NOT EXISTS user_authentication_methods (
id VARCHAR(64) PRIMARY KEY,
auth_id VARCHAR(64) NOT NULL,
owner_id VARCHAR(64) NOT NULL,
owner_type VARCHAR(64) NOT NULL,
auth_type VARCHAR(64) NOT NULL,
private_config bytea,
public_config JSONB,
allow_signup BOOLEAN NOT NULL,
created_at TIMESTAMP NOT NULL DEFAULT now(),
last_modified_at TIMESTAMP NOT NULL DEFAULT now()
);
CREATE INDEX IF NOT EXISTS auth_id_index ON user_authentication_methods (auth_id);
CREATE INDEX IF NOT EXISTS owner_id_index ON user_authentication_methods (owner_id);