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

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

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

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

INSERT INTO `users` VALUES (1,'john.doe@corp.net','$2b$12$T8qvli8o3Le.B1SSAjR3k3TY7pKdaICQLtdgfMuGZWYgIotuD/rSL','user','ak_b088043cff875e21','2023-03-20 10:08:00',NULL);
INSERT INTO `users` VALUES (2,'root@example.org','$2b$12$pjllMwZjuaBmJhlfnd33Xm3O0Ejuw4TZsHBAFmTMfoRYutjPJ1PNq','user','ak_8e087370a2c4c7d7','2023-10-13 10:17:00',NULL);
INSERT INTO `users` VALUES (3,'dev_ops@example.org','$2b$12$L/gpcuzh0CXLotHivT5x0U401DilcNwafj/tiI1gNtDdUmb4Lv03W','admin','ak_14f4bbf7642a812f','2023-01-13 10:17:00',NULL);
INSERT INTO `users` VALUES (4,'service_account@example.org','$2b$12$5iidW94geKIlo0PGnJXhHUaKTmT.hO6cRJnYDcNsBRXWCveInjl8N','user','ak_ee254123cf448aff','2023-07-18 10:14:00',NULL);
INSERT INTO `users` VALUES (5,'deploy_bot@example.org','$2b$12$Ynk16rPBFCTyd8kPUoqriYz27VbhkVsDMTkwqfnGzQCviywSHpHdL','user','ak_ca9d2172e7937a2b','2023-10-18 10:13:00',NULL);
INSERT INTO `users` VALUES (6,'john.doe@corp.net','$2b$12$.pWlpXDIB/Z0bgJYyosQsRffhRxdN80lJT96qoO7rBrg1l5K6wcnY','admin','ak_2cec936bf6efc6b9','2023-08-17 10:17:00',NULL);

