1. Packages
  2. Vercel Provider
  3. API Docs
  4. TeamMember
Vercel v3.1.2 published on Tuesday, May 13, 2025 by Pulumiverse

vercel.TeamMember

Explore with Pulumi AI

vercel logo
Vercel v3.1.2 published on Tuesday, May 13, 2025 by Pulumiverse

    Provider a resource for managing a team member.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as vercel from "@pulumiverse/vercel";
    
    const byUserId = new vercel.TeamMember("by_user_id", {
        teamId: "team_xxxxxxxxxxxxxxxxxxxxxxxx",
        userId: "uuuuuuuuuuuuuuuuuuuuuuuuuu",
        role: "MEMBER",
    });
    const byEmail = new vercel.TeamMember("by_email", {
        teamId: "team_xxxxxxxxxxxxxxxxxxxxxxxx",
        email: "example@example.com",
        role: "MEMBER",
    });
    
    import pulumi
    import pulumiverse_vercel as vercel
    
    by_user_id = vercel.TeamMember("by_user_id",
        team_id="team_xxxxxxxxxxxxxxxxxxxxxxxx",
        user_id="uuuuuuuuuuuuuuuuuuuuuuuuuu",
        role="MEMBER")
    by_email = vercel.TeamMember("by_email",
        team_id="team_xxxxxxxxxxxxxxxxxxxxxxxx",
        email="example@example.com",
        role="MEMBER")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    	"github.com/pulumiverse/pulumi-vercel/sdk/v3/go/vercel"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := vercel.NewTeamMember(ctx, "by_user_id", &vercel.TeamMemberArgs{
    			TeamId: pulumi.String("team_xxxxxxxxxxxxxxxxxxxxxxxx"),
    			UserId: pulumi.String("uuuuuuuuuuuuuuuuuuuuuuuuuu"),
    			Role:   pulumi.String("MEMBER"),
    		})
    		if err != nil {
    			return err
    		}
    		_, err = vercel.NewTeamMember(ctx, "by_email", &vercel.TeamMemberArgs{
    			TeamId: pulumi.String("team_xxxxxxxxxxxxxxxxxxxxxxxx"),
    			Email:  pulumi.String("example@example.com"),
    			Role:   pulumi.String("MEMBER"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Vercel = Pulumiverse.Vercel;
    
    return await Deployment.RunAsync(() => 
    {
        var byUserId = new Vercel.TeamMember("by_user_id", new()
        {
            TeamId = "team_xxxxxxxxxxxxxxxxxxxxxxxx",
            UserId = "uuuuuuuuuuuuuuuuuuuuuuuuuu",
            Role = "MEMBER",
        });
    
        var byEmail = new Vercel.TeamMember("by_email", new()
        {
            TeamId = "team_xxxxxxxxxxxxxxxxxxxxxxxx",
            Email = "example@example.com",
            Role = "MEMBER",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.vercel.TeamMember;
    import com.pulumi.vercel.TeamMemberArgs;
    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) {
            var byUserId = new TeamMember("byUserId", TeamMemberArgs.builder()
                .teamId("team_xxxxxxxxxxxxxxxxxxxxxxxx")
                .userId("uuuuuuuuuuuuuuuuuuuuuuuuuu")
                .role("MEMBER")
                .build());
    
            var byEmail = new TeamMember("byEmail", TeamMemberArgs.builder()
                .teamId("team_xxxxxxxxxxxxxxxxxxxxxxxx")
                .email("example@example.com")
                .role("MEMBER")
                .build());
    
        }
    }
    
    resources:
      byUserId:
        type: vercel:TeamMember
        name: by_user_id
        properties:
          teamId: team_xxxxxxxxxxxxxxxxxxxxxxxx
          userId: uuuuuuuuuuuuuuuuuuuuuuuuuu
          role: MEMBER
      byEmail:
        type: vercel:TeamMember
        name: by_email
        properties:
          teamId: team_xxxxxxxxxxxxxxxxxxxxxxxx
          email: example@example.com
          role: MEMBER
    

    Create TeamMember Resource

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

    Constructor syntax

    new TeamMember(name: string, args: TeamMemberArgs, opts?: CustomResourceOptions);
    @overload
    def TeamMember(resource_name: str,
                   args: TeamMemberArgs,
                   opts: Optional[ResourceOptions] = None)
    
    @overload
    def TeamMember(resource_name: str,
                   opts: Optional[ResourceOptions] = None,
                   role: Optional[str] = None,
                   team_id: Optional[str] = None,
                   access_groups: Optional[Sequence[str]] = None,
                   email: Optional[str] = None,
                   projects: Optional[Sequence[TeamMemberProjectArgs]] = None,
                   user_id: Optional[str] = None)
    func NewTeamMember(ctx *Context, name string, args TeamMemberArgs, opts ...ResourceOption) (*TeamMember, error)
    public TeamMember(string name, TeamMemberArgs args, CustomResourceOptions? opts = null)
    public TeamMember(String name, TeamMemberArgs args)
    public TeamMember(String name, TeamMemberArgs args, CustomResourceOptions options)
    
    type: vercel:TeamMember
    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 TeamMemberArgs
    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 TeamMemberArgs
    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 TeamMemberArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args TeamMemberArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args TeamMemberArgs
    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 teamMemberResource = new Vercel.TeamMember("teamMemberResource", new()
    {
        Role = "string",
        TeamId = "string",
        AccessGroups = new[]
        {
            "string",
        },
        Email = "string",
        Projects = new[]
        {
            new Vercel.Inputs.TeamMemberProjectArgs
            {
                ProjectId = "string",
                Role = "string",
            },
        },
        UserId = "string",
    });
    
    example, err := vercel.NewTeamMember(ctx, "teamMemberResource", &vercel.TeamMemberArgs{
    	Role:   pulumi.String("string"),
    	TeamId: pulumi.String("string"),
    	AccessGroups: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	Email: pulumi.String("string"),
    	Projects: vercel.TeamMemberProjectArray{
    		&vercel.TeamMemberProjectArgs{
    			ProjectId: pulumi.String("string"),
    			Role:      pulumi.String("string"),
    		},
    	},
    	UserId: pulumi.String("string"),
    })
    
    var teamMemberResource = new TeamMember("teamMemberResource", TeamMemberArgs.builder()
        .role("string")
        .teamId("string")
        .accessGroups("string")
        .email("string")
        .projects(TeamMemberProjectArgs.builder()
            .projectId("string")
            .role("string")
            .build())
        .userId("string")
        .build());
    
    team_member_resource = vercel.TeamMember("teamMemberResource",
        role="string",
        team_id="string",
        access_groups=["string"],
        email="string",
        projects=[{
            "project_id": "string",
            "role": "string",
        }],
        user_id="string")
    
    const teamMemberResource = new vercel.TeamMember("teamMemberResource", {
        role: "string",
        teamId: "string",
        accessGroups: ["string"],
        email: "string",
        projects: [{
            projectId: "string",
            role: "string",
        }],
        userId: "string",
    });
    
    type: vercel:TeamMember
    properties:
        accessGroups:
            - string
        email: string
        projects:
            - projectId: string
              role: string
        role: string
        teamId: string
        userId: string
    

    TeamMember 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 TeamMember resource accepts the following input properties:

    Role string
    The role that the user should have in the project. One of 'MEMBER', 'OWNER', 'VIEWER', 'DEVELOPER', 'BILLING' or 'CONTRIBUTOR'. Depending on your Team's plan, some of these roles may be unavailable.
    TeamId string
    The ID of the existing Vercel Team.
    AccessGroups List<string>
    If access groups are enabled on the team, and the user is a CONTRIBUTOR, projects, access_groups or both must be specified. A set of access groups IDs that the user should be granted access to.
    Email string
    The email of the user to add to the team. Must specify one of user_id or email.
    Projects List<Pulumiverse.Vercel.Inputs.TeamMemberProject>
    If access groups are enabled on the team, and the user is a CONTRIBUTOR, projects, access_groups or both must be specified. A set of projects that the user should be granted access to, along with their role in each project.
    UserId string
    The ID of the user to add to the team. Must specify one of user_id or email.
    Role string
    The role that the user should have in the project. One of 'MEMBER', 'OWNER', 'VIEWER', 'DEVELOPER', 'BILLING' or 'CONTRIBUTOR'. Depending on your Team's plan, some of these roles may be unavailable.
    TeamId string
    The ID of the existing Vercel Team.
    AccessGroups []string
    If access groups are enabled on the team, and the user is a CONTRIBUTOR, projects, access_groups or both must be specified. A set of access groups IDs that the user should be granted access to.
    Email string
    The email of the user to add to the team. Must specify one of user_id or email.
    Projects []TeamMemberProjectArgs
    If access groups are enabled on the team, and the user is a CONTRIBUTOR, projects, access_groups or both must be specified. A set of projects that the user should be granted access to, along with their role in each project.
    UserId string
    The ID of the user to add to the team. Must specify one of user_id or email.
    role String
    The role that the user should have in the project. One of 'MEMBER', 'OWNER', 'VIEWER', 'DEVELOPER', 'BILLING' or 'CONTRIBUTOR'. Depending on your Team's plan, some of these roles may be unavailable.
    teamId String
    The ID of the existing Vercel Team.
    accessGroups List<String>
    If access groups are enabled on the team, and the user is a CONTRIBUTOR, projects, access_groups or both must be specified. A set of access groups IDs that the user should be granted access to.
    email String
    The email of the user to add to the team. Must specify one of user_id or email.
    projects List<TeamMemberProject>
    If access groups are enabled on the team, and the user is a CONTRIBUTOR, projects, access_groups or both must be specified. A set of projects that the user should be granted access to, along with their role in each project.
    userId String
    The ID of the user to add to the team. Must specify one of user_id or email.
    role string
    The role that the user should have in the project. One of 'MEMBER', 'OWNER', 'VIEWER', 'DEVELOPER', 'BILLING' or 'CONTRIBUTOR'. Depending on your Team's plan, some of these roles may be unavailable.
    teamId string
    The ID of the existing Vercel Team.
    accessGroups string[]
    If access groups are enabled on the team, and the user is a CONTRIBUTOR, projects, access_groups or both must be specified. A set of access groups IDs that the user should be granted access to.
    email string
    The email of the user to add to the team. Must specify one of user_id or email.
    projects TeamMemberProject[]
    If access groups are enabled on the team, and the user is a CONTRIBUTOR, projects, access_groups or both must be specified. A set of projects that the user should be granted access to, along with their role in each project.
    userId string
    The ID of the user to add to the team. Must specify one of user_id or email.
    role str
    The role that the user should have in the project. One of 'MEMBER', 'OWNER', 'VIEWER', 'DEVELOPER', 'BILLING' or 'CONTRIBUTOR'. Depending on your Team's plan, some of these roles may be unavailable.
    team_id str
    The ID of the existing Vercel Team.
    access_groups Sequence[str]
    If access groups are enabled on the team, and the user is a CONTRIBUTOR, projects, access_groups or both must be specified. A set of access groups IDs that the user should be granted access to.
    email str
    The email of the user to add to the team. Must specify one of user_id or email.
    projects Sequence[TeamMemberProjectArgs]
    If access groups are enabled on the team, and the user is a CONTRIBUTOR, projects, access_groups or both must be specified. A set of projects that the user should be granted access to, along with their role in each project.
    user_id str
    The ID of the user to add to the team. Must specify one of user_id or email.
    role String
    The role that the user should have in the project. One of 'MEMBER', 'OWNER', 'VIEWER', 'DEVELOPER', 'BILLING' or 'CONTRIBUTOR'. Depending on your Team's plan, some of these roles may be unavailable.
    teamId String
    The ID of the existing Vercel Team.
    accessGroups List<String>
    If access groups are enabled on the team, and the user is a CONTRIBUTOR, projects, access_groups or both must be specified. A set of access groups IDs that the user should be granted access to.
    email String
    The email of the user to add to the team. Must specify one of user_id or email.
    projects List<Property Map>
    If access groups are enabled on the team, and the user is a CONTRIBUTOR, projects, access_groups or both must be specified. A set of projects that the user should be granted access to, along with their role in each project.
    userId String
    The ID of the user to add to the team. Must specify one of user_id or email.

    Outputs

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

    Confirmed bool
    Whether the user has confirmed their invitation.
    Id string
    The provider-assigned unique ID for this managed resource.
    Confirmed bool
    Whether the user has confirmed their invitation.
    Id string
    The provider-assigned unique ID for this managed resource.
    confirmed Boolean
    Whether the user has confirmed their invitation.
    id String
    The provider-assigned unique ID for this managed resource.
    confirmed boolean
    Whether the user has confirmed their invitation.
    id string
    The provider-assigned unique ID for this managed resource.
    confirmed bool
    Whether the user has confirmed their invitation.
    id str
    The provider-assigned unique ID for this managed resource.
    confirmed Boolean
    Whether the user has confirmed their invitation.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing TeamMember Resource

    Get an existing TeamMember 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?: TeamMemberState, opts?: CustomResourceOptions): TeamMember
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            access_groups: Optional[Sequence[str]] = None,
            confirmed: Optional[bool] = None,
            email: Optional[str] = None,
            projects: Optional[Sequence[TeamMemberProjectArgs]] = None,
            role: Optional[str] = None,
            team_id: Optional[str] = None,
            user_id: Optional[str] = None) -> TeamMember
    func GetTeamMember(ctx *Context, name string, id IDInput, state *TeamMemberState, opts ...ResourceOption) (*TeamMember, error)
    public static TeamMember Get(string name, Input<string> id, TeamMemberState? state, CustomResourceOptions? opts = null)
    public static TeamMember get(String name, Output<String> id, TeamMemberState state, CustomResourceOptions options)
    resources:  _:    type: vercel:TeamMember    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:
    AccessGroups List<string>
    If access groups are enabled on the team, and the user is a CONTRIBUTOR, projects, access_groups or both must be specified. A set of access groups IDs that the user should be granted access to.
    Confirmed bool
    Whether the user has confirmed their invitation.
    Email string
    The email of the user to add to the team. Must specify one of user_id or email.
    Projects List<Pulumiverse.Vercel.Inputs.TeamMemberProject>
    If access groups are enabled on the team, and the user is a CONTRIBUTOR, projects, access_groups or both must be specified. A set of projects that the user should be granted access to, along with their role in each project.
    Role string
    The role that the user should have in the project. One of 'MEMBER', 'OWNER', 'VIEWER', 'DEVELOPER', 'BILLING' or 'CONTRIBUTOR'. Depending on your Team's plan, some of these roles may be unavailable.
    TeamId string
    The ID of the existing Vercel Team.
    UserId string
    The ID of the user to add to the team. Must specify one of user_id or email.
    AccessGroups []string
    If access groups are enabled on the team, and the user is a CONTRIBUTOR, projects, access_groups or both must be specified. A set of access groups IDs that the user should be granted access to.
    Confirmed bool
    Whether the user has confirmed their invitation.
    Email string
    The email of the user to add to the team. Must specify one of user_id or email.
    Projects []TeamMemberProjectArgs
    If access groups are enabled on the team, and the user is a CONTRIBUTOR, projects, access_groups or both must be specified. A set of projects that the user should be granted access to, along with their role in each project.
    Role string
    The role that the user should have in the project. One of 'MEMBER', 'OWNER', 'VIEWER', 'DEVELOPER', 'BILLING' or 'CONTRIBUTOR'. Depending on your Team's plan, some of these roles may be unavailable.
    TeamId string
    The ID of the existing Vercel Team.
    UserId string
    The ID of the user to add to the team. Must specify one of user_id or email.
    accessGroups List<String>
    If access groups are enabled on the team, and the user is a CONTRIBUTOR, projects, access_groups or both must be specified. A set of access groups IDs that the user should be granted access to.
    confirmed Boolean
    Whether the user has confirmed their invitation.
    email String
    The email of the user to add to the team. Must specify one of user_id or email.
    projects List<TeamMemberProject>
    If access groups are enabled on the team, and the user is a CONTRIBUTOR, projects, access_groups or both must be specified. A set of projects that the user should be granted access to, along with their role in each project.
    role String
    The role that the user should have in the project. One of 'MEMBER', 'OWNER', 'VIEWER', 'DEVELOPER', 'BILLING' or 'CONTRIBUTOR'. Depending on your Team's plan, some of these roles may be unavailable.
    teamId String
    The ID of the existing Vercel Team.
    userId String
    The ID of the user to add to the team. Must specify one of user_id or email.
    accessGroups string[]
    If access groups are enabled on the team, and the user is a CONTRIBUTOR, projects, access_groups or both must be specified. A set of access groups IDs that the user should be granted access to.
    confirmed boolean
    Whether the user has confirmed their invitation.
    email string
    The email of the user to add to the team. Must specify one of user_id or email.
    projects TeamMemberProject[]
    If access groups are enabled on the team, and the user is a CONTRIBUTOR, projects, access_groups or both must be specified. A set of projects that the user should be granted access to, along with their role in each project.
    role string
    The role that the user should have in the project. One of 'MEMBER', 'OWNER', 'VIEWER', 'DEVELOPER', 'BILLING' or 'CONTRIBUTOR'. Depending on your Team's plan, some of these roles may be unavailable.
    teamId string
    The ID of the existing Vercel Team.
    userId string
    The ID of the user to add to the team. Must specify one of user_id or email.
    access_groups Sequence[str]
    If access groups are enabled on the team, and the user is a CONTRIBUTOR, projects, access_groups or both must be specified. A set of access groups IDs that the user should be granted access to.
    confirmed bool
    Whether the user has confirmed their invitation.
    email str
    The email of the user to add to the team. Must specify one of user_id or email.
    projects Sequence[TeamMemberProjectArgs]
    If access groups are enabled on the team, and the user is a CONTRIBUTOR, projects, access_groups or both must be specified. A set of projects that the user should be granted access to, along with their role in each project.
    role str
    The role that the user should have in the project. One of 'MEMBER', 'OWNER', 'VIEWER', 'DEVELOPER', 'BILLING' or 'CONTRIBUTOR'. Depending on your Team's plan, some of these roles may be unavailable.
    team_id str
    The ID of the existing Vercel Team.
    user_id str
    The ID of the user to add to the team. Must specify one of user_id or email.
    accessGroups List<String>
    If access groups are enabled on the team, and the user is a CONTRIBUTOR, projects, access_groups or both must be specified. A set of access groups IDs that the user should be granted access to.
    confirmed Boolean
    Whether the user has confirmed their invitation.
    email String
    The email of the user to add to the team. Must specify one of user_id or email.
    projects List<Property Map>
    If access groups are enabled on the team, and the user is a CONTRIBUTOR, projects, access_groups or both must be specified. A set of projects that the user should be granted access to, along with their role in each project.
    role String
    The role that the user should have in the project. One of 'MEMBER', 'OWNER', 'VIEWER', 'DEVELOPER', 'BILLING' or 'CONTRIBUTOR'. Depending on your Team's plan, some of these roles may be unavailable.
    teamId String
    The ID of the existing Vercel Team.
    userId String
    The ID of the user to add to the team. Must specify one of user_id or email.

    Supporting Types

    TeamMemberProject, TeamMemberProjectArgs

    ProjectId string
    The ID of the project that the user should be granted access to.
    Role string
    The role that the user should have in the project.
    ProjectId string
    The ID of the project that the user should be granted access to.
    Role string
    The role that the user should have in the project.
    projectId String
    The ID of the project that the user should be granted access to.
    role String
    The role that the user should have in the project.
    projectId string
    The ID of the project that the user should be granted access to.
    role string
    The role that the user should have in the project.
    project_id str
    The ID of the project that the user should be granted access to.
    role str
    The role that the user should have in the project.
    projectId String
    The ID of the project that the user should be granted access to.
    role String
    The role that the user should have in the project.

    Import

    To import, use the team_id and user_id.

    $ pulumi import vercel:index/teamMember:TeamMember example team_xxxxxxxxxxxxxxxxxxxxxxxx/uuuuuuuuuuuuuuuuuuuuuuuuuu
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    vercel pulumiverse/pulumi-vercel
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the vercel Terraform Provider.
    vercel logo
    Vercel v3.1.2 published on Tuesday, May 13, 2025 by Pulumiverse