getNamespace

Use this data source to access information about an existing Notification Hub Namespace.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";
const example = azure.notificationhub.getNamespace({
name: "my-namespace",
resourceGroupName: "my-resource-group",
});
export const servicebusEndpoint = example.then(example => example.servicebusEndpoint);
import pulumi
import pulumi_azure as azure
example = azure.notificationhub.get_namespace(name="my-namespace",
resource_group_name="my-resource-group")
pulumi.export("servicebusEndpoint", example.servicebus_endpoint)
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Azure = Pulumi.Azure;
return await Deployment.RunAsync(() =>
{
var example = Azure.NotificationHub.GetNamespace.Invoke(new()
{
Name = "my-namespace",
ResourceGroupName = "my-resource-group",
});
return new Dictionary<string, object?>
{
["servicebusEndpoint"] = example.Apply(getNamespaceResult => getNamespaceResult.ServicebusEndpoint),
};
});
package main
import (
"github.com/pulumi/pulumi-azure/sdk/v6/go/azure/notificationhub"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
example, err := notificationhub.LookupNamespace(ctx, &notificationhub.LookupNamespaceArgs{
Name: "my-namespace",
ResourceGroupName: "my-resource-group",
}, nil)
if err != nil {
return err
}
ctx.Export("servicebusEndpoint", example.ServicebusEndpoint)
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azure.notificationhub.NotificationhubFunctions;
import com.pulumi.azure.notificationhub.inputs.GetNamespaceArgs;
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 example = NotificationhubFunctions.getNamespace(GetNamespaceArgs.builder()
.name("my-namespace")
.resourceGroupName("my-resource-group")
.build());
ctx.export("servicebusEndpoint", example.applyValue(getNamespaceResult -> getNamespaceResult.servicebusEndpoint()));
}
}
variables:
example:
fn::invoke:
function: azure:notificationhub:getNamespace
arguments:
name: my-namespace
resourceGroupName: my-resource-group
outputs:
servicebusEndpoint: ${example.servicebusEndpoint}

Return

A collection of values returned by getNamespace.

Parameters

argument

A collection of arguments for invoking getNamespace.


suspend fun getNamespace(name: String, resourceGroupName: String): GetNamespaceResult

Return

A collection of values returned by getNamespace.

Parameters

name

Specifies the Name of the Notification Hub Namespace.

resourceGroupName

Specifies the Name of the Resource Group within which the Notification Hub exists.

See also


Return

A collection of values returned by getNamespace.

Parameters

argument

Builder for com.pulumi.azure.notificationhub.kotlin.inputs.GetNamespacePlainArgs.

See also