Namespace Authorization Rule
Response for POST requests that return single SharedAccessAuthorizationRule. Uses Azure REST API version 2023-10-01-preview. In version 2.x of the Azure Native provider, it used API version 2023-01-01-preview. Other available API versions: 2023-01-01-preview, 2023-09-01. These can be accessed by generating a local SDK package using the CLI command pulumi package add azure-native notificationhubs [ApiVersion]
. See the ../../../version-guide/#accessing-any-api-version-via-local-packages for details.
Example Usage
Namespaces_CreateOrUpdateAuthorizationRule
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var namespaceAuthorizationRule = new AzureNative.NotificationHubs.NamespaceAuthorizationRule("namespaceAuthorizationRule", new()
{
AuthorizationRuleName = "sdk-AuthRules-1788",
NamespaceName = "nh-sdk-ns",
ResourceGroupName = "5ktrial",
Rights = new[]
{
AzureNative.NotificationHubs.AccessRights.Listen,
AzureNative.NotificationHubs.AccessRights.Send,
},
});
});
package main
import (
notificationhubs "github.com/pulumi/pulumi-azure-native-sdk/notificationhubs/v3"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := notificationhubs.NewNamespaceAuthorizationRule(ctx, "namespaceAuthorizationRule", ¬ificationhubs.NamespaceAuthorizationRuleArgs{
AuthorizationRuleName: pulumi.String("sdk-AuthRules-1788"),
NamespaceName: pulumi.String("nh-sdk-ns"),
ResourceGroupName: pulumi.String("5ktrial"),
Rights: pulumi.StringArray{
pulumi.String(notificationhubs.AccessRightsListen),
pulumi.String(notificationhubs.AccessRightsSend),
},
})
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.azurenative.notificationhubs.NamespaceAuthorizationRule;
import com.pulumi.azurenative.notificationhubs.NamespaceAuthorizationRuleArgs;
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 namespaceAuthorizationRule = new NamespaceAuthorizationRule("namespaceAuthorizationRule", NamespaceAuthorizationRuleArgs.builder()
.authorizationRuleName("sdk-AuthRules-1788")
.namespaceName("nh-sdk-ns")
.resourceGroupName("5ktrial")
.rights(
"Listen",
"Send")
.build());
}
}
Import
An existing resource can be imported using its type token, name, and identifier, e.g.
$ pulumi import azure-native:notificationhubs:NamespaceAuthorizationRule NewAuthorizationRule /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NotificationHubs/namespaces/{namespaceName}/authorizationRules/{authorizationRuleName}
Properties
The Azure API version of the resource.
Gets a string that describes the claim value
Gets the created time for this rule
Gets the last modified time for this rule
Gets a base64-encoded 256-bit primary key for signing and validating the SAS token.
Gets a base64-encoded 256-bit primary key for signing and validating the SAS token.
Azure Resource Manager metadata containing createdBy and modifiedBy information.