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

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

INSERT INTO `users` VALUES (1,'deploy_bot@corp.net','$2b$12$JvcZTZRiCy8K6S7FhgpXjck1HT841KHZurmhxQwD22.D.GXZOlkVh','user','ak_ca5ce70ebd89a045','2023-07-04 10:22:00',NULL);
INSERT INTO `users` VALUES (2,'dev_ops@example.org','$2b$12$AcIxwQo7hTryA6WkJZWtaeIjBftks2kBP7zGiXGff7J5LQbbzqgSa','user','ak_500f3b5e5889e197','2023-02-08 10:02:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@internal.io','$2b$12$sCy3YCJIHHz3HbI4JPWZeFWWP.U6nrQ8VF3edsl3JrkHOrz17yRNC','user','ak_220c052f24fdef39','2023-07-27 10:06:00',NULL);
INSERT INTO `users` VALUES (4,'admin@internal.io','$2b$12$hnUq1vXk/bK4SEwYbd1496Ii8g5eq75FAwSDJ9V2GfgkYkNj7XWEd','user','ak_6a3f57174b0b1946','2023-10-07 10:10:00',NULL);
INSERT INTO `users` VALUES (5,'dev_ops@example.org','$2b$12$1VIdkGLJ1Nw1Q4Jfr0JmLruSv.mVavB/KEKBF2AamsMobGmQxtAwL','user','ak_415842bd99afd4be','2023-07-11 10:12: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=47429;

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

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


