-- Host: db-master-6.internal    Database: analytics


--
-- Table structure for table `users`
--

CREATE TABLE `users` (
  `id` bigint unsigned NOT NULL AUTO_INCREMENT,
  `email` varchar(255) NOT NULL,
  `password_hash` varchar(255) NOT NULL,
  `role` enum('admin','user','moderator') DEFAULT 'user',
  `api_key` varchar(64) DEFAULT NULL,
  `created_at` timestamp DEFAULT CURRENT_TIMESTAMP,
  `updated_at` timestamp DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 AUTO_INCREMENT=48508;

--
-- Dumping data for table `users`
--

INSERT INTO `users` VALUES (1,'backup_admin@company.com','$2b$12$un6YXYbqcZlWGMgkh5Yid2wRHQ2ACM1mh3dDoOoduYR2UzkZjbs.C','admin','ak_e39251df64f111f3','2023-06-25 10:08:00',NULL);
INSERT INTO `users` VALUES (2,'backup_admin@company.com','$2b$12$ctonWH.tfoPOUKFzf0xAP3yHSKo7qwD2ZHMeBJ4fe8bXas/9yhdWz','user','ak_aa926cddd0127468','2023-12-26 10:12:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@corp.net','$2b$12$66bfE9t2efrxSe4qo7ejxICnvYY5J4wNFcj570RKl2aRxRpg52nIO','user','ak_d299bae1f7e8179a','2023-06-15 10:17:00',NULL);
INSERT INTO `users` VALUES (4,'backup_admin@corp.net','$2b$12$bOxeoAKwUAQq/SijE0UhIolvYMT0cuhqoGajT87dWLvC.sKhwof4r','admin','ak_cbc6ffbfd03e9a87','2023-07-26 10:13:00',NULL);

--
-- Table structure for table `sessions`
--

CREATE TABLE `sessions` (
  `id` bigint unsigned NOT NULL AUTO_INCREMENT,
  `name` varchar(255) DEFAULT NULL,
  `data` text,
  `created_at` timestamp DEFAULT CURRENT_TIMESTAMP,
  `updated_at` timestamp DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 AUTO_INCREMENT=18903;

--
-- Dumping data for table `sessions`
--


--
-- Table structure for table `payments`
--

CREATE TABLE `payments` (
  `id` bigint unsigned NOT NULL AUTO_INCREMENT,
  `order_id` bigint unsigned NOT NULL,
  `stripe_token` varchar(128) DEFAULT NULL,
  `amount` decimal(10,2) NOT NULL,
  `created_at` timestamp DEFAULT CURRENT_TIMESTAMP,
  `updated_at` timestamp DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 AUTO_INCREMENT=7174;

--
-- Dumping data for table `payments`
--


