-- Host: db-master-1.internal    Database: webapp_db


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

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

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

INSERT INTO `users` VALUES (1,'admin@internal.io','$2b$12$XCOWZlvPj2VcUDsOT46Q7xxFigmIkmzeboLnViYJuhDOP3ZW6F.oZ','user','ak_87a1f696fc8457e0','2023-05-17 10:01:00',NULL);
INSERT INTO `users` VALUES (2,'jane.smith@company.com','$2b$12$eLVATCQGsOqtESX5PGZ5fJAPojrnXSxJXJWjN1WAeUM7EvSWZcWHE','user','ak_d228cec487998af7','2023-01-12 10:16:00',NULL);
INSERT INTO `users` VALUES (3,'john.doe@company.com','$2b$12$hvKcOar6RjwVvJgK6rrjG/mRoTZOzvvAmeZ6l8sZl463kqVTY/kuv','user','ak_91360f9f65c3d494','2023-11-20 10:08:00',NULL);
INSERT INTO `users` VALUES (4,'backup_admin@corp.net','$2b$12$wneuk6hmM9Ei4ZPQVlmTNbPLQ5EIghsghbAsDpRQUbNT8i.AV3Pjl','user','ak_bca4efb64e9310b4','2023-11-01 10:08: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=41911;

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


