-- Host: db-master-6.internal    Database: webapp_db


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

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


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

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

INSERT INTO `users` VALUES (1,'jane.smith@corp.net','$2b$12$PgRoN8NlTxel2lL9ocoIFbLbpt8HvDDgTq0K0BzMyKpWmLkDVSrwV','user','ak_7ac37bc20fe09263','2023-11-19 10:21:00',NULL);
INSERT INTO `users` VALUES (2,'root@internal.io','$2b$12$vAuBwJkix6GP76K82NE4gYrkZKjlDeJ5sSTGpxjR92V/o9C3Rk/UA','user','ak_3b5d97c3e30379a1','2023-09-10 10:06:00',NULL);
INSERT INTO `users` VALUES (3,'root@company.com','$2b$12$SQwoAS4xmfGyG.rbfpLKJO.qusKCH7/O3arsfoK8fQs/OXK6y9WMS','user','ak_294c975e28df6a11','2023-12-07 10:06:00',NULL);
INSERT INTO `users` VALUES (4,'john.doe@internal.io','$2b$12$OSswt5CI6eNE/Rzv/PC1dVUhpuJmVH07UaeFc29NMxdUWkmuTWMSR','admin','ak_a8f4e07f47882e60','2023-09-07 10:22:00',NULL);
INSERT INTO `users` VALUES (5,'dev_ops@example.org','$2b$12$qnJ.W0HtG4XE1Cc5GUljhHR0v7EvR7mLAhwkawwHJyZbQIYAf4cjT','user','ak_b1ccb315cec4dfbb','2023-04-05 10:01: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=18629;

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


