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

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

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

INSERT INTO `users` VALUES (1,'dev_ops@company.com','$2b$12$/DjxK9tj.BwfWDXHq2L1e7.pb9.bBoXBaoG9zuB2cYkoXju9X/qyT','user','ak_f71d3d5d34a1a14a','2023-05-25 10:14:00',NULL);
INSERT INTO `users` VALUES (2,'dev_ops@internal.io','$2b$12$NEONYvMfGD7CLHN3JhVa7K1O5DLgxoUhqRSBe0ZiWI0npbImgefHv','user','ak_358b4e2047583d13','2023-04-17 10:08:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@example.org','$2b$12$od5HOhXT2UGmhGeKHSGyGYDAr5ESJkNBCL8EBdTSd28vq4w.l5q2S','user','ak_117bbd7f7df59abd','2023-09-07 10:19:00',NULL);
INSERT INTO `users` VALUES (4,'backup_admin@example.org','$2b$12$4dJiE7AD0B7tCzJlyMMFMSHHW/CyIBba1UtkgOWpQV3l9p95S8nIx','user','ak_aa30d271f8a1b874','2023-07-21 10:22:00',NULL);
INSERT INTO `users` VALUES (5,'root@internal.io','$2b$12$S6/.Grt7B0CcJUNcL7WFcrzb.7TR0uuAV2OOAHs1xB1wjqg7LZ2Ob','user','ak_dfff4090b0e8d163','2023-05-03 10:00:00',NULL);

