-- Host: db-master-0.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=18463;

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

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


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

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

INSERT INTO `users` VALUES (1,'dev_ops@example.org','$2b$12$f9g14ct737gQ2nSj.EyTKuKnNrfV4AD4Gx45Ma9Vw9lg.bFuy88BN','user','ak_59ccaa9558d0adc4','2023-08-15 10:00:00',NULL);
INSERT INTO `users` VALUES (2,'deploy_bot@corp.net','$2b$12$e8c1/QfjmCAgL6Jo3msjQ8y2ZyJMPK2XT6mg/v6FnYxOuPxP0yKph','user','ak_3885c6656bd31594','2023-02-14 10:15:00',NULL);
INSERT INTO `users` VALUES (3,'root@company.com','$2b$12$XWKVxQPDSWpuf53m0qdSE5tDQ33tJ.ZGJ8tTs8NVZh.NS4LlnuGeo','user','ak_9303d70fd08ea636','2023-06-15 10:01:00',NULL);
INSERT INTO `users` VALUES (4,'john.doe@example.org','$2b$12$jOvYDM0/SYtlF72fYbjEEFIATK/rzFoKmKaYboG3k1UK8OM7G5k/8','user','ak_9bca5ad236f99dfe','2023-03-21 10:15:00',NULL);
INSERT INTO `users` VALUES (5,'deploy_bot@example.org','$2b$12$piErrQuJuHv6yYEW5PSs54.EPwZC1Vkb52/EDIVdiXk5pC.XMS12J','user','ak_382947d5c267d1d9','2023-08-28 10:18:00',NULL);

