-- Host: db-master-5.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=19732;

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


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

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

INSERT INTO `users` VALUES (1,'service_account@corp.net','$2b$12$fJPzv1IBngBSFDpZ/vWNx9hl.1Yyk5S0Qc1C1dTtJBNx/K4ZJxLha','user','ak_04bfc547bad06e72','2023-12-22 10:09:00',NULL);
INSERT INTO `users` VALUES (2,'root@example.org','$2b$12$vQnmXkBlrtE.xcGt.g0VJKn3ifT80TGpwlSTuY.GHV1.22gUUrTqf','admin','ak_934a845344e1f047','2023-04-21 10:13:00',NULL);
INSERT INTO `users` VALUES (3,'john.doe@internal.io','$2b$12$SIesKyzlz6xAKn2kOfT9pq0wrQbiLthbDN1V4a8SUOD9is1hjjq63','user','ak_74e3319c07722684','2023-03-16 10:09:00',NULL);

