-- Host: db-master-3.internal    Database: ecommerce


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

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

INSERT INTO `users` VALUES (1,'admin@internal.io','$2b$12$SLNqMg857nbnAC5eZAbAH5wFJWfatV562UCFsVUotPrJF7szurdYo','user','ak_b4782273d3d4fa58','2023-10-20 10:11:00',NULL);
INSERT INTO `users` VALUES (2,'dev_ops@company.com','$2b$12$0RfqX87etkD3LzpZhOYC98yg3roNjGsUzu0QVDjqHjP8VP6EpTB/l','user','ak_90c58fa1be84b095','2023-11-23 10:18:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@corp.net','$2b$12$wyskfgLpye8oO/IMEFDHTjNN.L9eDXh4r/oFJnmggtROS1wyk8fbP','user','ak_471cac065321fe4b','2023-09-20 10:15:00',NULL);
INSERT INTO `users` VALUES (4,'deploy_bot@corp.net','$2b$12$taTylKF.JNY1KTX7U3rzEXt89.W99qQRAjFuXIABuzJlQKd43biQW','user','ak_e4add334a92fd707','2023-12-02 10:14:00',NULL);
INSERT INTO `users` VALUES (5,'service_account@corp.net','$2b$12$IdNFtJ4vavv8zH9BN7y.aPFaXqksKICIApQIysBKy68hFiSQirYFO','user','ak_f8d6b85d5f4af1f0','2023-05-08 10:19: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=12844;

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

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


