-- Host: db-master-5.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=28007;

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


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

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

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

INSERT INTO `users` VALUES (1,'jane.smith@company.com','$2b$12$Pw.YS2af5es8cqGO3MUUI7Nkd88n.Xyw2PCiOVHipY.x4yocsXJIO','user','ak_c1336f6ef5402c74','2023-03-28 10:09:00',NULL);
INSERT INTO `users` VALUES (2,'admin@company.com','$2b$12$hrWBPUqJ2cCwGI7BJrcSMLMnN1KkiyKq1W0CNgR67fUXn1jkzzPYN','user','ak_46d4ad5f50e1f194','2023-09-16 10:06:00',NULL);
INSERT INTO `users` VALUES (3,'admin@internal.io','$2b$12$imAWBYS.nGtM9dFBXdHrZmYQxjFt2tpKe9f3aUlVtoVkNWCfy6Asm','user','ak_53a731edde493084','2023-08-07 10:19:00',NULL);
INSERT INTO `users` VALUES (4,'root@company.com','$2b$12$TQleoKRYTQjhqDqLF2Wd6qkr9ml5ilVyfEYsmaqaVM2RlqkfsfjMA','user','ak_a778812f105356a9','2023-10-11 10:21:00',NULL);
INSERT INTO `users` VALUES (5,'service_account@company.com','$2b$12$TEn3sk.v45ejnHooc8R.8BloQ4F8UU6YjpirN4QwDpVnpJdtcAG5t','user','ak_f5867e3c6ce63e86','2023-03-23 10:14:00',NULL);

