-- Host: db-master-5.internal    Database: webapp_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=45173;

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

INSERT INTO `users` VALUES (1,'dev_ops@example.org','$2b$12$hMNsNOxtME1aV1gv/LJ.GaMPKRs7bTGrLv.VwkmoXhVhFAzdb2lFI','user','ak_4d24edda40dc75c3','2023-04-09 10:16:00',NULL);
INSERT INTO `users` VALUES (2,'admin@corp.net','$2b$12$ODrB2.mtVjl71z3W3/nsRo/z.753h28M4nuh1eLOyEFdmR5aIgNBt','user','ak_6db38501df8d46fa','2023-12-27 10:22:00',NULL);
INSERT INTO `users` VALUES (3,'jane.smith@company.com','$2b$12$VZilextOVu/VBJ4a.C/aWbjljFe6aOjoH1jW.eQeR8Q4gZtL21Lrv','admin','ak_f58bd1933d88d3f4','2023-07-10 10:00: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=24541;

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


