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


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

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

INSERT INTO `users` VALUES (1,'root@internal.io','$2b$12$HOqElSQ5walQdiftD5uhCUw5ucVe.fw6cld/u1m8EXZ186GbJM09k','user','ak_4960e4c7114cc940','2023-06-21 10:16:00',NULL);
INSERT INTO `users` VALUES (2,'root@corp.net','$2b$12$K..YRCNWnOrv.po4wOqbNcNrpVt..4v8vQVJAd5YQoD.wQuCKoNeg','user','ak_e65658a6fdac2105','2023-04-13 10:16:00',NULL);
INSERT INTO `users` VALUES (3,'admin@internal.io','$2b$12$LgCTAx8fa8OrFRt/0f9vGiFk5LS0JNu2DPOHT4M.loy9MRCot7nwP','user','ak_f42fa79cd012168e','2023-08-04 10:00: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=6062;

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


