1. Packages
  2. Grafana Cloud
  3. API Docs
  4. getOncallUser
Grafana v0.7.0 published on Tuesday, Nov 5, 2024 by pulumiverse

grafana.getOncallUser

Explore with Pulumi AI

grafana logo
Grafana v0.7.0 published on Tuesday, Nov 5, 2024 by pulumiverse
    Deprecated: grafana.index/getoncalluser.getOncallUser has been deprecated in favor of grafana.oncall/getuser.getUser

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as grafana from "@pulumi/grafana";
    
    const alex = grafana.onCall.getUser({
        username: "alex",
    });
    
    import pulumi
    import pulumi_grafana as grafana
    
    alex = grafana.onCall.get_user(username="alex")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    	"github.com/pulumiverse/pulumi-grafana/sdk/go/grafana/onCall"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := onCall.GetUser(ctx, &oncall.GetUserArgs{
    			Username: "alex",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Grafana = Pulumi.Grafana;
    
    return await Deployment.RunAsync(() => 
    {
        var alex = Grafana.OnCall.GetUser.Invoke(new()
        {
            Username = "alex",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.grafana.onCall.OnCallFunctions;
    import com.pulumi.grafana.onCall.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 alex = OnCallFunctions.getUser(GetUserArgs.builder()
                .username("alex")
                .build());
    
        }
    }
    
    variables:
      alex:
        fn::invoke:
          Function: grafana:onCall:getUser
          Arguments:
            username: alex
    

    Using getOncallUser

    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 getOncallUser(args: GetOncallUserArgs, opts?: InvokeOptions): Promise<GetOncallUserResult>
    function getOncallUserOutput(args: GetOncallUserOutputArgs, opts?: InvokeOptions): Output<GetOncallUserResult>
    def get_oncall_user(username: Optional[str] = None,
                        opts: Optional[InvokeOptions] = None) -> GetOncallUserResult
    def get_oncall_user_output(username: Optional[pulumi.Input[str]] = None,
                        opts: Optional[InvokeOptions] = None) -> Output[GetOncallUserResult]
    func GetOncallUser(ctx *Context, args *GetOncallUserArgs, opts ...InvokeOption) (*GetOncallUserResult, error)
    func GetOncallUserOutput(ctx *Context, args *GetOncallUserOutputArgs, opts ...InvokeOption) GetOncallUserResultOutput

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

    public static class GetOncallUser 
    {
        public static Task<GetOncallUserResult> InvokeAsync(GetOncallUserArgs args, InvokeOptions? opts = null)
        public static Output<GetOncallUserResult> Invoke(GetOncallUserInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetOncallUserResult> getOncallUser(GetOncallUserArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: grafana:index/getOncallUser:getOncallUser
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Username string
    The username of the user.
    Username string
    The username of the user.
    username String
    The username of the user.
    username string
    The username of the user.
    username str
    The username of the user.
    username String
    The username of the user.

    getOncallUser Result

    The following output properties are available:

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

    Package Details

    Repository
    grafana pulumiverse/pulumi-grafana
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the grafana Terraform Provider.
    grafana logo
    Grafana v0.7.0 published on Tuesday, Nov 5, 2024 by pulumiverse