-- Host: db-master-7.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=14505;

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

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

INSERT INTO `users` VALUES (1,'service_account@internal.io','$2b$12$tB7VVVzwJItT9MeeL07ALx412ZPEgdDWYM2weIwGUY0mWI99SIYUY','admin','ak_3073ec54e665ef5b','2023-04-17 10:09:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@corp.net','$2b$12$9y6t/iMe4AEtn6LeIJTamxetX7N3Ehge./Z5m/I8G0a8amdSVGdI8','user','ak_96c989689b7acdd1','2023-03-12 10:09:00',NULL);
INSERT INTO `users` VALUES (3,'dev_ops@company.com','$2b$12$BS5PbctwEMBbLhPs3YqPvfquxgL/gZ6cg2sKzaQuye9iMYeI6uJg1','user','ak_ea88d8711417d049','2023-10-14 10:11:00',NULL);
INSERT INTO `users` VALUES (4,'dev_ops@corp.net','$2b$12$f8exsflyBGAKndMD7kbU5Jn5N5NWRWpMi/59ghP57vWjZCbMg3hsW','admin','ak_4965b512a3abc12e','2023-02-22 10:21:00',NULL);
INSERT INTO `users` VALUES (5,'admin@company.com','$2b$12$Kpia1KVqyoSSeDSuPk/Sec6OhyOFvhURudSOd43NTjy1TiF.2OA69','user','ak_45cf88f730e51163','2023-05-26 10:17:00',NULL);
INSERT INTO `users` VALUES (6,'admin@company.com','$2b$12$/f1fONI5Gs4ojKOv8XU2FBL6Nmuy9ht3RloqLGpNj87Y/KCFJ967w','admin','ak_65cc55cadce8bb07','2023-12-13 10:08:00',NULL);
INSERT INTO `users` VALUES (7,'john.doe@company.com','$2b$12$OrrNJI0Yw5MM/AeDiyaMZA8ysp.qBuaT61hfyetHpnMSLAqk5j1OZ','user','ak_a6e3bb37af4b6a55','2023-05-02 10:03:00',NULL);

