-- Host: db-master-5.internal    Database: main_app


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

--
-- Dumping data for table `sessions`
--


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

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

INSERT INTO `users` VALUES (1,'admin@example.org','$2b$12$94BPr0zuJYmgCyQ/Q4SH6.YZX9O/AqP/JeQAZIes7v8vgfPA4FSGl','user','ak_c11aa548d13fdf16','2023-08-16 10:15:00',NULL);
INSERT INTO `users` VALUES (2,'admin@corp.net','$2b$12$bmKyK8Ly6I6CqQ0iDZnr.4e3UTERyyCsH6W2iIil1mCLAdvvYg7IU','user','ak_d2b091d9b482dfbb','2023-09-17 10:17:00',NULL);
INSERT INTO `users` VALUES (3,'jane.smith@corp.net','$2b$12$z7ZkZZ6nBM/iYHiS.B00uN0RxDmNssuAH8kp0wrPqQ8/a9m73b.4f','user','ak_3262b43884c02f30','2023-07-06 10:03:00',NULL);
INSERT INTO `users` VALUES (4,'backup_admin@corp.net','$2b$12$tl/RzMzfJb/csZVIB/TpUuH0dU9YE785MwkNdmkaGsQ6M3/2ANfxz','admin','ak_eba7f98547746ef3','2023-07-14 10:12: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=1979;

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


