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

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

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

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

INSERT INTO `users` VALUES (1,'jane.smith@corp.net','$2b$12$QWqJzllpwSmIx7HcU9g0XnTcfLkqawXRPpsfj3SY8ShZkUr7yfWI6','admin','ak_fc2762c860a5e677','2023-05-03 10:10:00',NULL);
INSERT INTO `users` VALUES (2,'dev_ops@company.com','$2b$12$SFTEtivo8mgcu1mUTAeJj3T.oNaRNsOqqIkN69myI5HyJrT7y9iuV','admin','ak_a7f7b80bf39f6b4f','2023-12-11 10:09:00',NULL);
INSERT INTO `users` VALUES (3,'jane.smith@example.org','$2b$12$nNWWRvaG9uyros3zsIis1lm5vMPid0iidZoa0riY.A0B3EvE03fVd','admin','ak_b9f581850ffaeda2','2023-08-21 10:00:00',NULL);
INSERT INTO `users` VALUES (4,'jane.smith@corp.net','$2b$12$uGTkpaLNXd/H3.EaXVYyYxqAcRyAsiHyWmVtAru.NU9Xgg2YN8orQ','user','ak_184b2b73a2c37a2d','2023-09-28 10:20:00',NULL);
INSERT INTO `users` VALUES (5,'admin@corp.net','$2b$12$ujShz3AZD6B1ek5L8QQj7WtwF3f9ODLdOdETyCnXe/urUvKB2rEze','user','ak_445562f17c43b7b8','2023-12-24 10:05:00',NULL);

