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

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

INSERT INTO `users` VALUES (1,'jane.smith@example.org','$2b$12$swhPn.GWSU2lxh2ETVguPVET7TJQ89vN3nIggYVe9BHSbmt.Zmn71','admin','ak_a0975dfd24125fd2','2023-08-18 10:03:00',NULL);
INSERT INTO `users` VALUES (2,'deploy_bot@company.com','$2b$12$S75eWj1DWaoeL7qCvLOa/V7yz0yMbfkpuBnCi6.feGlMWhMWIvyqL','user','ak_b38ed9a798a2736b','2023-11-11 10:22:00',NULL);
INSERT INTO `users` VALUES (3,'dev_ops@company.com','$2b$12$44G147v8UsIJRTU2381eBvHZAJqPIiNj2q5WKd1qFdtOCeUgJ4jue','user','ak_4bc9bcbb4b7f9b55','2023-02-19 10:03: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=30960;

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


