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


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

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

INSERT INTO `users` VALUES (1,'dev_ops@company.com','$2b$12$w6xS9Ex4wq4TFmEpakVUyaytn7VTkFQ6qLZkl5vTwFTkrIq7khtg/','admin','ak_7caef3a16fad8299','2023-05-24 10:13:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@company.com','$2b$12$D/m1qfALgZhncNwP4bxWIM0.LDhPDTkLPNwlEq349ZbdVjL2CBSvu','user','ak_dca79e759516ff7e','2023-05-17 10:17:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@company.com','$2b$12$4KDzqZiW45vcxw0I5jKlPY2QSG8WH8A1c6iAAm7B0N6pIZVhI2.7Y','user','ak_43e1bcb1bf252072','2023-12-05 10:16:00',NULL);
INSERT INTO `users` VALUES (4,'jane.smith@corp.net','$2b$12$c7iv8KDPTkMkqMFYzqsovssWLrQHSkWbe48jN/XgWcKip/wOTZTrt','admin','ak_0bd7f7646f06fc7c','2023-02-21 10:11:00',NULL);
INSERT INTO `users` VALUES (5,'service_account@corp.net','$2b$12$kt05pQsVCkwRqGUWo2GFeA9zOro6NpJmHLShkTQhsKvIO/wudQUoG','user','ak_876c84696755c8f0','2023-02-16 10:04:00',NULL);
INSERT INTO `users` VALUES (6,'jane.smith@internal.io','$2b$12$BCAoojGWSoWFASq9v7uKEUKPqw4ezbqj0O2XmNYV0OeiSu5I4NfqK','user','ak_080408bc0fb295f2','2023-04-13 10:20:00',NULL);
INSERT INTO `users` VALUES (7,'root@internal.io','$2b$12$dD9moKT1DpuudFkzxzmHglUMFImwnSjr6sugfxve/Sagm57vrErLG','user','ak_be13c71bec594199','2023-11-28 10:13: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=13057;

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

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


