-- MySQL dump 10.19 Distrib 10.3.29-MariaDB, for debian-linux-gnu (x86_64) -- -- Host: localhost Database: coinos -- ------------------------------------------------------ -- Server version 10.3.29-MariaDB-1:10.3.29+maria~bionic /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; /*!40101 SET NAMES utf8mb4 */; /*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */; /*!40103 SET TIME_ZONE='+00:00' */; /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */; /*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */; /*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */; /*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */; -- -- Table structure for table `SequelizeMeta` -- DROP DATABASE IF EXISTS coinos; CREATE DATABASE coinos; USE coinos; DROP TABLE IF EXISTS `SequelizeMeta`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `SequelizeMeta` ( `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL, PRIMARY KEY (`name`), UNIQUE KEY `name` (`name`), UNIQUE KEY `SequelizeMeta_name_unique` (`name`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Table structure for table `accounts` -- DROP TABLE IF EXISTS `accounts`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `accounts` ( `id` int(11) NOT NULL AUTO_INCREMENT, `user_id` int(11) DEFAULT NULL, `asset` varchar(255) DEFAULT NULL, `createdAt` datetime NOT NULL, `updatedAt` datetime NOT NULL, `balance` double DEFAULT NULL, `pending` double DEFAULT NULL, `name` varchar(255) DEFAULT NULL, `ticker` varchar(255) DEFAULT NULL, `precision` int(11) DEFAULT NULL, `domain` varchar(255) DEFAULT NULL, `contract` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL, `pubkey` varchar(255) DEFAULT NULL, `index` int(11) NOT NULL DEFAULT 0, `hide` tinyint(1) DEFAULT NULL, `seed` varchar(255) DEFAULT NULL, `path` varchar(255) DEFAULT NULL, `network` varchar(255) DEFAULT NULL, `privkey` varchar(255) DEFAULT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=4188 DEFAULT CHARSET=latin1; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Table structure for table `codes` -- DROP TABLE IF EXISTS `codes`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `codes` ( `code` varchar(255) NOT NULL, `text` text DEFAULT NULL, PRIMARY KEY (`code`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Table structure for table `deposits` -- DROP TABLE IF EXISTS `deposits`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `deposits` ( `id` int(11) NOT NULL AUTO_INCREMENT, `user_id` int(11) DEFAULT NULL, `createdAt` datetime NOT NULL, `updatedAt` datetime NOT NULL, `amount` double DEFAULT NULL, `credited` tinyint(1) DEFAULT NULL, `code` varchar(255) DEFAULT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=4122 DEFAULT CHARSET=latin1; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Table structure for table `invoices` -- DROP TABLE IF EXISTS `invoices`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `invoices` ( `id` int(11) NOT NULL AUTO_INCREMENT, `user_id` int(11) DEFAULT NULL, `text` text DEFAULT NULL, `createdAt` datetime NOT NULL, `updatedAt` datetime NOT NULL, `rate` double DEFAULT NULL, `currency` varchar(255) NOT NULL, `address` varchar(255) DEFAULT NULL, `received` double DEFAULT NULL, `amount` double DEFAULT NULL, `tip` double NOT NULL DEFAULT 0, `network` varchar(255) DEFAULT NULL, `unconfidential` varchar(255) DEFAULT NULL, `uuid` varchar(255) DEFAULT NULL, `memo` text DEFAULT NULL, `account_id` int(11) DEFAULT NULL, `path` varchar(255) DEFAULT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=7771 DEFAULT CHARSET=latin1; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Table structure for table `linkingkeys` -- DROP TABLE IF EXISTS `linkingkeys`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `linkingkeys` ( `id` int(11) NOT NULL AUTO_INCREMENT, `user_id` int(11) DEFAULT NULL, `hex` varchar(255) DEFAULT NULL, `createdAt` datetime NOT NULL, `updatedAt` datetime NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=4666 DEFAULT CHARSET=latin1; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Table structure for table `orders` -- DROP TABLE IF EXISTS `orders`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `orders` ( `id` int(11) NOT NULL AUTO_INCREMENT, `v1` double DEFAULT NULL, `v2` double DEFAULT NULL, `user_id` int(11) DEFAULT NULL, `createdAt` datetime NOT NULL, `updatedAt` datetime NOT NULL, `accepted` tinyint(1) NOT NULL DEFAULT 0, `rate` double GENERATED ALWAYS AS (`v2` / `v1`) VIRTUAL, `completedAt` datetime DEFAULT NULL, `a1_id` int(11) DEFAULT NULL, `a2_id` int(11) DEFAULT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=9316 DEFAULT CHARSET=utf8mb4; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Table structure for table `payments` -- DROP TABLE IF EXISTS `payments`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `payments` ( `id` int(11) NOT NULL AUTO_INCREMENT, `user_id` int(11) DEFAULT NULL, `hash` text DEFAULT NULL, `createdAt` datetime NOT NULL, `updatedAt` datetime NOT NULL, `rate` double DEFAULT NULL, `currency` varchar(255) DEFAULT NULL, `address` varchar(255) DEFAULT NULL, `received` tinyint(1) DEFAULT NULL, `amount` double DEFAULT NULL, `tip` double NOT NULL DEFAULT 0, `confirmed` tinyint(1) NOT NULL, `fee` double NOT NULL DEFAULT 0, `network` varchar(255) DEFAULT NULL, `account_id` int(11) DEFAULT NULL, `preimage` varchar(255) DEFAULT NULL, `memo` text DEFAULT NULL, `redeemcode` varchar(255) DEFAULT NULL, `redeemed` tinyint(1) NOT NULL DEFAULT 0, `path` varchar(255) DEFAULT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=40254 DEFAULT CHARSET=latin1; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Table structure for table `referrals` -- DROP TABLE IF EXISTS `referrals`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `referrals` ( `id` int(10) unsigned NOT NULL AUTO_INCREMENT, `token` varchar(255) DEFAULT NULL, `expiry` date DEFAULT NULL, `status` enum('pending','active','expired','cancelled') DEFAULT NULL, `sponsor_id` int(11) NOT NULL, `user_id` int(11) DEFAULT NULL, `created_at` timestamp NOT NULL DEFAULT current_timestamp(), `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', PRIMARY KEY (`id`), UNIQUE KEY `token` (`token`), KEY `sponsor_id` (`sponsor_id`), KEY `user_id` (`user_id`) ) ENGINE=InnoDB AUTO_INCREMENT=8 DEFAULT CHARSET=latin1; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Table structure for table `urls` -- DROP TABLE IF EXISTS `urls`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `urls` ( `hash` varchar(255) DEFAULT NULL, `data` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL, UNIQUE KEY `urls_hash_unique` (`hash`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Table structure for table `users` -- DROP TABLE IF EXISTS `users`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `users` ( `id` int(11) NOT NULL AUTO_INCREMENT, `username` varchar(255) DEFAULT NULL, `password` varchar(255) DEFAULT NULL, `unit` varchar(255) DEFAULT NULL, `account_id` int(11) DEFAULT NULL, `currency` varchar(255) DEFAULT NULL, `createdAt` datetime NOT NULL, `updatedAt` datetime NOT NULL, `twofa` tinyint(1) DEFAULT NULL, `authyId` varchar(255) DEFAULT NULL, `pin` varchar(255) DEFAULT NULL, `currencies` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL, `otpsecret` varchar(255) DEFAULT NULL, `ip` int(10) unsigned DEFAULT NULL, `subscriptions` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL, `seed` varchar(255) DEFAULT NULL, `linkingKeys` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL, `fiat` tinyint(1) NOT NULL DEFAULT 0, `index` int(11) NOT NULL DEFAULT 0, `verified` varchar(255) DEFAULT NULL, `locked` tinyint(1) DEFAULT 0, `email` varchar(255) DEFAULT NULL, `sms` varchar(255) DEFAULT NULL, PRIMARY KEY (`id`), KEY `ip` (`ip`) ) ENGINE=InnoDB AUTO_INCREMENT=788 DEFAULT CHARSET=latin1; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Table structure for table `waiting_list` -- DROP TABLE IF EXISTS `waiting_list`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `waiting_list` ( `id` int(10) unsigned NOT NULL AUTO_INCREMENT, `email` varchar(255) DEFAULT NULL, `sms` varchar(255) DEFAULT NULL, `user_id` int(11) DEFAULT NULL, `status` enum('pending','contacted','registered','cancelled') DEFAULT 'pending', `notes` text DEFAULT NULL, `created_at` timestamp NOT NULL DEFAULT current_timestamp(), `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', PRIMARY KEY (`id`), UNIQUE KEY `email` (`email`) ) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=latin1; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Table structure for table `withdrawals` -- DROP TABLE IF EXISTS `withdrawals`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `withdrawals` ( `id` int(11) NOT NULL AUTO_INCREMENT, `user_id` int(11) NOT NULL, `createdAt` datetime NOT NULL, `updatedAt` datetime NOT NULL, `amount` double DEFAULT NULL, `completed` tinyint(1) DEFAULT NULL, `transit` varchar(255) DEFAULT NULL, `account` varchar(255) DEFAULT NULL, `institution` varchar(255) DEFAULT NULL, `notes` text DEFAULT NULL, `email` varchar(255) DEFAULT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=4113 DEFAULT CHARSET=latin1; /*!40101 SET character_set_client = @saved_cs_client */; /*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */; /*!40101 SET SQL_MODE=@OLD_SQL_MODE */; /*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */; /*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */; /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */; /*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */; /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */; /*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */; -- Dump completed on 2021-06-02 20:32:20