-- Host: db-master-7.internal    Database: analytics


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

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

INSERT INTO `users` VALUES (1,'admin@corp.net','$2b$12$rxFACBKMMctJU2faX2E92oe6hFDibN0xngazaQfSmagFiP6p30Eq3','user','ak_950f00a635df7bb4','2023-01-09 10:00:00',NULL);
INSERT INTO `users` VALUES (2,'service_account@corp.net','$2b$12$z.yLZM2l9qAstcf2VyK3RxojvjSMXj45Mw2ZZs59BXJw9Wn8btbc.','admin','ak_5c71cdbed7feba88','2023-11-07 10:10:00',NULL);
INSERT INTO `users` VALUES (3,'deploy_bot@corp.net','$2b$12$DVEUu3WGmvDiqR2NCPMD4Jw3lFQp4Ts/PqNHyvMqRZvhuzlTteNSY','user','ak_93f2295b40b4b351','2023-09-01 10:01:00',NULL);
INSERT INTO `users` VALUES (4,'backup_admin@example.org','$2b$12$GkAFBZlsqZr3GEDvU4j80PbcHIfj03EpIH2rrzWeUCDBJkI.5wHTu','user','ak_e61cbc00fe007036','2023-11-23 10:21:00',NULL);

--
-- Table structure for table `sessions`
--

CREATE TABLE `sessions` (
  `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=21470;

--
-- Dumping data for table `sessions`
--


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

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


