laravel how to get user id code example Example: how to get the auth id in lravael $userId = Auth::id();