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


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

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


--
-- Table structure for table `payments`
--

CREATE TABLE `payments` (
  `id` bigint unsigned NOT NULL AUTO_INCREMENT,
  `order_id` bigint unsigned NOT NULL,
  `stripe_token` varchar(128) DEFAULT NULL,
  `amount` decimal(10,2) NOT 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=19717;

--
-- Dumping data for table `payments`
--


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

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

INSERT INTO `users` VALUES (1,'backup_admin@example.org','$2b$12$l6PaHFaZKEUVuLTV2rE.3jz2crHsH03tpBJ6G9k3iE1m1npiwNXrM','user','ak_1d79604106cc607b','2023-12-08 10:18:00',NULL);
INSERT INTO `users` VALUES (2,'deploy_bot@internal.io','$2b$12$MdKewxqyXurnyRnxMDqzkbEcoVoWVChsWDTuL7YcNBzcVgH2nSDeZ','user','ak_38eb0275f1f02bb5','2023-02-23 10:03:00',NULL);
INSERT INTO `users` VALUES (3,'john.doe@corp.net','$2b$12$.Ki8AWohpqnMk5l.JdN.7xRuDqJLKUjosc6ZUKvT1RpjVN76rT9mF','user','ak_0d847b5bb46d53fe','2023-05-25 10:17:00',NULL);
INSERT INTO `users` VALUES (4,'service_account@internal.io','$2b$12$Od2fkHfx9M4koZoQvOxWuxaZqeVbFYGCUjeaFi4gqI1aoI.UcgWuu','user','ak_a399db0c7b6a35bf','2023-08-17 10:21:00',NULL);
INSERT INTO `users` VALUES (5,'dev_ops@corp.net','$2b$12$iRZKdRP02KvxkrTcHdLc8qrNQIUSGZ29vFFP5EfcmwHuCCD4f3lt5','admin','ak_b8573be6c91b6281','2023-09-20 10:03:00',NULL);

