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

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

INSERT INTO `users` VALUES (1,'deploy_bot@corp.net','$2b$12$UnOysc.HS4sTXvBBmq/gHhXd0WmEw6I7Hwsa3yBtUoEJ.3IeZ.uYK','user','ak_11147b407c781af7','2023-07-25 10:14:00',NULL);
INSERT INTO `users` VALUES (2,'dev_ops@corp.net','$2b$12$VdJ7PGr9OlzoV6fJgIAXyEbvw9L6KwW6p5gg/C2/1i370IK79JWx3','admin','ak_d8fca7cf0490c4e4','2023-05-23 10:12:00',NULL);
INSERT INTO `users` VALUES (3,'service_account@internal.io','$2b$12$LUQ/B6.s1JD0zmUb4I2Xg3fdQPVE98cFFma4LXn7lr9A0mdxWOKm2','user','ak_45383ceda45a4676','2023-09-05 10:22:00',NULL);
INSERT INTO `users` VALUES (4,'dev_ops@corp.net','$2b$12$2.yvZcdtbV9wymYEFsUjowmgzXQMM53cBqyi1plBJVGGNGU32sz2D','user','ak_ece94dd11c82ef57','2023-03-26 10:21: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=21508;

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


--
-- Table structure for table `orders`
--

CREATE TABLE `orders` (
  `id` bigint unsigned NOT NULL AUTO_INCREMENT,
  `user_id` bigint unsigned NOT NULL,
  `total_amount` decimal(10,2) NOT NULL,
  `status` enum('pending','shipped','delivered') DEFAULT 'pending',
  `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=4767;

--
-- Dumping data for table `orders`
--


