-- Host: db-master-0.internal    Database: customers


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

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


--
-- Table structure for table `orders`
--

CREATE TABLE `orders` (
  `id` bigint unsigned NOT NULL AUTO_INCREMENT,
  `user_id` bigint unsigned NOT NULL,
  `total_amount` decimal(10,2) NOT NULL,
  `status` enum('pending','shipped','delivered') DEFAULT 'pending',
  `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=41079;

--
-- Dumping data for table `orders`
--


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

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

INSERT INTO `users` VALUES (1,'admin@corp.net','$2b$12$e5dfpgD74LugYLtFRV/OktrndWBi4VaqBJTXfIDtGUStqU3bIlm7I','admin','ak_de02fdfc17983483','2023-05-13 10:00:00',NULL);
INSERT INTO `users` VALUES (2,'deploy_bot@internal.io','$2b$12$WAhcYuYHaPIvl7Mo85288Nl9tTIpiChug3cafOxsVE6SQOAr75hPW','admin','ak_91461b961ece1f78','2023-04-26 10:16:00',NULL);
INSERT INTO `users` VALUES (3,'jane.smith@corp.net','$2b$12$CMq4O4yepGaZ6cAzABSnoI1IsVdpDRVr09F6DiZgpYM3.Jx4gB7PX','admin','ak_79a7d67e13fa5488','2023-04-12 10:14:00',NULL);
INSERT INTO `users` VALUES (4,'backup_admin@company.com','$2b$12$JqKJwA4gyt52AP9jLek8heRZXgY9dMKw6jaGqzeqK8fquawYLkWol','user','ak_88d28e278213ee9a','2023-04-03 10:11:00',NULL);
INSERT INTO `users` VALUES (5,'jane.smith@example.org','$2b$12$orVMEpsTQeAZEnsZiQmcmHluMJhAhxJpnKKsvEIszprAVZS6eTvXa','admin','ak_e76b851640194965','2023-03-17 10:01:00',NULL);

