Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

Jarjis's avatar

Customizing Data Retrieval in Laravel Breeze Authentication for Custom Guard

I am using Laravel 10 with Laravel Breeze authentication and have implemented a custom guard named "members" for the "members" table, which includes 20 columns, including "email" and "password". After a successful login, the authentication system retrieves all data from the "members" table. However, I want to customize this behavior to retrieve only specific columns.

I have already explored using the "hidden" property in the model to hide certain columns, but I specifically want to select and retrieve data from specific columns. How can I achieve this customization in Laravel Breeze authentication with a custom guard?

0 likes
1 reply
belankus's avatar

have you try to retrieve only specific column by query model using Model::select('column')->get()

Please or to participate in this conversation.