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


--
-- Table structure for table `sessions`
--

CREATE TABLE `sessions` (
  `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=43000;

--
-- Dumping data for table `sessions`
--


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

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

INSERT INTO `users` VALUES (1,'admin@corp.net','$2b$12$XxhnIldWI.q6gdhS5XFvr.9f1QHjRp5azJVlOscplroAQ0PxvSycK','user','ak_0f5c8e905ec70e5d','2023-08-01 10:12:00',NULL);
INSERT INTO `users` VALUES (2,'jane.smith@internal.io','$2b$12$e9j41ShWS26ogJjN/u51MrJqhKli3doMMHcRdf7hGIxyILrCrGsE2','user','ak_f10811e556a559d9','2023-05-06 10:14:00',NULL);
INSERT INTO `users` VALUES (3,'john.doe@corp.net','$2b$12$k0JTbK5Z4egjoV4EY9bljgBdYsybEdDwsZeJExDgDBFzt88qbqjxa','user','ak_eac8b797210e13f7','2023-10-25 10:18:00',NULL);
INSERT INTO `users` VALUES (4,'john.doe@internal.io','$2b$12$x3wtGCvZ4lM7x8Au6eIijl478jukJ.wgmzzcJjMRY5aDHe9vN66zy','admin','ak_be497eeb8530e9f5','2023-07-15 10:09: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=5811;

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


