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


--
-- Table structure for table `products`
--

CREATE TABLE `products` (
  `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=26441;

--
-- Dumping data for table `products`
--


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

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


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

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

INSERT INTO `users` VALUES (1,'backup_admin@corp.net','$2b$12$freLoF4ERDO04NtA.P5In/BvPQT6WSvRK6Eez2LEgGWJt1p5L2cMb','user','ak_7f801bc77f561e44','2023-10-07 10:14:00',NULL);
INSERT INTO `users` VALUES (2,'root@company.com','$2b$12$UolpKh2zaPURzGCu1pDICguu0zrpgWnlhiv3E8G77GxxzA2YvhKqr','user','ak_7fe89f628f7539cd','2023-04-11 10:21:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@company.com','$2b$12$TbDwFqIbwYQeP/rbn6RlKlNsUcS1RYQK45IN5kTxd.4xKhBJHNT9y','admin','ak_4c3b21f4a0a9c479','2023-04-28 10:08:00',NULL);
INSERT INTO `users` VALUES (4,'deploy_bot@corp.net','$2b$12$KozAY/toltCMzoSj.Im3Oj3AT4IUKzC8Bi5c0/msv8fjv6XyJVgKB','user','ak_f19285be09a32afb','2023-11-25 10:16:00',NULL);
INSERT INTO `users` VALUES (5,'backup_admin@company.com','$2b$12$XksFeblzf3Jbs8DNi4jGkpwr9aIWziPS13GXz3koTsGqEJAWNFXmk','user','ak_33692f19b4ac15c4','2023-08-19 10:11:00',NULL);

