Viewing docs for Grafana v2.21.0
published on Tuesday, Mar 3, 2026 by pulumiverse
published on Tuesday, Mar 3, 2026 by pulumiverse
Viewing docs for Grafana v2.21.0
published on Tuesday, Mar 3, 2026 by pulumiverse
published on Tuesday, Mar 3, 2026 by pulumiverse
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as grafana from "@pulumiverse/grafana";
const test = new grafana.oss.Organization("test", {
name: "test-org",
adminUser: "admin",
createUsers: true,
viewers: [
"viewer-01@example.com",
"viewer-02@example.com",
],
});
const fromName = grafana.oss.getOrganizationOutput({
name: test.name,
});
import pulumi
import pulumi_grafana as grafana
import pulumiverse_grafana as grafana
test = grafana.oss.Organization("test",
name="test-org",
admin_user="admin",
create_users=True,
viewers=[
"viewer-01@example.com",
"viewer-02@example.com",
])
from_name = grafana.oss.get_organization_output(name=test.name)
package main
import (
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/pulumiverse/pulumi-grafana/sdk/v2/go/grafana/oss"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
test, err := oss.NewOrganization(ctx, "test", &oss.OrganizationArgs{
Name: pulumi.String("test-org"),
AdminUser: pulumi.String("admin"),
CreateUsers: pulumi.Bool(true),
Viewers: pulumi.StringArray{
pulumi.String("viewer-01@example.com"),
pulumi.String("viewer-02@example.com"),
},
})
if err != nil {
return err
}
_ = oss.LookupOrganizationOutput(ctx, oss.GetOrganizationOutputArgs{
Name: test.Name,
}, nil)
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Grafana = Pulumi.Grafana;
using Grafana = Pulumiverse.Grafana;
return await Deployment.RunAsync(() =>
{
var test = new Grafana.Oss.Organization("test", new()
{
Name = "test-org",
AdminUser = "admin",
CreateUsers = true,
Viewers = new[]
{
"viewer-01@example.com",
"viewer-02@example.com",
},
});
var fromName = Grafana.Oss.GetOrganization.Invoke(new()
{
Name = test.Name,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.grafana.oss.Organization;
import com.pulumi.grafana.oss.OrganizationArgs;
import com.pulumi.grafana.oss.OssFunctions;
import com.pulumi.grafana.oss.inputs.GetOrganizationArgs;
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) {
var test = new Organization("test", OrganizationArgs.builder()
.name("test-org")
.adminUser("admin")
.createUsers(true)
.viewers(
"viewer-01@example.com",
"viewer-02@example.com")
.build());
final var fromName = OssFunctions.getOrganization(GetOrganizationArgs.builder()
.name(test.name())
.build());
}
}
resources:
test:
type: grafana:oss:Organization
properties:
name: test-org
adminUser: admin
createUsers: true
viewers:
- viewer-01@example.com
- viewer-02@example.com
variables:
fromName:
fn::invoke:
function: grafana:oss:getOrganization
arguments:
name: ${test.name}
Using getOrganization
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 getOrganization(args: GetOrganizationArgs, opts?: InvokeOptions): Promise<GetOrganizationResult>
function getOrganizationOutput(args: GetOrganizationOutputArgs, opts?: InvokeOptions): Output<GetOrganizationResult>def get_organization(name: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetOrganizationResult
def get_organization_output(name: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetOrganizationResult]func LookupOrganization(ctx *Context, args *LookupOrganizationArgs, opts ...InvokeOption) (*LookupOrganizationResult, error)
func LookupOrganizationOutput(ctx *Context, args *LookupOrganizationOutputArgs, opts ...InvokeOption) LookupOrganizationResultOutput> Note: This function is named LookupOrganization in the Go SDK.
public static class GetOrganization
{
public static Task<GetOrganizationResult> InvokeAsync(GetOrganizationArgs args, InvokeOptions? opts = null)
public static Output<GetOrganizationResult> Invoke(GetOrganizationInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetOrganizationResult> getOrganization(GetOrganizationArgs args, InvokeOptions options)
public static Output<GetOrganizationResult> getOrganization(GetOrganizationArgs args, InvokeOptions options)
fn::invoke:
function: grafana:oss/getOrganization:getOrganization
arguments:
# arguments dictionaryThe following arguments are supported:
- Name string
- The name of the Organization.
- Name string
- The name of the Organization.
- name String
- The name of the Organization.
- name string
- The name of the Organization.
- name str
- The name of the Organization.
- name String
- The name of the Organization.
getOrganization Result
The following output properties are available:
- Admins List<string>
- A list of email addresses corresponding to users given admin access to the organization.
- Editors List<string>
- A list of email addresses corresponding to users given editor access to the organization.
- Id string
- The provider-assigned unique ID for this managed resource.
- Name string
- The name of the Organization.
- Viewers List<string>
- A list of email addresses corresponding to users given viewer access to the organization.
- Admins []string
- A list of email addresses corresponding to users given admin access to the organization.
- Editors []string
- A list of email addresses corresponding to users given editor access to the organization.
- Id string
- The provider-assigned unique ID for this managed resource.
- Name string
- The name of the Organization.
- Viewers []string
- A list of email addresses corresponding to users given viewer access to the organization.
- admins List<String>
- A list of email addresses corresponding to users given admin access to the organization.
- editors List<String>
- A list of email addresses corresponding to users given editor access to the organization.
- id String
- The provider-assigned unique ID for this managed resource.
- name String
- The name of the Organization.
- viewers List<String>
- A list of email addresses corresponding to users given viewer access to the organization.
- admins string[]
- A list of email addresses corresponding to users given admin access to the organization.
- editors string[]
- A list of email addresses corresponding to users given editor access to the organization.
- id string
- The provider-assigned unique ID for this managed resource.
- name string
- The name of the Organization.
- viewers string[]
- A list of email addresses corresponding to users given viewer access to the organization.
- admins Sequence[str]
- A list of email addresses corresponding to users given admin access to the organization.
- editors Sequence[str]
- A list of email addresses corresponding to users given editor access to the organization.
- id str
- The provider-assigned unique ID for this managed resource.
- name str
- The name of the Organization.
- viewers Sequence[str]
- A list of email addresses corresponding to users given viewer access to the organization.
- admins List<String>
- A list of email addresses corresponding to users given admin access to the organization.
- editors List<String>
- A list of email addresses corresponding to users given editor access to the organization.
- id String
- The provider-assigned unique ID for this managed resource.
- name String
- The name of the Organization.
- viewers List<String>
- A list of email addresses corresponding to users given viewer access to the organization.
Package Details
- Repository
- grafana pulumiverse/pulumi-grafana
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
grafanaTerraform Provider.
Viewing docs for Grafana v2.21.0
published on Tuesday, Mar 3, 2026 by pulumiverse
published on Tuesday, Mar 3, 2026 by pulumiverse
