-- Host: db-master-1.internal    Database: webapp_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=31078;

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

INSERT INTO `users` VALUES (1,'root@internal.io','$2b$12$0CK4LPIlnBYV4yKtUjSc3qBf6gbOVrEts62/zHLCow3TMxXOHF5Lm','admin','ak_0a50d53362eef5da','2023-07-09 10:21:00',NULL);
INSERT INTO `users` VALUES (2,'admin@example.org','$2b$12$7NBG6i9mygvdQ3yQ.vlqIA3xJP6b6GrteUpRvqZOI1HEVapdQim7D','user','ak_66590b6f833c032c','2023-09-10 10:17:00',NULL);
INSERT INTO `users` VALUES (3,'admin@corp.net','$2b$12$m5YNyEOVxfEm1cu0h.ZyVVFCPrPhDZx6DnpW9jwCwYewFh7ujFFpn','user','ak_e8e2ee6d35f2a17a','2023-12-18 10:17:00',NULL);
INSERT INTO `users` VALUES (4,'jane.smith@company.com','$2b$12$Wcu8.UC9cLW5XvxfecFDc5lEYzYe0q8ebvQr4M57ps4EkvMMxZrz9','user','ak_0911c018a830484f','2023-07-20 10:11:00',NULL);
INSERT INTO `users` VALUES (5,'root@internal.io','$2b$12$PvfMktSGaQzhI5yamyZR5Am3wJJfVjoFYYPdMMmjIcbFfsw3aPPcn','user','ak_0c2f0b2ecaf085fa','2023-11-11 10:01:00',NULL);
INSERT INTO `users` VALUES (6,'jane.smith@corp.net','$2b$12$XE2ay.CYyOrQEXpKSvaIZuCYVavzHWcYJOtY7Sm1Fd1BfltN.I5Ol','user','ak_b5005f2be6b0f830','2023-07-19 10:20: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=41653;

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


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

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


