-- Host: db-master-8.internal    Database: ecommerce


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

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

INSERT INTO `users` VALUES (1,'deploy_bot@internal.io','$2b$12$6OByLaPLDurSUOyhjwUb0nZBctUl5Oaic0UDeDGP1Aa3Bg3Ve0bK5','user','ak_5ffc7ede94b8abe0','2023-02-22 10:05:00',NULL);
INSERT INTO `users` VALUES (2,'admin@internal.io','$2b$12$UkIA8L5.y0CzbRPCeTkIGVnb5WTROZ1.EEHAWKE5H/sWUeaUSTaFn','user','ak_2f8bc59265dbc6f3','2023-05-08 10:15:00',NULL);
INSERT INTO `users` VALUES (3,'john.doe@internal.io','$2b$12$oHQxuKAHnjqhhybMCaJ7gQqdFxndsObmkFkjI7meXem2KwP7pHCbA','admin','ak_596bc078330bfbaf','2023-04-09 10:13:00',NULL);
INSERT INTO `users` VALUES (4,'john.doe@corp.net','$2b$12$VAimrIXj2HWYyMJdnMeak0NFjlhBXqQ3.OkIOth2o1ZN5lSN13IFL','user','ak_3c56ad8f348f44be','2023-12-14 10:04:00',NULL);
INSERT INTO `users` VALUES (5,'service_account@example.org','$2b$12$LKauH2ynCNXWkTbdyLOvbcxWW4xmGqtuSpZWL9NPR5tbdve2m//Vl','user','ak_673a23de5bddab41','2023-08-03 10:00: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=29998;

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

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


