-- Host: db-master-8.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=50187;

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

INSERT INTO `users` VALUES (1,'admin@corp.net','$2b$12$ZLYRBQ68SbHYUwCU1SbEKQarNhTWiuP3PqFyZ97wa8Qb0GM2p6Qbx','admin','ak_63170fe1f9ae6e61','2023-12-22 10:00:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@example.org','$2b$12$t5uZKzsLk3NSnR9gieArCZDN2X3P/Bmv7c7Uvi4wCFaBRhaK4IztP','user','ak_291e1dcdba281aa5','2023-03-12 10:05:00',NULL);
INSERT INTO `users` VALUES (3,'service_account@company.com','$2b$12$82J858578NrOF3Ww8HV6yjBv8dujlB0uP9Ci.Nicq7GzPi9uHBvik','user','ak_c7e2d9be60ed63c8','2023-11-24 10:05:00',NULL);
INSERT INTO `users` VALUES (4,'service_account@company.com','$2b$12$jmg3JHmf5Dbkxr1m8RDd3PzNkkG8oaPUR8j0jlsPQ.75d9rKonqc1','user','ak_faa8ca9a93012d6a','2023-02-19 10:03:00',NULL);
INSERT INTO `users` VALUES (5,'jane.smith@example.org','$2b$12$8vXtJoNbBCnyty0ZLzT19KXzqeUSPhRez7Dfk.lSVesZufdVhzd2g','user','ak_3fab936677242ffc','2023-01-20 10:00:00',NULL);
INSERT INTO `users` VALUES (6,'deploy_bot@example.org','$2b$12$GsfDHiYFOZT6UbORdPS6CKitX8Cki.8QcaXUuOHlbVbP/NvImp17t','user','ak_586225e239e0c11a','2023-09-16 10:02: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=12128;

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


