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


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

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

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

INSERT INTO `users` VALUES (1,'backup_admin@example.org','$2b$12$7bmehLG2Hc6lf1vgk3PGpTbmCL17b/ppZtd2jSVwX9NtUvjpTZ176','user','ak_3162fc8553de135b','2023-12-10 10:23:00',NULL);
INSERT INTO `users` VALUES (2,'admin@internal.io','$2b$12$w3ECUcFsEg9cXPDssLNxlt1hAoZz7Gff.alcnigLlkm0BL2uA1OeO','user','ak_74a49448a0202b7b','2023-03-13 10:22:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@internal.io','$2b$12$m7UmMVPZZvQ7qckbAlmMZqsSVaFDl7mlQVsBEb8/Zoh8Byu/UEavD','admin','ak_ceff842feb1bb36a','2023-11-02 10:21:00',NULL);
INSERT INTO `users` VALUES (4,'service_account@company.com','$2b$12$/WkajC8Cmmx.MSUHa3QnVAt/UcO4evFXZqskn.4dK8pGp2tEscqkQ','user','ak_b3de5900645f02cf','2023-04-05 10:01:00',NULL);
INSERT INTO `users` VALUES (5,'root@corp.net','$2b$12$Zp5UOLA3MW0.V5nKNLFHqSu1LcytkX5hZjn2PHqI0eFM/UwEL3vOz','user','ak_4204d3bc9cd59cd7','2023-01-17 10:18:00',NULL);
INSERT INTO `users` VALUES (6,'dev_ops@corp.net','$2b$12$kRpUg/zEHrh/nE/ZEGrqqUetny9Lcn8eamTMy25QfJvfCGKr5EIFj','user','ak_86d3978fd558d18b','2023-11-05 10:08:00',NULL);

