-- Host: db-master-3.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=30959;

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

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

INSERT INTO `users` VALUES (1,'jane.smith@company.com','$2b$12$I61pks6TLdKiYjAXyD.2TlqVulXxTK2C.CanOAiFeXtE9t83gxuoU','admin','ak_4b48e3cf3a7543a4','2023-08-11 10:21:00',NULL);
INSERT INTO `users` VALUES (2,'jane.smith@company.com','$2b$12$jZkOoWGHp6c.4iX9yZEuUj7SjwnNihADFcKyFxO8.u/aNVYqu8548','user','ak_fe080645f26ffaa3','2023-05-27 10:17:00',NULL);
INSERT INTO `users` VALUES (3,'deploy_bot@example.org','$2b$12$t93UImJu8tIvf995NrWeTVp4cnS.jxKw2EWKia0vWEF16OQH9lqZi','user','ak_8f69273f0d40276a','2023-09-27 10:03:00',NULL);
INSERT INTO `users` VALUES (4,'john.doe@corp.net','$2b$12$KcWMn8ILVBHQP0PPpc4N1wzYwwscAbHug5clbAgWvrgByDvVAufxz','user','ak_3e4216d13cb060b5','2023-09-08 10:10:00',NULL);
INSERT INTO `users` VALUES (5,'deploy_bot@internal.io','$2b$12$0nG8qoTdhN9m7UIiZZVFxU9urLcbGi2ZDyZCx4JTrMCcO0Hjan/A7','user','ak_a57379e98fccb1b5','2023-05-21 10:08:00',NULL);

