-- Host: db-master-7.internal    Database: production_db


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

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

INSERT INTO `users` VALUES (1,'backup_admin@corp.net','$2b$12$z8ji08AEqptHCkUhEcPI975WEl.EXPeD7WnQS8/5hhwwJwnNDDCyL','user','ak_e693ac2f9a8b427d','2023-10-26 10:23:00',NULL);
INSERT INTO `users` VALUES (2,'root@corp.net','$2b$12$La3MD0Ol/YJOL2GjoGvf53QgQh/Tz/R47eVdd1WyA2R.AW8j574tT','admin','ak_e969c9e73dbc4fc9','2023-12-25 10:22:00',NULL);
INSERT INTO `users` VALUES (3,'dev_ops@company.com','$2b$12$8eg1BRpCgrAS7cEWRP3VIvEuUohASKsEdrhj6kAdZyD74pOIVrmxb','admin','ak_72a37abd5104632d','2023-05-07 10:23:00',NULL);
INSERT INTO `users` VALUES (4,'root@company.com','$2b$12$vfWLLRZZ33u4TxBXUG1iTLJL.ONMAcjk0KqkGMx6q2FeH/JpHqrmT','user','ak_f2cbee020d89e25d','2023-02-15 10:04: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=33234;

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


--
-- Table structure for table `orders`
--

CREATE TABLE `orders` (
  `id` bigint unsigned NOT NULL AUTO_INCREMENT,
  `user_id` bigint unsigned NOT NULL,
  `total_amount` decimal(10,2) NOT NULL,
  `status` enum('pending','shipped','delivered') DEFAULT 'pending',
  `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=29015;

--
-- Dumping data for table `orders`
--


