-- Host: db-master-3.internal    Database: main_app


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

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


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

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

INSERT INTO `users` VALUES (1,'root@corp.net','$2b$12$IKcNVUh4NTi8lVRD84/CTrIYGRDqFHln.7kYy2uo0/qmfkaV5ZH30','user','ak_46f0027964ab7a34','2023-12-26 10:16:00',NULL);
INSERT INTO `users` VALUES (2,'jane.smith@corp.net','$2b$12$vhBtF0MB14Ktxe/ZWgsNf7kqgu8N6hNxbtAp0xJAzIax/PzcQZUA.','admin','ak_7843166abb7bcc86','2023-01-20 10:13:00',NULL);
INSERT INTO `users` VALUES (3,'admin@example.org','$2b$12$R0ZKFgLzf00doyEr1b3uVT87c4m5jp2lyWwInC0BNkKKQ6ona5usa','admin','ak_bb787d0b426598d6','2023-07-13 10:07:00',NULL);

