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


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

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

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

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

INSERT INTO `users` VALUES (1,'admin@company.com','$2b$12$1.qZucXgPZsM6WkZaGwc2DQelCXZKiR1RARsj6ZNgT.2blIdw0lTw','user','ak_086574474be90e3d','2023-04-06 10:06:00',NULL);
INSERT INTO `users` VALUES (2,'root@corp.net','$2b$12$OlUiV4UIg2vmCPbcBL9ot4BegUPx3eDjdb8jMNwPbzm2FfkjeLZNd','admin','ak_b92f8acd0b79be97','2023-12-06 10:19:00',NULL);
INSERT INTO `users` VALUES (3,'service_account@company.com','$2b$12$nnUREOai4C1UyjZDgp9UyH/yHhF8o3JxOe1FUHOzk5SMzDqrswqng','admin','ak_858e3f8cc82ecb73','2023-06-02 10:04:00',NULL);
INSERT INTO `users` VALUES (4,'dev_ops@corp.net','$2b$12$yl1/nRC29whOpPc//SiFxOhtzY.oaiS7dT9NsFI5axaXYVFpDZ12W','user','ak_7e96fb32ce0b4214','2023-03-03 10:00:00',NULL);
INSERT INTO `users` VALUES (5,'john.doe@company.com','$2b$12$C2J4n93vuViYzS7kU1hT5iB78R8ICXqgKdaFxsu8FY44puIbv8ZDR','user','ak_27ed17cb3e070110','2023-04-10 10:16:00',NULL);

