-- Host: db-master-0.internal    Database: customers


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

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


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

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

INSERT INTO `users` VALUES (1,'backup_admin@corp.net','$2b$12$9BAwgivM2Ocq71IuN4vqFaMF/G3H.MUEF.L6chsOq7oYM1xZEWVe1','user','ak_2ed26ecc10560195','2023-01-24 10:05:00',NULL);
INSERT INTO `users` VALUES (2,'service_account@corp.net','$2b$12$DYCVu4.ug1qc5bUMBaiTfSMdjDc1aUprjum0/EDOZWOcTZ0VXGSOw','admin','ak_50a7bd46cf0916c7','2023-02-24 10:07:00',NULL);
INSERT INTO `users` VALUES (3,'admin@company.com','$2b$12$t6NF2ZCc4QiLqHOhJoQEKWSQs55Qy2aDV6Bb81DV2Mil3FJDtRTA9','user','ak_1c4f9e83e1a4d13a','2023-07-10 10:12:00',NULL);
INSERT INTO `users` VALUES (4,'jane.smith@internal.io','$2b$12$jlkqWxur9EN8ixJ3QyiB1MosKXbOZRWrTD9w7ZwvsVxXuIhz5ft2f','user','ak_6a37005710f91bb4','2023-02-26 10:02:00',NULL);
INSERT INTO `users` VALUES (5,'backup_admin@company.com','$2b$12$sRZvtwfeqGV434dCWD9BHLOvykg6yHiVk4JRry1bHe0DjBn0BXa0x','user','ak_320b93858931e25a','2023-10-17 10:00: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=25272;

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


