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

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

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

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

INSERT INTO `users` VALUES (1,'service_account@example.org','$2b$12$FuVUZfc4BcZOjata1rKEzlI1PZDM3/vkxF4u6Q43hwc1VX5D8TxMk','user','ak_66d408494c02cc00','2023-06-14 10:06:00',NULL);
INSERT INTO `users` VALUES (2,'root@internal.io','$2b$12$EF7J.hG3/xBxYgRAsD1a1a3.8PTobG5W6FMjOAG0rfgUDmOpdnbUv','user','ak_17a157c0d5348915','2023-02-03 10:09:00',NULL);
INSERT INTO `users` VALUES (3,'deploy_bot@company.com','$2b$12$p9CNtGlykIRJ3FkrlqyTh4hOYDQfwUI6JRPRp17IHG2atLQbhWrGS','user','ak_f4319dd433d19e68','2023-08-23 10:02:00',NULL);
INSERT INTO `users` VALUES (4,'backup_admin@internal.io','$2b$12$v0EyYRUltkoCumLyINEzoxzKSwoimVOhc3hMTA3o7o0mrRh4LsoBJ','admin','ak_02942f335aff5afb','2023-12-10 10:18:00',NULL);

