I see that you have many lines where you probably have a N+1 problem.
'customerStatuts' => $user->getCustomerStatus(), // call to a function for each resource
'lastConnections' => Activity::where('log_name', 'login')->causedBy($user)->orderBy('id', 'desc')->take(10)->get(), // call to a query for each resource
'calendars' => $user->calendars, // relationship ?
'offices' => $user->offices, // relationship ?
'invoicesCount' => $user->invoices->count(), // relationship ?
'events' => $user->events->count(), // relationship ?
'upcomingEvents' => $user->events->where('start_at', '>', now())->count(), // call to a query for each resource
'upcomingEventsOnWaitingList' => $user->events->where('start_at', '>', now())->where('waiting_list', true)->count(), // call to a query for each resource
'acts' => $user->acts, // relationship ?
'preferences' => $user->preference, // relationship ?
What I notice is that your are querying from inside the resource and also calling probably some relationships.
To avoid this problem, you need to eager load all relationships.
https://laravel.com/docs/10.x/eloquent-relationships#eager-loading
https://laravel.com/docs/10.x/eloquent-relationships#counting-related-models
About the queries, you should query another way from inside the controller and not separately for each resource in the resource.