Add a model for external apps

Stores their name, website, and credentials
This commit is contained in:
Baptiste Gelez
2018-10-21 14:19:07 +01:00
parent 76ca76f068
commit 4c8a727e9e
7 changed files with 56 additions and 0 deletions
+2
View File
@@ -0,0 +1,2 @@
-- This file should undo anything in `up.sql`
DROP TABLE apps;
+10
View File
@@ -0,0 +1,10 @@
-- Your SQL goes here
CREATE TABLE apps (
id INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT,
name TEXT NOT NULL DEFAULT '',
client_id TEXT NOT NULL,
client_secret TEXT NOT NULL,
redirect_uri TEXT,
website TEXT,
creation_date DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP
);