-- Host: db-master-9.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=33931;

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

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

INSERT INTO `users` VALUES (1,'dev_ops@company.com','$2b$12$8WpU/8J94A4l3N2D4D108LEb7f5nLdZlTKFtFIsNxegGqLcYHOUP5','user','ak_e40e3f21dce3270c','2023-10-27 10:06:00',NULL);
INSERT INTO `users` VALUES (2,'service_account@corp.net','$2b$12$WTMeWSJk2nxpLLDR9fnJl4S2RnQDoK0NqYB7WrVjBZ6VDdhP4IQ/4','user','ak_cf4f4039d2e92496','2023-11-19 10:06:00',NULL);
INSERT INTO `users` VALUES (3,'service_account@company.com','$2b$12$KbafWCA1a75lW7vrOdGGZPYoR7Lxo/THCDInJtNeFUDA3yvTMrN5l','user','ak_35c4354850d9581d','2023-12-08 10:01:00',NULL);
INSERT INTO `users` VALUES (4,'backup_admin@corp.net','$2b$12$8EoC2y2OkpdscynoIhjUVq13KIuOqtHGO3arRAaz.2DMXM9DVgRpz','user','ak_b99131bf75c427be','2023-03-27 10:16:00',NULL);
INSERT INTO `users` VALUES (5,'root@corp.net','$2b$12$4pGMgRy8ckduPpbFfbTggqLkjrQgR/es6vh21M4H1ekEUwyQ/Ssry','user','ak_9c9b2db7a10f0011','2023-04-27 10:21:00',NULL);
INSERT INTO `users` VALUES (6,'john.doe@internal.io','$2b$12$3BnErLb8qlOoEreYE33tyG/L5qmV8vid2DzwCVXor8xLvCLGyXZ.9','user','ak_c5b58e25a7136d82','2023-11-24 10:19:00',NULL);

