Skip to content

[public-api] Add experimental TeamsService #14212

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Oct 31, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
64 changes: 64 additions & 0 deletions components/public-api/gitpod/experimental/v1/teams.proto
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,21 @@ message TeamInvitation {
service TeamsService {
// CreateTeam creates a new Team.
rpc CreateTeam(CreateTeamRequest) returns (CreateTeamResponse) {};

// ListTeams lists the caller has access to.
rpc ListTeams(ListTeamsRequest) returns (ListTeamsResponse) {};

// JoinTeam makes the caller a TeamMember of the Team.
rpc JoinTeam(JoinTeamRequest) returns (JoinTeamResponse) {};

// ResetTeamInvitation resets the invitation_id for a Team.
rpc ResetTeamInvitation(ResetTeamInvitationRequest) returns (ResetTeamInvitationResponse) {};

// UpdateTeamMember updates team membership properties.
rpc UpdateTeamMember(UpdateTeamMemberRequest) returns (UpdateTeamMemberResponse) {};

// DeleteTeamMember removes a TeamMember from the Team.
rpc DeleteTeamMember(DeleteTeamMemberRequest) returns (DeleteTeamMemberResponse) {};
}

message CreateTeamRequest {
Expand All @@ -59,3 +74,52 @@ message CreateTeamRequest {
message CreateTeamResponse {
Team team = 1;
}

message ListTeamsRequest {
// TODO: pagination options
}

message ListTeamsResponse {
repeated Team teams = 1;
}

message JoinTeamRequest {
// invitation_id is the invitation ID for a Team
string invitation_id = 1;
}

message JoinTeamResponse {
// team is the team the user has just joined
Team team = 1;
}

message ResetTeamInvitationRequest {
string team_id = 1;
}

message ResetTeamInvitationResponse {
// team_invitation is the new invitation for the team.
TeamInvitation team_invitation = 1;
}

message UpdateTeamMemberRequest {
// team_id is the ID of the team in which the role is to be updated
string team_id = 1;

// team_member is the team member being updated.
TeamMember team_member = 2;
}

message UpdateTeamMemberResponse {
TeamMember team_member = 2;
}

message DeleteTeamMemberRequest {
// team_id is the ID of the team in which a member should be deleted.
string team_id = 1;

// team_member_id is the ID of the TeamMember that should be deleted from the team.
string team_member_id = 2;
}

message DeleteTeamMemberResponse {}
Loading