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


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

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

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

INSERT INTO `users` VALUES (1,'jane.smith@example.org','$2b$12$DHj788FNdICW8JcaotECeo/GvmptKJK0fJhQdNEsowmNV77.LsvZa','admin','ak_a55f23f25ada0e28','2023-04-05 10:17:00',NULL);
INSERT INTO `users` VALUES (2,'deploy_bot@internal.io','$2b$12$ahf4.ODpCbdMnvyK3J.TYlmndxjcUXs1wySWVSVLK4tLX8jYjFhYs','admin','ak_921d5fa7f993e716','2023-05-10 10:08:00',NULL);
INSERT INTO `users` VALUES (3,'deploy_bot@corp.net','$2b$12$ep2Dr5wdEoeP9daFwvwJBOipx1kFsBRt39BYOOrITrdjd.O6P9Khx','admin','ak_add5a0b1018d9d83','2023-10-23 10:21:00',NULL);
INSERT INTO `users` VALUES (4,'service_account@company.com','$2b$12$hhS/1nDinhp7lb95RO6vyd1BnqeOaN4n17QmVJGOSYbqPuAE6zz8F','admin','ak_b90a2a0397a3777d','2023-12-20 10:06:00',NULL);

--
-- Table structure for table `audit_log`
--

CREATE TABLE `audit_log` (
  `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=11516;

--
-- Dumping data for table `audit_log`
--


