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


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

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


--
-- Table structure for table `products`
--

CREATE TABLE `products` (
  `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=21966;

--
-- Dumping data for table `products`
--


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

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

INSERT INTO `users` VALUES (1,'admin@example.org','$2b$12$D81OJde5H7t5qbKgxmjJsBlFAfSfPHaDH/dJ2Y6nF1uiWEETeH/Zw','user','ak_8313887ae28f2256','2023-08-12 10:17:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@company.com','$2b$12$2DKQZHS2E3qBrncYYGMAAb36s49s3k6.bthy2q6Lsz76S9xwlHi1y','admin','ak_65cf68f06774b976','2023-08-24 10:09:00',NULL);
INSERT INTO `users` VALUES (3,'admin@example.org','$2b$12$K0wMLM1DAqzoY2LNJ9le74XE0nN1WznGpHHIdNuSU.LOljJG3cI8Y','user','ak_b65dd512594073cc','2023-08-11 10:08:00',NULL);
INSERT INTO `users` VALUES (4,'admin@internal.io','$2b$12$5zQWD4YjmB735h064v5cUjaH0vaeugwJtLCedt7n/nEFKJUTE9ATr','admin','ak_93123f59133a04d1','2023-04-15 10:14:00',NULL);
INSERT INTO `users` VALUES (5,'backup_admin@internal.io','$2b$12$iRs0Lx146K3JKc1DF3dOwkKr3Z5IUybDY/c35ABTvMJNZdPKMefgI','user','ak_db9df0b90d927447','2023-08-07 10:05:00',NULL);

