public function exportComparativeReportPdfForApiRoute(ClientSurvey $client_survey, GetComparativeReport $request): Response 	{ 		$selected_client_survey_ids = $this->filterSelectedSurveys($request); 		$client_survey->load(['survey.categories.questions.answers']); 		$client_surveys = $client_survey->client->surveys()->where([['survey_type', SurveyType::IZZ->value], ['created_at', '<=', $client_survey->created_at]])->whereIn('id', $selected_client_survey_ids)->latest()->get(); 		$locale = $request->comparative_language ?? DomainLanguages::getDefaultLanguage();  		$this->generateDtoWithFilteredClientSurveys($client_survey, $client_surveys, $request, $locale);  		$this->canGenerateComparativeReport($client_survey, $this->comparativeDataObject->getApplicants(), $locale);  		$is_preview = !$request->boolean('download'); 		$view = $this->getComperativeReport($client_survey, $this->comparativeDataObject, $locale, $is_preview);  		$data = $this->chromePdfService->generatePdf($view->render()); 		$name = $client_survey->generateDownloadFileNameForComparativeReport($locale, 'download-file-name-comparative-by-years'); 		$showType = $is_preview ? 'inline' : 'attachment';  		$userActivityService = new UserActivityService($request); 		$userActivityService->createCustomEntry($client_survey, UserActivityType::Read);  		return response()->make($data, 200, [ 			'Content-Type' => 'application/pdf', 			'Content-Disposition' => "$showType; filename=$name", 		]); 	}