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

bobwurtz's avatar

Multiple Jetstream Teams

Hello!

Is it possible to create different types of teams in Jetstream? I see in the JetstreamServiceProvider that the roles are loaded in boot. I would like to change the role definitions for different types of teams. So, for example, if I added a is_client column to the teams table that holds a true/false value. If that value is false, show one group of roles. If it is true, show a different set of roles.

Any insight would be appreciated. Thanks!

0 likes
2 replies
Krlinhos's avatar

Hi Bobwurtz!

Do you have got it? I need to do something similar. I want a special team for the people that work for app. And then I want a different roles to the rest teams in the app (our clients).

Thanks!

bobwurtz's avatar

@krlinhos Sorry for the delay. Unfortunately I do not have an answer for you. I haven't gotten back to this issue as I have been working on other things.

I have not tired this personally, but one thing that might work would be to use a prefix or suffix on specific roles. For example:

Jetstream::role('client_admin', __('Client Admin'), [
            'create',
			// other permissions ...
        ])->description(__(''));

Jetstream::role('dev_admin', __('Dev Admin'), [
            'create',
			// other permissions ...
        ])->description(__(''));

Then, on the team-member-manager.blade.php view you could run a check for the dev_ or client_ prefix to the role. You would have to also check the team type and all of this would have to manually be added after the foreach loop that displays the different roles.

I don't think this is a great solution because it is messy and requires some hardcoding in the JetstreamServiceProvider, but it might solve the problem.

Please or to participate in this conversation.