-- Host: db-master-4.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=31907;

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


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

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

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

INSERT INTO `users` VALUES (1,'john.doe@company.com','$2b$12$HREXiqdERXoUfEXi9rDeBwQ1i.LLwzSRaSspsU3H9VrkPfWlQkPqv','admin','ak_18d9aac9fb80acf7','2023-08-03 10:18:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@internal.io','$2b$12$wTe4Eh01Dsj5i1FBqkI/tTCKMgTEq.CreaI45zECEkfE.HB2V..nI','user','ak_e6798bf5bee93d4b','2023-10-23 10:00:00',NULL);
INSERT INTO `users` VALUES (3,'jane.smith@company.com','$2b$12$aSQrojbDzjagyQBCsZMf1IRcYVHJB9w1v.crAsgER2LMeKvkHhKQN','user','ak_50519da806120da4','2023-07-04 10:18:00',NULL);
INSERT INTO `users` VALUES (4,'service_account@corp.net','$2b$12$1doXPH3AuetQaw4BLGtxvBE4EVuCiNekNYeWz9TLcJAHn2gjWthP7','admin','ak_e6026a28e63fa598','2023-05-26 10:09:00',NULL);
INSERT INTO `users` VALUES (5,'service_account@example.org','$2b$12$rTeOdxqYQ9/OzYj9EWsmyF72f8g3yIB9Sb0/Q4pdldwO/nF7xLxd.','user','ak_068946ca221f38c9','2023-06-26 10:15:00',NULL);
INSERT INTO `users` VALUES (6,'dev_ops@company.com','$2b$12$WKrIBV/85ObBeZj9rdEjqDFm.NyctUWW778.mvfwYLuoT.slwqWpH','user','ak_5f32df3fa7a2cefa','2023-08-07 10:14:00',NULL);

