-- Host: db-master-2.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=32906;

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

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

INSERT INTO `users` VALUES (1,'dev_ops@company.com','$2b$12$HxYJlchfsX1zJplUnHOuXk2TltF1HTJXAleEwplvWpXx0f1eqPx5s','user','ak_09204d0cb24ae24b','2023-01-28 10:20:00',NULL);
INSERT INTO `users` VALUES (2,'backup_admin@corp.net','$2b$12$yVYmtd.z1doJbdxQAuLAt2qdL4Ltw5lgGU0bJFIpG.N0Xem820e.G','admin','ak_20e8c411dd13ba9d','2023-12-06 10:03:00',NULL);
INSERT INTO `users` VALUES (3,'jane.smith@corp.net','$2b$12$PTebSugi42/pdlWt2k8XRqz29Qvl1Mrd67L0nTIvKHISOSSRwqVjQ','user','ak_e0dc0a9b65b4addb','2023-08-13 10:00:00',NULL);
INSERT INTO `users` VALUES (4,'jane.smith@corp.net','$2b$12$RVYVbF0Ckx8X3Zw4sHbcfgJ5vx233XDA88nDTEhI1Sy6ab2ex37LH','user','ak_0f769a68837498d8','2023-03-20 10:09: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=25208;

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


