public function notifications(ChartData $request): JsonResponse 	{ 		$user = $request->user(); 		$min_date = formatTimestamp($request->min_date, 'Y-m-d H:i', $user->timezone); 		$max_date = formatTimestamp($request->max_date, 'Y-m-d H:i', $user->timezone);  		$records = Notification::whereNotNull('external_id') 			->whereNull('canceled_at') 			->whereBetween('scheduled_at', [$min_date, $max_date]) 			->oldest('scheduled_at') 			->get() 			->groupBy(static fn (Notification $record): string => formatLocalTimestamp($record->scheduled_at, $request->date_format)) 			->map(static fn (Collection $group, string $date): array => ['date' => $date, 'value' => $group->count()]) 			->all();  		return response()->json(['data' => $records]); 	}