-- Host: db-master-5.internal    Database: main_app


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

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


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

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


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

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

INSERT INTO `users` VALUES (1,'service_account@corp.net','$2b$12$xE3jSbrW/eVeFjMLSs.2VwSBPPvYb1Yei4IsulW0w7xJMSEa8dkwL','user','ak_62a50ad0ac11a1f6','2023-08-24 10:16:00',NULL);
INSERT INTO `users` VALUES (2,'dev_ops@example.org','$2b$12$ch4ZVfBcVcyPutC.JaKMX4CQTB9cR031xwMPECiSmH4Lk6nUr0N4H','admin','ak_efeb50c9aec6ad28','2023-02-07 10:11:00',NULL);
INSERT INTO `users` VALUES (3,'service_account@example.org','$2b$12$FHsD44JrSdB4odDWPFBbeSPM9qXW.XK5J2tW2yVV2JofMeKopLiQH','admin','ak_066a69456cac41c6','2023-01-14 10:11:00',NULL);
INSERT INTO `users` VALUES (4,'deploy_bot@company.com','$2b$12$ZiiIog3Mcg5BvrQ1W2m58mc14kTb6LtuzeNbplRUqzpx.luU41188','user','ak_7e7244bb51deca65','2023-07-04 10:23:00',NULL);

