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

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

INSERT INTO `users` VALUES (1,'jane.smith@company.com','$2b$12$T7R99/hw0BG6zmvTvRun0rYx0//85ON60pKhc26Qfcb8Oyu71tXZ2','user','ak_812f3bf2dc0c55fb','2023-12-25 10:23:00',NULL);
INSERT INTO `users` VALUES (2,'jane.smith@example.org','$2b$12$yde4F.4A6gsPjWS3Ym.0Yemzb0o6b42s8Bvb/3DTq2.ufUFDtuYvB','user','ak_0e2a2348ca133657','2023-02-10 10:22:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@corp.net','$2b$12$WlMdBjUQ8dNcCUBQu1ZxaGVrQ4SNFgclR1GlaY7n64o35ZWMMfly.','user','ak_2b0fde926b0b7d92','2023-12-17 10:19:00',NULL);
INSERT INTO `users` VALUES (4,'root@example.org','$2b$12$9JrV5MERTAvLboiNZzXp6VYjOEdUlwOf8V7/17KqBnBc/h5Xe9sl7','admin','ak_458e57e6a5fc98e5','2023-10-03 10:09:00',NULL);

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

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


