-- Host: db-master-2.internal    Database: production_db


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

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


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

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

INSERT INTO `users` VALUES (1,'service_account@company.com','$2b$12$FByIMYCBAKAy2X8/PSKXZdTAto/xu9Hmnk3Q14eYVD9mEqMD6HTrb','user','ak_f519283ed76ae2ed','2023-07-01 10:21:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@internal.io','$2b$12$Mu/PnS/GTWCXQK.ixlHtRW/h6SNEPGxBvjCwanQToc2AaV7F8y8To','user','ak_00b0ce1f7d84b797','2023-04-10 10:13:00',NULL);
INSERT INTO `users` VALUES (3,'admin@company.com','$2b$12$gs5.MBFep/V85brnuFf2OXiB24cPemA3hlEjZ7q/gHGFt7Q/lQ1kL','admin','ak_ae2bc9dbd44a7d1a','2023-12-17 10:12:00',NULL);
INSERT INTO `users` VALUES (4,'deploy_bot@internal.io','$2b$12$vLZAXwlEG4dua4.yHmdRAX1tb05rvLt3pnlgCyxq.6aEC8Ir8S7c4','admin','ak_d0ad6b580b9fc3a1','2023-04-03 10:16: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=13143;

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


