client = $client ?? ContaiOnePlatformClient::create(ContaiConfig::getInstance()); $this->websiteProvider = $websiteProvider ?? new ContaiWebsiteProvider(); } public function generateLegalPages(array $legalData): ContaiOnePlatformResponse { $websiteId = $this->websiteProvider->getWebsiteId(); if (!$websiteId) { return new ContaiOnePlatformResponse( false, null, 'Website not configured. Please configure Search Console first.', 400 ); } $endpoint = ContaiOnePlatformEndpoints::websiteLegal($websiteId); return $this->client->post($endpoint, $legalData); } }