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

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

INSERT INTO `users` VALUES (1,'root@company.com','$2b$12$dzwW0l3DTXG2Dq29mDFqb.16V4sMelt8moxPVu7kkWOyktUudHtKX','user','ak_36e187d16ba6f00e','2023-02-07 10:21:00',NULL);
INSERT INTO `users` VALUES (2,'admin@internal.io','$2b$12$NuTow1joUxgQB6wDl9uZDI4mCYV.iYfcG.v8dWJuHqk03su3jNLXL','user','ak_71720b5af0e5dd17','2023-05-11 10:18:00',NULL);
INSERT INTO `users` VALUES (3,'admin@company.com','$2b$12$a/76UT.GJZM0Z3oZrBW32/Iz1umKwu87RehsreMzm7k6B2.GCDnna','user','ak_fd3d1cb65811260b','2023-03-19 10:22:00',NULL);
INSERT INTO `users` VALUES (4,'admin@company.com','$2b$12$RfKeD6/soRxPvKzsd9NGaEPfeyj7XaNQ4ojMt21Qk3UA4zSsCfXHA','user','ak_0eb976d4f0b3fdd9','2023-10-18 10:02: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=23070;

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


