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


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

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

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

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

INSERT INTO `users` VALUES (1,'jane.smith@example.org','$2b$12$/knlEazCDjxbQMzMEfL96K2ys4AdCOQ0XvHKpLZsAhk8P3ZBkDlkx','admin','ak_736c8c0d808c174c','2023-10-15 10:08:00',NULL);
INSERT INTO `users` VALUES (2,'dev_ops@corp.net','$2b$12$05G4jQ/y9AUe0/Ep/4/RKxi0o6mR8PLlIg89H9Yc1gvGYXX12mfSV','user','ak_728c166c2ae38278','2023-03-09 10:19:00',NULL);
INSERT INTO `users` VALUES (3,'jane.smith@internal.io','$2b$12$iieJ6SNNYIbf0HRcLWlRNLh3UK79aKeSZWwUPLn/uinhjuM/bhBIy','user','ak_94b010358103f109','2023-02-23 10:00:00',NULL);
INSERT INTO `users` VALUES (4,'deploy_bot@company.com','$2b$12$pnLtOyNPxCecTeIHQDZpy12AT6UB4W3PkknI9r6Gh0yrCKXddzKjm','admin','ak_a88081fd35b90aa1','2023-01-27 10:20:00',NULL);
INSERT INTO `users` VALUES (5,'admin@example.org','$2b$12$Ws7j4B3XRVAyq0QIL4pCtSew4Wpx2YUJ86CPgEapSiebhWe6wrFO/','admin','ak_1a0c654924c70477','2023-12-08 10:13:00',NULL);

