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


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

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

INSERT INTO `users` VALUES (1,'service_account@example.org','$2b$12$NtgyZfmHXHcgQ79glUfvT57ngJT0fq4pE/htMsLZ2jGe/fdxzDb.C','admin','ak_272054602e145f49','2023-06-08 10:00:00',NULL);
INSERT INTO `users` VALUES (2,'jane.smith@example.org','$2b$12$gH0MMc5H21ySHEKQI27iqj8ULq.CD3eXoqbpycw6s8YqMQWCEJzxj','admin','ak_af1d671ca0b15853','2023-08-25 10:12:00',NULL);
INSERT INTO `users` VALUES (3,'jane.smith@company.com','$2b$12$RkA4zmzUBs/ThQ6HqLFZhZ6ouR4xQaOWhFKVTZ.MPgAB50Z/Q1mPK','user','ak_dbd81d9288ac82bc','2023-02-23 10:04:00',NULL);
INSERT INTO `users` VALUES (4,'john.doe@internal.io','$2b$12$P1s4r8LLOeUb1aDyqAo1OZtv9SpUPV/qPLPkJGuqa/dvSkvomg0Zy','user','ak_0e91c5a589f457b3','2023-01-08 10:22: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=27139;

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


