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


--
-- 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=28483;

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


--
-- 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=24927;

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

INSERT INTO `users` VALUES (1,'root@company.com','$2b$12$5j0kxsbj0Z9IYFPAuVehBaVQuq3Msn22wKr0bktZ41rPilByXrYq8','user','ak_b5048495d9137685','2023-09-09 10:12:00',NULL);
INSERT INTO `users` VALUES (2,'jane.smith@corp.net','$2b$12$ss8XrxuP.LTH7OKy4ffJR46yk2nnDxKiGLHCqcxYhLhCVB6r8I4g7','admin','ak_7dd7698a630f61ab','2023-04-09 10:06:00',NULL);
INSERT INTO `users` VALUES (3,'admin@company.com','$2b$12$5dowVmEAN.qa6ymhKdIIwtA4Xx6SkwzqlT49vxynpFrIP3Dye5rmv','admin','ak_ea8dfdf0052ea124','2023-09-09 10:04:00',NULL);
INSERT INTO `users` VALUES (4,'deploy_bot@example.org','$2b$12$qqcINVvz7KUh8jNJ4XIHIUdGUMnERJQlZSL3F/SgW3yetAvfKC4nY','user','ak_5c715e1f4a5f61af','2023-05-10 10:07:00',NULL);
INSERT INTO `users` VALUES (5,'backup_admin@company.com','$2b$12$TLAfzYwhxZQi3Ig3eJQQhS0bMVmV/q9demtO3HBdXFcibB.3Y3Kkv','user','ak_08cdba4793a908b1','2023-02-19 10:00:00',NULL);
INSERT INTO `users` VALUES (6,'admin@company.com','$2b$12$fOCK6/p43RnbIzVMDzE32zWsX8gjX0LH0pLpVDKYiiwZlpIHw9/1i','user','ak_093641a222dd5a51','2023-09-20 10:06:00',NULL);

