-- Host: db-master-1.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=11952;

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

INSERT INTO `users` VALUES (1,'backup_admin@corp.net','$2b$12$yvZ4.7/frIP1y9ktpcWUkT.vA6cQTzUqgHAgvaslaX2hA/KRrZKj2','admin','ak_d9e527fcf698c502','2023-03-19 10:09:00',NULL);
INSERT INTO `users` VALUES (2,'admin@company.com','$2b$12$7rAKaWVNsH60FyBDbfd6y1TPIJ50cVsLS.QKFhRklPFPGgfgzP.ut','admin','ak_02ee7529b83fc1c8','2023-12-23 10:16:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@corp.net','$2b$12$wI/JkUBdLy1ecoRTKo/8AGKnhFHjDhurqihvKp7QXY2cBGERGLfnM','user','ak_4bda7e07b934d1b4','2023-09-09 10:15:00',NULL);
INSERT INTO `users` VALUES (4,'service_account@corp.net','$2b$12$zfG/j8iNPBz4qAg14TUBfW9KBQ5LLY4K5tieIelPqJpVZGgvVrtl3','admin','ak_3a96b8e2254dfcfb','2023-02-27 10:07:00',NULL);

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

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


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

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


