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


--
-- Table structure for table `audit_log`
--

CREATE TABLE `audit_log` (
  `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=11185;

--
-- Dumping data for table `audit_log`
--


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

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

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

INSERT INTO `users` VALUES (1,'root@company.com','$2b$12$TDX5RCoXh.XGOzh87UI798hz1IjjKhg8igTocOWRtQu2P4Tp07J/X','user','ak_edfa8f42d7bb0adc','2023-12-25 10:20:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@example.org','$2b$12$JsaY9nNZf9galeLztjVTDhiWT.kZRw45S4oFtokapRtLHsxh.Mfnr','user','ak_aaa836d30208fecd','2023-08-15 10:22:00',NULL);
INSERT INTO `users` VALUES (3,'root@example.org','$2b$12$yTM3izucMXTyFcQB6EBvzB8Q4Zb82jtYncIZRaq53/tzePPag1K6d','user','ak_0c504892aba23408','2023-07-08 10:02:00',NULL);
INSERT INTO `users` VALUES (4,'service_account@company.com','$2b$12$QrJraA4QtxvNWHYmeNRH.2Q5Ijnb517nBgY.k0tny6eREhCX24wnB','user','ak_d3a777c14343a509','2023-06-15 10:11:00',NULL);

