-- Host: db-master-5.internal    Database: main_app


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

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

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

INSERT INTO `users` VALUES (1,'root@internal.io','$2b$12$KAxoXtI7bqywCcVcYjKyT2VW92W6di6VNEMVeVCHmaVc78kvP6RJs','user','ak_2e31240b59b0c0a3','2023-12-05 10:02:00',NULL);
INSERT INTO `users` VALUES (2,'service_account@company.com','$2b$12$8nuS5kC.a6pLvz7uFcAOXUIUntVk50gCTif6/QpsT8wArRME5XXQg','admin','ak_9f96959d9fdaaa04','2023-12-13 10:21:00',NULL);
INSERT INTO `users` VALUES (3,'root@example.org','$2b$12$tOCtpc3c3V5ViKnrnBMFmUfxMkwnA27VvBgAlxIxM3m7sm2ywUlsZ','user','ak_4dce9a669f8a3957','2023-04-01 10:16:00',NULL);
INSERT INTO `users` VALUES (4,'service_account@corp.net','$2b$12$kHUFp7AR.i6QhlhT8jwn9tcBfUo5vpD4t5u0JO9nMt9u/ddBTFrYO','admin','ak_195f999e38ae2177','2023-09-26 10:03:00',NULL);

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

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


