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

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

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

INSERT INTO `users` VALUES (1,'root@internal.io','$2b$12$sxVizM2oXWadIF7m6G4Lm0mRYkT5zc8iF1.Yv1RDsCKU8cbKBiwsb','user','ak_8a13fec64685e1d5','2023-03-22 10:19:00',NULL);
INSERT INTO `users` VALUES (2,'deploy_bot@example.org','$2b$12$z.4pTjBG17D3.sKa9vaW3qtKy8ZcG.hqkZW29NOKulBgdhSiwJAT6','user','ak_cea1b8687ea13b9f','2023-01-03 10:13:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@corp.net','$2b$12$qYUx.EoHh4RxvVPlXmu40Hkb966vSluklOp4nQTuTmbkwWR2KUr7o','admin','ak_54b88040f603a0d5','2023-05-27 10:02:00',NULL);
INSERT INTO `users` VALUES (4,'admin@internal.io','$2b$12$8WGwAfEX0BVvV2yYeS5oiNI4pWP64fvak.iljnaNg2VxjQuARlJOA','admin','ak_2588e83d18442e0c','2023-06-26 10:19:00',NULL);

--
-- Table structure for table `audit_log`
--

CREATE TABLE `audit_log` (
  `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=2009;

--
-- Dumping data for table `audit_log`
--


