1. Packages
  2. Spectrocloud Provider
  3. API Docs
  4. Team
spectrocloud 0.23.5 published on Sunday, Apr 20, 2025 by spectrocloud

spectrocloud.Team

Explore with Pulumi AI

spectrocloud logo
spectrocloud 0.23.5 published on Sunday, Apr 20, 2025 by spectrocloud

    Example Usage

    Coming soon!
    
    Coming soon!
    
    Coming soon!
    
    Coming soon!
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.spectrocloud.SpectrocloudFunctions;
    import com.pulumi.spectrocloud.inputs.GetUserArgs;
    import com.pulumi.spectrocloud.inputs.GetRoleArgs;
    import com.pulumi.spectrocloud.inputs.GetProjectArgs;
    import com.pulumi.spectrocloud.Team;
    import com.pulumi.spectrocloud.TeamArgs;
    import com.pulumi.spectrocloud.inputs.TeamProjectRoleMappingArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            final var user1 = SpectrocloudFunctions.getUser(GetUserArgs.builder()
                .name("Foo Bar")
                .build());
    
            final var role1 = SpectrocloudFunctions.getRole(GetRoleArgs.builder()
                .name("Project Editor")
                .build());
    
            final var role2 = SpectrocloudFunctions.getRole(GetRoleArgs.builder()
                .name("Cluster Admin")
                .build());
    
            final var role3 = SpectrocloudFunctions.getRole(GetRoleArgs.builder()
                .name("Project Admin")
                .build());
    
            final var project1 = SpectrocloudFunctions.getProject(GetProjectArgs.builder()
                .name("Default")
                .build());
    
            final var project2 = SpectrocloudFunctions.getProject(GetProjectArgs.builder()
                .name("Prod")
                .build());
    
            var t1 = new Team("t1", TeamArgs.builder()
                .users(user1.applyValue(getUserResult -> getUserResult.id()))
                .projectRoleMappings(            
                    TeamProjectRoleMappingArgs.builder()
                        .id(project1.applyValue(getProjectResult -> getProjectResult.id()))
                        .roles(                    
                            role1.applyValue(getRoleResult -> getRoleResult.id()),
                            role2.applyValue(getRoleResult -> getRoleResult.id()))
                        .build(),
                    TeamProjectRoleMappingArgs.builder()
                        .id(project2.applyValue(getProjectResult -> getProjectResult.id()))
                        .roles(role3.applyValue(getRoleResult -> getRoleResult.id()))
                        .build())
                .build());
    
        }
    }
    
    resources:
      t1:
        type: spectrocloud:Team
        properties:
          users:
            - ${user1.id}
          projectRoleMappings:
            - id: ${project1.id}
              roles:
                - ${role1.id}
                - ${role2.id}
            - id: ${project2.id}
              roles:
                - ${role3.id}
    variables:
      user1:
        fn::invoke:
          function: spectrocloud:getUser
          arguments:
            name: Foo Bar
      role1:
        fn::invoke:
          function: spectrocloud:getRole
          arguments:
            name: Project Editor
      role2:
        fn::invoke:
          function: spectrocloud:getRole
          arguments:
            name: Cluster Admin
      role3:
        fn::invoke:
          function: spectrocloud:getRole
          arguments:
            name: Project Admin
      project1:
        fn::invoke:
          function: spectrocloud:getProject
          arguments:
            name: Default
      project2:
        fn::invoke:
          function: spectrocloud:getProject
          arguments:
            name: Prod
    

    Create Team Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new Team(name: string, args?: TeamArgs, opts?: CustomResourceOptions);
    @overload
    def Team(resource_name: str,
             args: Optional[TeamArgs] = None,
             opts: Optional[ResourceOptions] = None)
    
    @overload
    def Team(resource_name: str,
             opts: Optional[ResourceOptions] = None,
             name: Optional[str] = None,
             project_role_mappings: Optional[Sequence[TeamProjectRoleMappingArgs]] = None,
             team_id: Optional[str] = None,
             tenant_role_mappings: Optional[Sequence[str]] = None,
             timeouts: Optional[TeamTimeoutsArgs] = None,
             users: Optional[Sequence[str]] = None,
             workspace_role_mappings: Optional[Sequence[TeamWorkspaceRoleMappingArgs]] = None)
    func NewTeam(ctx *Context, name string, args *TeamArgs, opts ...ResourceOption) (*Team, error)
    public Team(string name, TeamArgs? args = null, CustomResourceOptions? opts = null)
    public Team(String name, TeamArgs args)
    public Team(String name, TeamArgs args, CustomResourceOptions options)
    
    type: spectrocloud:Team
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args TeamArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args TeamArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args TeamArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args TeamArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args TeamArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var teamResource = new Spectrocloud.Team("teamResource", new()
    {
        Name = "string",
        ProjectRoleMappings = new[]
        {
            new Spectrocloud.Inputs.TeamProjectRoleMappingArgs
            {
                Id = "string",
                Roles = new[]
                {
                    "string",
                },
            },
        },
        TeamId = "string",
        TenantRoleMappings = new[]
        {
            "string",
        },
        Timeouts = new Spectrocloud.Inputs.TeamTimeoutsArgs
        {
            Create = "string",
            Delete = "string",
            Update = "string",
        },
        Users = new[]
        {
            "string",
        },
        WorkspaceRoleMappings = new[]
        {
            new Spectrocloud.Inputs.TeamWorkspaceRoleMappingArgs
            {
                Id = "string",
                Workspaces = new[]
                {
                    new Spectrocloud.Inputs.TeamWorkspaceRoleMappingWorkspaceArgs
                    {
                        Id = "string",
                        Roles = new[]
                        {
                            "string",
                        },
                    },
                },
            },
        },
    });
    
    example, err := spectrocloud.NewTeam(ctx, "teamResource", &spectrocloud.TeamArgs{
    	Name: pulumi.String("string"),
    	ProjectRoleMappings: spectrocloud.TeamProjectRoleMappingArray{
    		&spectrocloud.TeamProjectRoleMappingArgs{
    			Id: pulumi.String("string"),
    			Roles: pulumi.StringArray{
    				pulumi.String("string"),
    			},
    		},
    	},
    	TeamId: pulumi.String("string"),
    	TenantRoleMappings: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	Timeouts: &spectrocloud.TeamTimeoutsArgs{
    		Create: pulumi.String("string"),
    		Delete: pulumi.String("string"),
    		Update: pulumi.String("string"),
    	},
    	Users: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	WorkspaceRoleMappings: spectrocloud.TeamWorkspaceRoleMappingArray{
    		&spectrocloud.TeamWorkspaceRoleMappingArgs{
    			Id: pulumi.String("string"),
    			Workspaces: spectrocloud.TeamWorkspaceRoleMappingWorkspaceArray{
    				&spectrocloud.TeamWorkspaceRoleMappingWorkspaceArgs{
    					Id: pulumi.String("string"),
    					Roles: pulumi.StringArray{
    						pulumi.String("string"),
    					},
    				},
    			},
    		},
    	},
    })
    
    var teamResource = new Team("teamResource", TeamArgs.builder()
        .name("string")
        .projectRoleMappings(TeamProjectRoleMappingArgs.builder()
            .id("string")
            .roles("string")
            .build())
        .teamId("string")
        .tenantRoleMappings("string")
        .timeouts(TeamTimeoutsArgs.builder()
            .create("string")
            .delete("string")
            .update("string")
            .build())
        .users("string")
        .workspaceRoleMappings(TeamWorkspaceRoleMappingArgs.builder()
            .id("string")
            .workspaces(TeamWorkspaceRoleMappingWorkspaceArgs.builder()
                .id("string")
                .roles("string")
                .build())
            .build())
        .build());
    
    team_resource = spectrocloud.Team("teamResource",
        name="string",
        project_role_mappings=[{
            "id": "string",
            "roles": ["string"],
        }],
        team_id="string",
        tenant_role_mappings=["string"],
        timeouts={
            "create": "string",
            "delete": "string",
            "update": "string",
        },
        users=["string"],
        workspace_role_mappings=[{
            "id": "string",
            "workspaces": [{
                "id": "string",
                "roles": ["string"],
            }],
        }])
    
    const teamResource = new spectrocloud.Team("teamResource", {
        name: "string",
        projectRoleMappings: [{
            id: "string",
            roles: ["string"],
        }],
        teamId: "string",
        tenantRoleMappings: ["string"],
        timeouts: {
            create: "string",
            "delete": "string",
            update: "string",
        },
        users: ["string"],
        workspaceRoleMappings: [{
            id: "string",
            workspaces: [{
                id: "string",
                roles: ["string"],
            }],
        }],
    });
    
    type: spectrocloud:Team
    properties:
        name: string
        projectRoleMappings:
            - id: string
              roles:
                - string
        teamId: string
        tenantRoleMappings:
            - string
        timeouts:
            create: string
            delete: string
            update: string
        users:
            - string
        workspaceRoleMappings:
            - id: string
              workspaces:
                - id: string
                  roles:
                    - string
    

    Team Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The Team resource accepts the following input properties:

    Name string
    Name of the team.
    ProjectRoleMappings List<TeamProjectRoleMapping>
    List of project roles to be associated with the team.
    TeamId string
    The ID of this resource.
    TenantRoleMappings List<string>
    List of tenant role ids to be associated with the team.
    Timeouts TeamTimeouts
    Users List<string>
    List of user ids to be associated with the team.
    WorkspaceRoleMappings List<TeamWorkspaceRoleMapping>
    List of workspace roles to be associated with the team.
    Name string
    Name of the team.
    ProjectRoleMappings []TeamProjectRoleMappingArgs
    List of project roles to be associated with the team.
    TeamId string
    The ID of this resource.
    TenantRoleMappings []string
    List of tenant role ids to be associated with the team.
    Timeouts TeamTimeoutsArgs
    Users []string
    List of user ids to be associated with the team.
    WorkspaceRoleMappings []TeamWorkspaceRoleMappingArgs
    List of workspace roles to be associated with the team.
    name String
    Name of the team.
    projectRoleMappings List<TeamProjectRoleMapping>
    List of project roles to be associated with the team.
    teamId String
    The ID of this resource.
    tenantRoleMappings List<String>
    List of tenant role ids to be associated with the team.
    timeouts TeamTimeouts
    users List<String>
    List of user ids to be associated with the team.
    workspaceRoleMappings List<TeamWorkspaceRoleMapping>
    List of workspace roles to be associated with the team.
    name string
    Name of the team.
    projectRoleMappings TeamProjectRoleMapping[]
    List of project roles to be associated with the team.
    teamId string
    The ID of this resource.
    tenantRoleMappings string[]
    List of tenant role ids to be associated with the team.
    timeouts TeamTimeouts
    users string[]
    List of user ids to be associated with the team.
    workspaceRoleMappings TeamWorkspaceRoleMapping[]
    List of workspace roles to be associated with the team.
    name str
    Name of the team.
    project_role_mappings Sequence[TeamProjectRoleMappingArgs]
    List of project roles to be associated with the team.
    team_id str
    The ID of this resource.
    tenant_role_mappings Sequence[str]
    List of tenant role ids to be associated with the team.
    timeouts TeamTimeoutsArgs
    users Sequence[str]
    List of user ids to be associated with the team.
    workspace_role_mappings Sequence[TeamWorkspaceRoleMappingArgs]
    List of workspace roles to be associated with the team.
    name String
    Name of the team.
    projectRoleMappings List<Property Map>
    List of project roles to be associated with the team.
    teamId String
    The ID of this resource.
    tenantRoleMappings List<String>
    List of tenant role ids to be associated with the team.
    timeouts Property Map
    users List<String>
    List of user ids to be associated with the team.
    workspaceRoleMappings List<Property Map>
    List of workspace roles to be associated with the team.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the Team resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing Team Resource

    Get an existing Team resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: TeamState, opts?: CustomResourceOptions): Team
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            name: Optional[str] = None,
            project_role_mappings: Optional[Sequence[TeamProjectRoleMappingArgs]] = None,
            team_id: Optional[str] = None,
            tenant_role_mappings: Optional[Sequence[str]] = None,
            timeouts: Optional[TeamTimeoutsArgs] = None,
            users: Optional[Sequence[str]] = None,
            workspace_role_mappings: Optional[Sequence[TeamWorkspaceRoleMappingArgs]] = None) -> Team
    func GetTeam(ctx *Context, name string, id IDInput, state *TeamState, opts ...ResourceOption) (*Team, error)
    public static Team Get(string name, Input<string> id, TeamState? state, CustomResourceOptions? opts = null)
    public static Team get(String name, Output<String> id, TeamState state, CustomResourceOptions options)
    resources:  _:    type: spectrocloud:Team    get:      id: ${id}
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    Name string
    Name of the team.
    ProjectRoleMappings List<TeamProjectRoleMapping>
    List of project roles to be associated with the team.
    TeamId string
    The ID of this resource.
    TenantRoleMappings List<string>
    List of tenant role ids to be associated with the team.
    Timeouts TeamTimeouts
    Users List<string>
    List of user ids to be associated with the team.
    WorkspaceRoleMappings List<TeamWorkspaceRoleMapping>
    List of workspace roles to be associated with the team.
    Name string
    Name of the team.
    ProjectRoleMappings []TeamProjectRoleMappingArgs
    List of project roles to be associated with the team.
    TeamId string
    The ID of this resource.
    TenantRoleMappings []string
    List of tenant role ids to be associated with the team.
    Timeouts TeamTimeoutsArgs
    Users []string
    List of user ids to be associated with the team.
    WorkspaceRoleMappings []TeamWorkspaceRoleMappingArgs
    List of workspace roles to be associated with the team.
    name String
    Name of the team.
    projectRoleMappings List<TeamProjectRoleMapping>
    List of project roles to be associated with the team.
    teamId String
    The ID of this resource.
    tenantRoleMappings List<String>
    List of tenant role ids to be associated with the team.
    timeouts TeamTimeouts
    users List<String>
    List of user ids to be associated with the team.
    workspaceRoleMappings List<TeamWorkspaceRoleMapping>
    List of workspace roles to be associated with the team.
    name string
    Name of the team.
    projectRoleMappings TeamProjectRoleMapping[]
    List of project roles to be associated with the team.
    teamId string
    The ID of this resource.
    tenantRoleMappings string[]
    List of tenant role ids to be associated with the team.
    timeouts TeamTimeouts
    users string[]
    List of user ids to be associated with the team.
    workspaceRoleMappings TeamWorkspaceRoleMapping[]
    List of workspace roles to be associated with the team.
    name str
    Name of the team.
    project_role_mappings Sequence[TeamProjectRoleMappingArgs]
    List of project roles to be associated with the team.
    team_id str
    The ID of this resource.
    tenant_role_mappings Sequence[str]
    List of tenant role ids to be associated with the team.
    timeouts TeamTimeoutsArgs
    users Sequence[str]
    List of user ids to be associated with the team.
    workspace_role_mappings Sequence[TeamWorkspaceRoleMappingArgs]
    List of workspace roles to be associated with the team.
    name String
    Name of the team.
    projectRoleMappings List<Property Map>
    List of project roles to be associated with the team.
    teamId String
    The ID of this resource.
    tenantRoleMappings List<String>
    List of tenant role ids to be associated with the team.
    timeouts Property Map
    users List<String>
    List of user ids to be associated with the team.
    workspaceRoleMappings List<Property Map>
    List of workspace roles to be associated with the team.

    Supporting Types

    TeamProjectRoleMapping, TeamProjectRoleMappingArgs

    Id string
    Project id to be associated with the team.
    Roles List<string>
    List of project roles to be associated with the team.
    Id string
    Project id to be associated with the team.
    Roles []string
    List of project roles to be associated with the team.
    id String
    Project id to be associated with the team.
    roles List<String>
    List of project roles to be associated with the team.
    id string
    Project id to be associated with the team.
    roles string[]
    List of project roles to be associated with the team.
    id str
    Project id to be associated with the team.
    roles Sequence[str]
    List of project roles to be associated with the team.
    id String
    Project id to be associated with the team.
    roles List<String>
    List of project roles to be associated with the team.

    TeamTimeouts, TeamTimeoutsArgs

    Create string
    Delete string
    Update string
    Create string
    Delete string
    Update string
    create String
    delete String
    update String
    create string
    delete string
    update string
    create str
    delete str
    update str
    create String
    delete String
    update String

    TeamWorkspaceRoleMapping, TeamWorkspaceRoleMappingArgs

    Id string
    Project id to be associated with the team.
    Workspaces List<TeamWorkspaceRoleMappingWorkspace>
    List of workspace roles to be associated with the team.
    Id string
    Project id to be associated with the team.
    Workspaces []TeamWorkspaceRoleMappingWorkspace
    List of workspace roles to be associated with the team.
    id String
    Project id to be associated with the team.
    workspaces List<TeamWorkspaceRoleMappingWorkspace>
    List of workspace roles to be associated with the team.
    id string
    Project id to be associated with the team.
    workspaces TeamWorkspaceRoleMappingWorkspace[]
    List of workspace roles to be associated with the team.
    id str
    Project id to be associated with the team.
    workspaces Sequence[TeamWorkspaceRoleMappingWorkspace]
    List of workspace roles to be associated with the team.
    id String
    Project id to be associated with the team.
    workspaces List<Property Map>
    List of workspace roles to be associated with the team.

    TeamWorkspaceRoleMappingWorkspace, TeamWorkspaceRoleMappingWorkspaceArgs

    Id string
    Workspace id to be associated with the team.
    Roles List<string>
    List of workspace roles to be associated with the team.
    Id string
    Workspace id to be associated with the team.
    Roles []string
    List of workspace roles to be associated with the team.
    id String
    Workspace id to be associated with the team.
    roles List<String>
    List of workspace roles to be associated with the team.
    id string
    Workspace id to be associated with the team.
    roles string[]
    List of workspace roles to be associated with the team.
    id str
    Workspace id to be associated with the team.
    roles Sequence[str]
    List of workspace roles to be associated with the team.
    id String
    Workspace id to be associated with the team.
    roles List<String>
    List of workspace roles to be associated with the team.

    Package Details

    Repository
    spectrocloud spectrocloud/terraform-provider-spectrocloud
    License
    Notes
    This Pulumi package is based on the spectrocloud Terraform Provider.
    spectrocloud logo
    spectrocloud 0.23.5 published on Sunday, Apr 20, 2025 by spectrocloud