GetNamespaceAuthorizationRule
Use this data source to access information about an existing ServiceBus Namespace Authorization Rule.
Example Usage
using Pulumi;
using Azure = Pulumi.Azure;
class MyStack : Stack
{
public MyStack()
{
var example = Output.Create(Azure.ServiceBus.GetNamespaceAuthorizationRule.InvokeAsync(new Azure.ServiceBus.GetNamespaceAuthorizationRuleArgs
{
Name = "examplerule",
NamespaceName = "examplenamespace",
ResourceGroupName = "example-resources",
}));
this.RuleId = example.Apply(example => example.Id);
}
[Output("ruleId")]
public Output<string> RuleId { get; set; }
}
package main
import (
"github.com/pulumi/pulumi-azure/sdk/v3/go/azure/servicebus"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
example, err := servicebus.LookupNamespaceAuthorizationRule(ctx, &servicebus.LookupNamespaceAuthorizationRuleArgs{
Name: "examplerule",
NamespaceName: "examplenamespace",
ResourceGroupName: "example-resources",
}, nil)
if err != nil {
return err
}
ctx.Export("ruleId", example.Id)
return nil
})
}import pulumi
import pulumi_azure as azure
example = azure.servicebus.get_namespace_authorization_rule(name="examplerule",
namespace_name="examplenamespace",
resource_group_name="example-resources")
pulumi.export("ruleId", example.id)import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";
const example = azure.servicebus.getNamespaceAuthorizationRule({
name: "examplerule",
namespaceName: "examplenamespace",
resourceGroupName: "example-resources",
});
export const ruleId = example.then(example => example.id);Using GetNamespaceAuthorizationRule
function getNamespaceAuthorizationRule(args: GetNamespaceAuthorizationRuleArgs, opts?: InvokeOptions): Promise<GetNamespaceAuthorizationRuleResult>function get_namespace_authorization_rule(name=None, namespace_name=None, resource_group_name=None, opts=None)func LookupNamespaceAuthorizationRule(ctx *Context, args *LookupNamespaceAuthorizationRuleArgs, opts ...InvokeOption) (*LookupNamespaceAuthorizationRuleResult, error)Note: This function is named
LookupNamespaceAuthorizationRulein the Go SDK.
public static class GetNamespaceAuthorizationRule {
public static Task<GetNamespaceAuthorizationRuleResult> InvokeAsync(GetNamespaceAuthorizationRuleArgs args, InvokeOptions? opts = null)
}The following arguments are supported:
- Name string
Specifies the name of the ServiceBus Namespace Authorization Rule.
- Namespace
Name string Specifies the name of the ServiceBus Namespace.
- Resource
Group stringName Specifies the name of the Resource Group where the ServiceBus Namespace exists.
- Name string
Specifies the name of the ServiceBus Namespace Authorization Rule.
- Namespace
Name string Specifies the name of the ServiceBus Namespace.
- Resource
Group stringName Specifies the name of the Resource Group where the ServiceBus Namespace exists.
- name string
Specifies the name of the ServiceBus Namespace Authorization Rule.
- namespace
Name string Specifies the name of the ServiceBus Namespace.
- resource
Group stringName Specifies the name of the Resource Group where the ServiceBus Namespace exists.
- name str
Specifies the name of the ServiceBus Namespace Authorization Rule.
- namespace_
name str Specifies the name of the ServiceBus Namespace.
- resource_
group_ strname Specifies the name of the Resource Group where the ServiceBus Namespace exists.
GetNamespaceAuthorizationRule Result
The following output properties are available:
- Id string
The provider-assigned unique ID for this managed resource.
- Name string
- Namespace
Name string - Primary
Connection stringString The primary connection string for the authorization rule.
- Primary
Key string The primary access key for the authorization rule.
- Resource
Group stringName - Secondary
Connection stringString The secondary connection string for the authorization rule.
- Secondary
Key string The secondary access key for the authorization rule.
- Id string
The provider-assigned unique ID for this managed resource.
- Name string
- Namespace
Name string - Primary
Connection stringString The primary connection string for the authorization rule.
- Primary
Key string The primary access key for the authorization rule.
- Resource
Group stringName - Secondary
Connection stringString The secondary connection string for the authorization rule.
- Secondary
Key string The secondary access key for the authorization rule.
- id string
The provider-assigned unique ID for this managed resource.
- name string
- namespace
Name string - primary
Connection stringString The primary connection string for the authorization rule.
- primary
Key string The primary access key for the authorization rule.
- resource
Group stringName - secondary
Connection stringString The secondary connection string for the authorization rule.
- secondary
Key string The secondary access key for the authorization rule.
- id str
The provider-assigned unique ID for this managed resource.
- name str
- namespace_
name str - primary_
connection_ strstring The primary connection string for the authorization rule.
- primary_
key str The primary access key for the authorization rule.
- resource_
group_ strname - secondary_
connection_ strstring The secondary connection string for the authorization rule.
- secondary_
key str The secondary access key for the authorization rule.
Package Details
- Repository
- https://github.com/pulumi/pulumi-azure
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
azurermTerraform Provider.