1. Packages
  2. Rollbar Provider
  3. API Docs
  4. User
rollbar 1.16.0 published on Wednesday, Apr 30, 2025 by rollbar

rollbar.User

Explore with Pulumi AI

rollbar logo
rollbar 1.16.0 published on Wednesday, Apr 30, 2025 by rollbar

    rollbar.User Resource

    =========================

    Rollbar user resource.

    Example Usage


    import * as pulumi from "@pulumi/pulumi";
    import * as rollbar from "@pulumi/rollbar";
    
    // Create a team
    const developers = new rollbar.Team("developers", {});
    // Create a user as a member of that team
    const someDev = new rollbar.User("someDev", {
        email: "some_dev@company.com",
        teamIds: [developers.teamId],
    });
    
    import pulumi
    import pulumi_rollbar as rollbar
    
    # Create a team
    developers = rollbar.Team("developers")
    # Create a user as a member of that team
    some_dev = rollbar.User("someDev",
        email="some_dev@company.com",
        team_ids=[developers.team_id])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/rollbar/rollbar"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		// Create a team
    		developers, err := rollbar.NewTeam(ctx, "developers", nil)
    		if err != nil {
    			return err
    		}
    		// Create a user as a member of that team
    		_, err = rollbar.NewUser(ctx, "someDev", &rollbar.UserArgs{
    			Email: pulumi.String("some_dev@company.com"),
    			TeamIds: pulumi.Float64Array{
    				developers.TeamId,
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Rollbar = Pulumi.Rollbar;
    
    return await Deployment.RunAsync(() => 
    {
        // Create a team
        var developers = new Rollbar.Team("developers");
    
        // Create a user as a member of that team
        var someDev = new Rollbar.User("someDev", new()
        {
            Email = "some_dev@company.com",
            TeamIds = new[]
            {
                developers.TeamId,
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.rollbar.Team;
    import com.pulumi.rollbar.User;
    import com.pulumi.rollbar.UserArgs;
    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) {
            // Create a team
            var developers = new Team("developers");
    
            // Create a user as a member of that team
            var someDev = new User("someDev", UserArgs.builder()
                .email("some_dev@company.com")
                .teamIds(developers.teamId())
                .build());
    
        }
    }
    
    resources:
      # Create a team
      developers:
        type: rollbar:Team
      # Create a user as a member of that team
      someDev:
        type: rollbar:User
        properties:
          email: some_dev@company.com
          teamIds:
            - ${developers.teamId}
    

    Create User Resource

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

    Constructor syntax

    new User(name: string, args: UserArgs, opts?: CustomResourceOptions);
    @overload
    def User(resource_name: str,
             args: UserArgs,
             opts: Optional[ResourceOptions] = None)
    
    @overload
    def User(resource_name: str,
             opts: Optional[ResourceOptions] = None,
             email: Optional[str] = None,
             team_ids: Optional[Sequence[float]] = None,
             rollbar_user_id: Optional[str] = None)
    func NewUser(ctx *Context, name string, args UserArgs, opts ...ResourceOption) (*User, error)
    public User(string name, UserArgs args, CustomResourceOptions? opts = null)
    public User(String name, UserArgs args)
    public User(String name, UserArgs args, CustomResourceOptions options)
    
    type: rollbar:User
    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 UserArgs
    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 UserArgs
    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 UserArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args UserArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args UserArgs
    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 userResource = new Rollbar.User("userResource", new()
    {
        Email = "string",
        TeamIds = new[]
        {
            0,
        },
        RollbarUserId = "string",
    });
    
    example, err := rollbar.NewUser(ctx, "userResource", &rollbar.UserArgs{
    	Email: pulumi.String("string"),
    	TeamIds: pulumi.Float64Array{
    		pulumi.Float64(0),
    	},
    	RollbarUserId: pulumi.String("string"),
    })
    
    var userResource = new User("userResource", UserArgs.builder()
        .email("string")
        .teamIds(0)
        .rollbarUserId("string")
        .build());
    
    user_resource = rollbar.User("userResource",
        email="string",
        team_ids=[0],
        rollbar_user_id="string")
    
    const userResource = new rollbar.User("userResource", {
        email: "string",
        teamIds: [0],
        rollbarUserId: "string",
    });
    
    type: rollbar:User
    properties:
        email: string
        rollbarUserId: string
        teamIds:
            - 0
    

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

    Email string
    The user's email address
    TeamIds List<double>
    IDs of the teams to which this user belongs
    RollbarUserId string
    Email string
    The user's email address
    TeamIds []float64
    IDs of the teams to which this user belongs
    RollbarUserId string
    email String
    The user's email address
    teamIds List<Double>
    IDs of the teams to which this user belongs
    rollbarUserId String
    email string
    The user's email address
    teamIds number[]
    IDs of the teams to which this user belongs
    rollbarUserId string
    email str
    The user's email address
    team_ids Sequence[float]
    IDs of the teams to which this user belongs
    rollbar_user_id str
    email String
    The user's email address
    teamIds List<Number>
    IDs of the teams to which this user belongs
    rollbarUserId String

    Outputs

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

    Id string
    The provider-assigned unique ID for this managed resource.
    Status string
    Status of the user. Either invited or subscribed
    UserId double
    The ID of the user
    Username string
    The user's username
    Id string
    The provider-assigned unique ID for this managed resource.
    Status string
    Status of the user. Either invited or subscribed
    UserId float64
    The ID of the user
    Username string
    The user's username
    id String
    The provider-assigned unique ID for this managed resource.
    status String
    Status of the user. Either invited or subscribed
    userId Double
    The ID of the user
    username String
    The user's username
    id string
    The provider-assigned unique ID for this managed resource.
    status string
    Status of the user. Either invited or subscribed
    userId number
    The ID of the user
    username string
    The user's username
    id str
    The provider-assigned unique ID for this managed resource.
    status str
    Status of the user. Either invited or subscribed
    user_id float
    The ID of the user
    username str
    The user's username
    id String
    The provider-assigned unique ID for this managed resource.
    status String
    Status of the user. Either invited or subscribed
    userId Number
    The ID of the user
    username String
    The user's username

    Look up Existing User Resource

    Get an existing User 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?: UserState, opts?: CustomResourceOptions): User
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            email: Optional[str] = None,
            rollbar_user_id: Optional[str] = None,
            status: Optional[str] = None,
            team_ids: Optional[Sequence[float]] = None,
            user_id: Optional[float] = None,
            username: Optional[str] = None) -> User
    func GetUser(ctx *Context, name string, id IDInput, state *UserState, opts ...ResourceOption) (*User, error)
    public static User Get(string name, Input<string> id, UserState? state, CustomResourceOptions? opts = null)
    public static User get(String name, Output<String> id, UserState state, CustomResourceOptions options)
    resources:  _:    type: rollbar:User    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:
    Email string
    The user's email address
    RollbarUserId string
    Status string
    Status of the user. Either invited or subscribed
    TeamIds List<double>
    IDs of the teams to which this user belongs
    UserId double
    The ID of the user
    Username string
    The user's username
    Email string
    The user's email address
    RollbarUserId string
    Status string
    Status of the user. Either invited or subscribed
    TeamIds []float64
    IDs of the teams to which this user belongs
    UserId float64
    The ID of the user
    Username string
    The user's username
    email String
    The user's email address
    rollbarUserId String
    status String
    Status of the user. Either invited or subscribed
    teamIds List<Double>
    IDs of the teams to which this user belongs
    userId Double
    The ID of the user
    username String
    The user's username
    email string
    The user's email address
    rollbarUserId string
    status string
    Status of the user. Either invited or subscribed
    teamIds number[]
    IDs of the teams to which this user belongs
    userId number
    The ID of the user
    username string
    The user's username
    email str
    The user's email address
    rollbar_user_id str
    status str
    Status of the user. Either invited or subscribed
    team_ids Sequence[float]
    IDs of the teams to which this user belongs
    user_id float
    The ID of the user
    username str
    The user's username
    email String
    The user's email address
    rollbarUserId String
    status String
    Status of the user. Either invited or subscribed
    teamIds List<Number>
    IDs of the teams to which this user belongs
    userId Number
    The ID of the user
    username String
    The user's username

    Import


    Users can be imported using their user email address, e.g.

    $ pulumi import rollbar:index/user:User some_dev some_dev@company.com
    

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

    Package Details

    Repository
    rollbar rollbar/terraform-provider-rollbar
    License
    Notes
    This Pulumi package is based on the rollbar Terraform Provider.
    rollbar logo
    rollbar 1.16.0 published on Wednesday, Apr 30, 2025 by rollbar