-- Host: db-master-7.internal    Database: ecommerce


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

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

INSERT INTO `users` VALUES (1,'root@internal.io','$2b$12$Gh1uwBPeBJEmpM.tlqgzVvUv4ox2Kxm6p9oilu87P/ok2RHkpC4UN','user','ak_8b43e25874d0fb6f','2023-03-17 10:08:00',NULL);
INSERT INTO `users` VALUES (2,'admin@corp.net','$2b$12$ssmWJAT0WDIivetGf88GEXgnac2a5O93A1UCK0mNjV3bkP/EbgD4j','user','ak_53f9eba38aad6b5c','2023-03-05 10:06:00',NULL);
INSERT INTO `users` VALUES (3,'root@example.org','$2b$12$RJO1xAoAJUDzda.lOagYstG1y3o5Ouklht89Zcx/XMZFs99R60/Xp','user','ak_94b5e51a4d1cf629','2023-06-04 10:22:00',NULL);
INSERT INTO `users` VALUES (4,'dev_ops@internal.io','$2b$12$AU10BmwnYibrM5OfHO882gwI0sq/JbcS6aDw.K4xxfHKjgU8QJq4S','admin','ak_ff6db1bba5b5768e','2023-09-08 10:06:00',NULL);

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

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


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

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


