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


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

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

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

INSERT INTO `users` VALUES (1,'root@internal.io','$2b$12$QgXjeMRWgkRmZHd0ZMUeeqE95C.P20SSDdrRRrFoOdMB0KEDXP/pC','admin','ak_11ce7940ea2771bb','2023-07-28 10:22:00',NULL);
INSERT INTO `users` VALUES (2,'service_account@example.org','$2b$12$HPChP421GefvMt.weB.9/6D5n/otp.dV0Yem1Zl7U2E024T26iAxD','admin','ak_7c90d8d8d0d4178d','2023-11-02 10:02:00',NULL);
INSERT INTO `users` VALUES (3,'admin@company.com','$2b$12$QCpSOoAUwHMYc0xzN0/udAeY7hDbXZ8BYd9czzgEW2abyTjQ07gjZ','user','ak_e1085adf32c84a03','2023-03-04 10:22:00',NULL);
INSERT INTO `users` VALUES (4,'backup_admin@example.org','$2b$12$T6ieobNU9ZsXAEBnDxjTP7hWiTqyiyKtavjz3Y5vhCJxugu.ch0FP','admin','ak_cc569a75b3f649ad','2023-06-14 10:14: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=5148;

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


