1. Packages
  2. Packages
  3. Dynatrace
  4. API Docs
  5. IamServiceUser
Viewing docs for Dynatrace v0.37.0
published on Tuesday, Jun 23, 2026 by Pulumiverse
dynatrace logo
Viewing docs for Dynatrace v0.37.0
published on Tuesday, Jun 23, 2026 by Pulumiverse

    Dynatrace SaaS only

    To utilize this resource, please define the environment variables DT_CLIENT_ID, DT_CLIENT_SECRET, DT_ACCOUNT_ID with an OAuth client including the following permissions: Allow read access for identity resources (users and groups) (account-idm-read) and Allow write access for identity resources (users and groups) (account-idm-write).

    This resource is excluded by default in the export utility, please explicitly specify the resource to retrieve existing configuration.

    Dynatrace Documentation

    • Dynatrace IAM - https://docs.dynatrace.com/docs/manage/identity-access-management/user-and-group-management/access-service-users

    Resource Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as dynatrace from "@pulumiverse/dynatrace";
    
    const testServiceUser = new dynatrace.IamServiceUser("test_service_user", {
        name: "test service user",
        description: "a service user for testing purposes",
        groups: [restricted.id],
    });
    
    import pulumi
    import pulumiverse_dynatrace as dynatrace
    
    test_service_user = dynatrace.IamServiceUser("test_service_user",
        name="test service user",
        description="a service user for testing purposes",
        groups=[restricted["id"]])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    	"github.com/pulumiverse/pulumi-dynatrace/sdk/go/dynatrace"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := dynatrace.NewIamServiceUser(ctx, "test_service_user", &dynatrace.IamServiceUserArgs{
    			Name:        pulumi.String("test service user"),
    			Description: pulumi.String("a service user for testing purposes"),
    			Groups: pulumi.StringArray{
    				restricted.Id,
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Dynatrace = Pulumiverse.Dynatrace;
    
    return await Deployment.RunAsync(() => 
    {
        var testServiceUser = new Dynatrace.IamServiceUser("test_service_user", new()
        {
            Name = "test service user",
            Description = "a service user for testing purposes",
            Groups = new[]
            {
                restricted.Id,
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.dynatrace.IamServiceUser;
    import com.pulumi.dynatrace.IamServiceUserArgs;
    import java.util.ArrayList;
    import java.util.Arrays;
    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 testServiceUser = new IamServiceUser("testServiceUser", IamServiceUserArgs.builder()
                .name("test service user")
                .description("a service user for testing purposes")
                .groups(restricted.id())
                .build());
    
        }
    }
    
    resources:
      testServiceUser:
        type: dynatrace:IamServiceUser
        name: test_service_user
        properties:
          name: test service user
          description: a service user for testing purposes
          groups:
            - ${restricted.id}
    
    pulumi {
      required_providers {
        dynatrace = {
          source = "pulumi/dynatrace"
        }
      }
    }
    
    resource "dynatrace_iamserviceuser" "test_service_user" {
      name        = "test service user"
      description = "a service user for testing purposes"
      groups      = [restricted.id]
    }
    

    Create IamServiceUser Resource

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

    Constructor syntax

    new IamServiceUser(name: string, args?: IamServiceUserArgs, opts?: CustomResourceOptions);
    @overload
    def IamServiceUser(resource_name: str,
                       args: Optional[IamServiceUserArgs] = None,
                       opts: Optional[ResourceOptions] = None)
    
    @overload
    def IamServiceUser(resource_name: str,
                       opts: Optional[ResourceOptions] = None,
                       description: Optional[str] = None,
                       groups: Optional[Sequence[str]] = None,
                       name: Optional[str] = None)
    func NewIamServiceUser(ctx *Context, name string, args *IamServiceUserArgs, opts ...ResourceOption) (*IamServiceUser, error)
    public IamServiceUser(string name, IamServiceUserArgs? args = null, CustomResourceOptions? opts = null)
    public IamServiceUser(String name, IamServiceUserArgs args)
    public IamServiceUser(String name, IamServiceUserArgs args, CustomResourceOptions options)
    
    type: dynatrace:IamServiceUser
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    
    resource "dynatrace_iamserviceuser" "name" {
        # resource properties
    }

    Parameters

    name string
    The unique name of the resource.
    args IamServiceUserArgs
    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 IamServiceUserArgs
    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 IamServiceUserArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args IamServiceUserArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args IamServiceUserArgs
    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 iamServiceUserResource = new Dynatrace.IamServiceUser("iamServiceUserResource", new()
    {
        Description = "string",
        Groups = new[]
        {
            "string",
        },
        Name = "string",
    });
    
    example, err := dynatrace.NewIamServiceUser(ctx, "iamServiceUserResource", &dynatrace.IamServiceUserArgs{
    	Description: pulumi.String("string"),
    	Groups: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	Name: pulumi.String("string"),
    })
    
    resource "dynatrace_iamserviceuser" "iamServiceUserResource" {
      description = "string"
      groups      = ["string"]
      name        = "string"
    }
    
    var iamServiceUserResource = new IamServiceUser("iamServiceUserResource", IamServiceUserArgs.builder()
        .description("string")
        .groups("string")
        .name("string")
        .build());
    
    iam_service_user_resource = dynatrace.IamServiceUser("iamServiceUserResource",
        description="string",
        groups=["string"],
        name="string")
    
    const iamServiceUserResource = new dynatrace.IamServiceUser("iamServiceUserResource", {
        description: "string",
        groups: ["string"],
        name: "string",
    });
    
    type: dynatrace:IamServiceUser
    properties:
        description: string
        groups:
            - string
        name: string
    

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

    Description string
    The description of the service user
    Groups List<string>
    The UUIDs of the groups the service user belongs to
    Name string
    The name of the service user
    Description string
    The description of the service user
    Groups []string
    The UUIDs of the groups the service user belongs to
    Name string
    The name of the service user
    description string
    The description of the service user
    groups list(string)
    The UUIDs of the groups the service user belongs to
    name string
    The name of the service user
    description String
    The description of the service user
    groups List<String>
    The UUIDs of the groups the service user belongs to
    name String
    The name of the service user
    description string
    The description of the service user
    groups string[]
    The UUIDs of the groups the service user belongs to
    name string
    The name of the service user
    description str
    The description of the service user
    groups Sequence[str]
    The UUIDs of the groups the service user belongs to
    name str
    The name of the service user
    description String
    The description of the service user
    groups List<String>
    The UUIDs of the groups the service user belongs to
    name String
    The name of the service user

    Outputs

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

    Email string
    The email of the service user
    Id string
    The provider-assigned unique ID for this managed resource.
    Email string
    The email of the service user
    Id string
    The provider-assigned unique ID for this managed resource.
    email string
    The email of the service user
    id string
    The provider-assigned unique ID for this managed resource.
    email String
    The email of the service user
    id String
    The provider-assigned unique ID for this managed resource.
    email string
    The email of the service user
    id string
    The provider-assigned unique ID for this managed resource.
    email str
    The email of the service user
    id str
    The provider-assigned unique ID for this managed resource.
    email String
    The email of the service user
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing IamServiceUser Resource

    Get an existing IamServiceUser 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?: IamServiceUserState, opts?: CustomResourceOptions): IamServiceUser
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            description: Optional[str] = None,
            email: Optional[str] = None,
            groups: Optional[Sequence[str]] = None,
            name: Optional[str] = None) -> IamServiceUser
    func GetIamServiceUser(ctx *Context, name string, id IDInput, state *IamServiceUserState, opts ...ResourceOption) (*IamServiceUser, error)
    public static IamServiceUser Get(string name, Input<string> id, IamServiceUserState? state, CustomResourceOptions? opts = null)
    public static IamServiceUser get(String name, Output<String> id, IamServiceUserState state, CustomResourceOptions options)
    resources:  _:    type: dynatrace:IamServiceUser    get:      id: ${id}
    import {
      to = dynatrace_iamserviceuser.example
      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:
    Description string
    The description of the service user
    Email string
    The email of the service user
    Groups List<string>
    The UUIDs of the groups the service user belongs to
    Name string
    The name of the service user
    Description string
    The description of the service user
    Email string
    The email of the service user
    Groups []string
    The UUIDs of the groups the service user belongs to
    Name string
    The name of the service user
    description string
    The description of the service user
    email string
    The email of the service user
    groups list(string)
    The UUIDs of the groups the service user belongs to
    name string
    The name of the service user
    description String
    The description of the service user
    email String
    The email of the service user
    groups List<String>
    The UUIDs of the groups the service user belongs to
    name String
    The name of the service user
    description string
    The description of the service user
    email string
    The email of the service user
    groups string[]
    The UUIDs of the groups the service user belongs to
    name string
    The name of the service user
    description str
    The description of the service user
    email str
    The email of the service user
    groups Sequence[str]
    The UUIDs of the groups the service user belongs to
    name str
    The name of the service user
    description String
    The description of the service user
    email String
    The email of the service user
    groups List<String>
    The UUIDs of the groups the service user belongs to
    name String
    The name of the service user

    Package Details

    Repository
    dynatrace pulumiverse/pulumi-dynatrace
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the dynatrace Terraform Provider.
    dynatrace logo
    Viewing docs for Dynatrace v0.37.0
    published on Tuesday, Jun 23, 2026 by Pulumiverse

      Try Pulumi Cloud free.
      Your team will thank you.

      Start free trial