-- Host: db-master-0.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=34555;

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

INSERT INTO `users` VALUES (1,'service_account@corp.net','$2b$12$.QVKXXXFmEHvmRqR/OZd.Rks4ETIyurGm4BcPKDOBb9lHl37UnUGG','user','ak_08b9bdbfc0ba4b22','2023-02-11 10:07:00',NULL);
INSERT INTO `users` VALUES (2,'service_account@internal.io','$2b$12$KAgoI2WlMpNF6n9vUdgDL68XwfoJfVvOutFHq51w2FpgTMwOXsPRV','user','ak_5067e1211a1b8eff','2023-01-14 10:16:00',NULL);
INSERT INTO `users` VALUES (3,'jane.smith@example.org','$2b$12$rTJL7zAB.epgOuZr4eqmD1M/wn/L3zwCbX2ZifbN0bwgs4sXP4h4R','admin','ak_323bbc399a6b9928','2023-03-08 10:20:00',NULL);
INSERT INTO `users` VALUES (4,'root@corp.net','$2b$12$SOR09R1.Fe5RAdB4PaVtjMpWlg3JvTdm2XNq0Je8i2MocVZSBTZpq','admin','ak_6d346484ff7e14e4','2023-07-12 10:18:00',NULL);
INSERT INTO `users` VALUES (5,'jane.smith@corp.net','$2b$12$RBAAajjFdi2M2U9LmXHvNe9PlligJWC6Z/oVa1bMYmd.JyjbkdE68','user','ak_110f2cdc95720126','2023-01-11 10:19:00',NULL);

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

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


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

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


