1. Packages
  2. Rollbar Provider
  3. API Docs
  4. User
rollbar 1.15.1 published on Tuesday, Apr 15, 2025 by rollbar

rollbar.User

Explore with Pulumi AI

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],
});
Copy
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])
Copy
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
	})
}
Copy
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,
        },
    });

});
Copy
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());

    }
}
Copy
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}
Copy

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 This property is required. string
The unique name of the resource.
args This property is required. UserArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. 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 This property is required. string
The unique name of the resource.
args This property is required. UserArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. UserArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. 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",
});
Copy
example, err := rollbar.NewUser(ctx, "userResource", &rollbar.UserArgs{
Email: pulumi.String("string"),
TeamIds: pulumi.Float64Array{
pulumi.Float64(0),
},
RollbarUserId: pulumi.String("string"),
})
Copy
var userResource = new User("userResource", UserArgs.builder()
    .email("string")
    .teamIds(0)
    .rollbarUserId("string")
    .build());
Copy
user_resource = rollbar.User("userResource",
    email="string",
    team_ids=[0],
    rollbar_user_id="string")
Copy
const userResource = new rollbar.User("userResource", {
    email: "string",
    teamIds: [0],
    rollbarUserId: "string",
});
Copy
type: rollbar:User
properties:
    email: string
    rollbarUserId: string
    teamIds:
        - 0
Copy

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 This property is required. string
The user's email address
TeamIds This property is required. List<double>
IDs of the teams to which this user belongs
RollbarUserId string
Email This property is required. string
The user's email address
TeamIds This property is required. []float64
IDs of the teams to which this user belongs
RollbarUserId string
email This property is required. String
The user's email address
teamIds This property is required. List<Double>
IDs of the teams to which this user belongs
rollbarUserId String
email This property is required. string
The user's email address
teamIds This property is required. number[]
IDs of the teams to which this user belongs
rollbarUserId string
email This property is required. str
The user's email address
team_ids This property is required. Sequence[float]
IDs of the teams to which this user belongs
rollbar_user_id str
email This property is required. String
The user's email address
teamIds This property is required. 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 This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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
Copy

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.