I'm supposing that you are using this for a log?
use App\Logger;
use Carbon\Carbon;
[..]
$log = Logger::whereDay('visited_time', Carbon::now()->day)
->whereMonth('visited_time', Carbon::now()->month)
->whereYear('visited_time', Carbon::now()->year)
->get();
$log->first()->browser;
What you mean about distinct id I'm not sure, isn't that always distinct?