1. Packages
  2. Opsgenie
  3. API Docs
  4. getUser
Opsgenie v1.3.6 published on Tuesday, Feb 27, 2024 by Pulumi

opsgenie.getUser

Explore with Pulumi AI

opsgenie logo
Opsgenie v1.3.6 published on Tuesday, Feb 27, 2024 by Pulumi

    Manages existing User within Opsgenie.

    Example Usage

    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Opsgenie = Pulumi.Opsgenie;
    
    return await Deployment.RunAsync(() => 
    {
        var test = Opsgenie.GetUser.Invoke(new()
        {
            Username = "user@domain.com",
        });
    
    });
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-opsgenie/sdk/go/opsgenie"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := opsgenie.LookupUser(ctx, &opsgenie.LookupUserArgs{
    			Username: "user@domain.com",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.opsgenie.OpsgenieFunctions;
    import com.pulumi.opsgenie.inputs.GetUserArgs;
    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 test = OpsgenieFunctions.getUser(GetUserArgs.builder()
                .username("user@domain.com")
                .build());
    
        }
    }
    
    import pulumi
    import pulumi_opsgenie as opsgenie
    
    test = opsgenie.get_user(username="user@domain.com")
    
    import * as pulumi from "@pulumi/pulumi";
    import * as opsgenie from "@pulumi/opsgenie";
    
    const test = opsgenie.getUser({
        username: "user@domain.com",
    });
    
    variables:
      test:
        fn::invoke:
          Function: opsgenie:getUser
          Arguments:
            username: user@domain.com
    

    Using getUser

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getUser(args: GetUserArgs, opts?: InvokeOptions): Promise<GetUserResult>
    function getUserOutput(args: GetUserOutputArgs, opts?: InvokeOptions): Output<GetUserResult>
    def get_user(full_name: Optional[str] = None,
                 locale: Optional[str] = None,
                 role: Optional[str] = None,
                 timezone: Optional[str] = None,
                 username: Optional[str] = None,
                 opts: Optional[InvokeOptions] = None) -> GetUserResult
    def get_user_output(full_name: Optional[pulumi.Input[str]] = None,
                 locale: Optional[pulumi.Input[str]] = None,
                 role: Optional[pulumi.Input[str]] = None,
                 timezone: Optional[pulumi.Input[str]] = None,
                 username: Optional[pulumi.Input[str]] = None,
                 opts: Optional[InvokeOptions] = None) -> Output[GetUserResult]
    func LookupUser(ctx *Context, args *LookupUserArgs, opts ...InvokeOption) (*LookupUserResult, error)
    func LookupUserOutput(ctx *Context, args *LookupUserOutputArgs, opts ...InvokeOption) LookupUserResultOutput

    > Note: This function is named LookupUser in the Go SDK.

    public static class GetUser 
    {
        public static Task<GetUserResult> InvokeAsync(GetUserArgs args, InvokeOptions? opts = null)
        public static Output<GetUserResult> Invoke(GetUserInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetUserResult> getUser(GetUserArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: opsgenie:index/getUser:getUser
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Username string
    The email address associated with this user. Opsgenie defines that this must not be longer than 100 characters.
    FullName string
    The Full Name of the User.
    Locale string
    Location information for the user. Please look at Supported Locale Ids for available locales.
    Role string
    The Role assigned to the User. Either a built-in such as 'Owner', 'Admin' or 'User' - or the name of a custom role.
    Timezone string
    Timezone information of the user. Please look at Supported Timezone Ids for available timezones.
    Username string
    The email address associated with this user. Opsgenie defines that this must not be longer than 100 characters.
    FullName string
    The Full Name of the User.
    Locale string
    Location information for the user. Please look at Supported Locale Ids for available locales.
    Role string
    The Role assigned to the User. Either a built-in such as 'Owner', 'Admin' or 'User' - or the name of a custom role.
    Timezone string
    Timezone information of the user. Please look at Supported Timezone Ids for available timezones.
    username String
    The email address associated with this user. Opsgenie defines that this must not be longer than 100 characters.
    fullName String
    The Full Name of the User.
    locale String
    Location information for the user. Please look at Supported Locale Ids for available locales.
    role String
    The Role assigned to the User. Either a built-in such as 'Owner', 'Admin' or 'User' - or the name of a custom role.
    timezone String
    Timezone information of the user. Please look at Supported Timezone Ids for available timezones.
    username string
    The email address associated with this user. Opsgenie defines that this must not be longer than 100 characters.
    fullName string
    The Full Name of the User.
    locale string
    Location information for the user. Please look at Supported Locale Ids for available locales.
    role string
    The Role assigned to the User. Either a built-in such as 'Owner', 'Admin' or 'User' - or the name of a custom role.
    timezone string
    Timezone information of the user. Please look at Supported Timezone Ids for available timezones.
    username str
    The email address associated with this user. Opsgenie defines that this must not be longer than 100 characters.
    full_name str
    The Full Name of the User.
    locale str
    Location information for the user. Please look at Supported Locale Ids for available locales.
    role str
    The Role assigned to the User. Either a built-in such as 'Owner', 'Admin' or 'User' - or the name of a custom role.
    timezone str
    Timezone information of the user. Please look at Supported Timezone Ids for available timezones.
    username String
    The email address associated with this user. Opsgenie defines that this must not be longer than 100 characters.
    fullName String
    The Full Name of the User.
    locale String
    Location information for the user. Please look at Supported Locale Ids for available locales.
    role String
    The Role assigned to the User. Either a built-in such as 'Owner', 'Admin' or 'User' - or the name of a custom role.
    timezone String
    Timezone information of the user. Please look at Supported Timezone Ids for available timezones.

    getUser Result

    The following output properties are available:

    Id string
    The provider-assigned unique ID for this managed resource.
    Username string
    FullName string
    The Full Name of the User.
    Locale string
    Location information for the user. Please look at Supported Locale Ids for available locales.
    Role string
    The Role assigned to the User. Either a built-in such as 'Owner', 'Admin' or 'User' - or the name of a custom role.
    Timezone string
    Timezone information of the user. Please look at Supported Timezone Ids for available timezones.
    Id string
    The provider-assigned unique ID for this managed resource.
    Username string
    FullName string
    The Full Name of the User.
    Locale string
    Location information for the user. Please look at Supported Locale Ids for available locales.
    Role string
    The Role assigned to the User. Either a built-in such as 'Owner', 'Admin' or 'User' - or the name of a custom role.
    Timezone string
    Timezone information of the user. Please look at Supported Timezone Ids for available timezones.
    id String
    The provider-assigned unique ID for this managed resource.
    username String
    fullName String
    The Full Name of the User.
    locale String
    Location information for the user. Please look at Supported Locale Ids for available locales.
    role String
    The Role assigned to the User. Either a built-in such as 'Owner', 'Admin' or 'User' - or the name of a custom role.
    timezone String
    Timezone information of the user. Please look at Supported Timezone Ids for available timezones.
    id string
    The provider-assigned unique ID for this managed resource.
    username string
    fullName string
    The Full Name of the User.
    locale string
    Location information for the user. Please look at Supported Locale Ids for available locales.
    role string
    The Role assigned to the User. Either a built-in such as 'Owner', 'Admin' or 'User' - or the name of a custom role.
    timezone string
    Timezone information of the user. Please look at Supported Timezone Ids for available timezones.
    id str
    The provider-assigned unique ID for this managed resource.
    username str
    full_name str
    The Full Name of the User.
    locale str
    Location information for the user. Please look at Supported Locale Ids for available locales.
    role str
    The Role assigned to the User. Either a built-in such as 'Owner', 'Admin' or 'User' - or the name of a custom role.
    timezone str
    Timezone information of the user. Please look at Supported Timezone Ids for available timezones.
    id String
    The provider-assigned unique ID for this managed resource.
    username String
    fullName String
    The Full Name of the User.
    locale String
    Location information for the user. Please look at Supported Locale Ids for available locales.
    role String
    The Role assigned to the User. Either a built-in such as 'Owner', 'Admin' or 'User' - or the name of a custom role.
    timezone String
    Timezone information of the user. Please look at Supported Timezone Ids for available timezones.

    Package Details

    Repository
    Opsgenie pulumi/pulumi-opsgenie
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the opsgenie Terraform Provider.
    opsgenie logo
    Opsgenie v1.3.6 published on Tuesday, Feb 27, 2024 by Pulumi