From 002681b8bc73b2b6d98f49d320b7e26c8c585b80 Mon Sep 17 00:00:00 2001 From: Jesper Handskemager Date: Fri, 16 Sep 2022 15:47:06 +0200 Subject: [PATCH] README --- README.md | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 README.md diff --git a/README.md b/README.md new file mode 100644 index 0000000..16754e6 --- /dev/null +++ b/README.md @@ -0,0 +1,23 @@ +# CS:GO Hub backend +Use with [csgo-hub-discord](https://github.com/jesperbakhandskemager/csgo-hub-discord) + +## Database +You need the following tables + +```{sql} +CREATE TABLE + `tokens` ( + `id` int(10) unsigned NOT NULL AUTO_INCREMENT, + `discord_id` varchar(18) COLLATE utf8mb4_unicode_ci NOT NULL, + `token` varchar(8) COLLATE utf8mb4_unicode_ci NOT NULL, + PRIMARY KEY (`id`) + ) ENGINE = InnoDB AUTO_INCREMENT = 17 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci +CREATE TABLE + `users` ( + `id` int(10) unsigned NOT NULL AUTO_INCREMENT, + `created_at` timestamp NOT NULL DEFAULT current_timestamp(), + `discord_id` varchar(18) COLLATE utf8mb4_unicode_ci NOT NULL, + `friend_code` varchar(10) COLLATE utf8mb4_unicode_ci DEFAULT 'NULL', + PRIMARY KEY (`id`) + ) ENGINE = InnoDB AUTO_INCREMENT = 6 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci +``` \ No newline at end of file