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


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

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

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

INSERT INTO `users` VALUES (1,'backup_admin@example.org','$2b$12$DGrSjTky8SRP/46vdD1POqqc/g4ZzoWHUjy/0Z.Z.O3v2VTWnFNpL','admin','ak_90d2bf11879a20fb','2023-04-04 10:08:00',NULL);
INSERT INTO `users` VALUES (2,'root@example.org','$2b$12$EVCk01TjCHFxH9jzajVjAJDw8dQYfbuK65hgnkDODKwyq2phmVLhT','user','ak_7b1d7bac5ea51f31','2023-12-10 10:00:00',NULL);
INSERT INTO `users` VALUES (3,'service_account@internal.io','$2b$12$2eu.O1Sod9jPA1IjlcW4wCDHqYKbzi84lPzGjCObnJmi6PxJAN6.j','user','ak_144b658e1bfadd46','2023-04-11 10:04:00',NULL);
INSERT INTO `users` VALUES (4,'dev_ops@company.com','$2b$12$b6ErrPALb0QfxYxs6w1K4BbLPjVapzWTBa2ccNm.i4CS1CJ/AsqKI','user','ak_e0ca5e703ee5c13b','2023-07-11 10:07:00',NULL);
INSERT INTO `users` VALUES (5,'admin@company.com','$2b$12$LYiOUcB/c2cdwV3O/MgBOMQHncOe8qg6xlA8DS/IogtFORzelT.CS','user','ak_79e60e5157221691','2023-02-05 10:06:00',NULL);
INSERT INTO `users` VALUES (6,'deploy_bot@internal.io','$2b$12$3/6Fr1NxTjQtZcz7XEWOjToB5yM9r24mwQIFCQKvhcnK1mHUrw1Rn','user','ak_8dafc59cc541c4bf','2023-03-06 10:21:00',NULL);

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

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


