azure-native.notificationhubs.NotificationHubAuthorizationRule
Explore with Pulumi AI
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 for details.
Create NotificationHubAuthorizationRule Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new NotificationHubAuthorizationRule(name: string, args: NotificationHubAuthorizationRuleArgs, opts?: CustomResourceOptions);
@overload
def NotificationHubAuthorizationRule(resource_name: str,
args: NotificationHubAuthorizationRuleArgs,
opts: Optional[ResourceOptions] = None)
@overload
def NotificationHubAuthorizationRule(resource_name: str,
opts: Optional[ResourceOptions] = None,
namespace_name: Optional[str] = None,
notification_hub_name: Optional[str] = None,
resource_group_name: Optional[str] = None,
rights: Optional[Sequence[Union[str, AccessRights]]] = None,
authorization_rule_name: Optional[str] = None,
location: Optional[str] = None,
primary_key: Optional[str] = None,
secondary_key: Optional[str] = None,
tags: Optional[Mapping[str, str]] = None)
func NewNotificationHubAuthorizationRule(ctx *Context, name string, args NotificationHubAuthorizationRuleArgs, opts ...ResourceOption) (*NotificationHubAuthorizationRule, error)
public NotificationHubAuthorizationRule(string name, NotificationHubAuthorizationRuleArgs args, CustomResourceOptions? opts = null)
public NotificationHubAuthorizationRule(String name, NotificationHubAuthorizationRuleArgs args)
public NotificationHubAuthorizationRule(String name, NotificationHubAuthorizationRuleArgs args, CustomResourceOptions options)
type: azure-native:notificationhubs:NotificationHubAuthorizationRule
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name
This property is required. string - The unique name of the resource.
- args
This property is required. NotificationHubAuthorizationRuleArgs - The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name
This property is required. str - The unique name of the resource.
- args
This property is required. NotificationHubAuthorizationRuleArgs - The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name
This property is required. string - The unique name of the resource.
- args
This property is required. NotificationHubAuthorizationRuleArgs - The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name
This property is required. string - The unique name of the resource.
- args
This property is required. NotificationHubAuthorizationRuleArgs - The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name
This property is required. String - The unique name of the resource.
- args
This property is required. NotificationHubAuthorizationRuleArgs - The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var notificationHubAuthorizationRuleResource = new AzureNative.NotificationHubs.NotificationHubAuthorizationRule("notificationHubAuthorizationRuleResource", new()
{
NamespaceName = "string",
NotificationHubName = "string",
ResourceGroupName = "string",
Rights = new[]
{
"string",
},
AuthorizationRuleName = "string",
Location = "string",
PrimaryKey = "string",
SecondaryKey = "string",
Tags =
{
{ "string", "string" },
},
});
example, err := notificationhubs.NewNotificationHubAuthorizationRule(ctx, "notificationHubAuthorizationRuleResource", ¬ificationhubs.NotificationHubAuthorizationRuleArgs{
NamespaceName: pulumi.String("string"),
NotificationHubName: pulumi.String("string"),
ResourceGroupName: pulumi.String("string"),
Rights: pulumi.StringArray{
pulumi.String("string"),
},
AuthorizationRuleName: pulumi.String("string"),
Location: pulumi.String("string"),
PrimaryKey: pulumi.String("string"),
SecondaryKey: pulumi.String("string"),
Tags: pulumi.StringMap{
"string": pulumi.String("string"),
},
})
var notificationHubAuthorizationRuleResource = new NotificationHubAuthorizationRule("notificationHubAuthorizationRuleResource", NotificationHubAuthorizationRuleArgs.builder()
.namespaceName("string")
.notificationHubName("string")
.resourceGroupName("string")
.rights("string")
.authorizationRuleName("string")
.location("string")
.primaryKey("string")
.secondaryKey("string")
.tags(Map.of("string", "string"))
.build());
notification_hub_authorization_rule_resource = azure_native.notificationhubs.NotificationHubAuthorizationRule("notificationHubAuthorizationRuleResource",
namespace_name="string",
notification_hub_name="string",
resource_group_name="string",
rights=["string"],
authorization_rule_name="string",
location="string",
primary_key="string",
secondary_key="string",
tags={
"string": "string",
})
const notificationHubAuthorizationRuleResource = new azure_native.notificationhubs.NotificationHubAuthorizationRule("notificationHubAuthorizationRuleResource", {
namespaceName: "string",
notificationHubName: "string",
resourceGroupName: "string",
rights: ["string"],
authorizationRuleName: "string",
location: "string",
primaryKey: "string",
secondaryKey: "string",
tags: {
string: "string",
},
});
type: azure-native:notificationhubs:NotificationHubAuthorizationRule
properties:
authorizationRuleName: string
location: string
namespaceName: string
notificationHubName: string
primaryKey: string
resourceGroupName: string
rights:
- string
secondaryKey: string
tags:
string: string
NotificationHubAuthorizationRule Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The NotificationHubAuthorizationRule resource accepts the following input properties:
- Namespace
Name This property is required. Changes to this property will trigger replacement.
- Namespace name
- Notification
Hub Name This property is required. Changes to this property will trigger replacement.
- Notification Hub name
- Resource
Group Name This property is required. Changes to this property will trigger replacement.
- The name of the resource group. The name is case insensitive.
- Rights
This property is required. List<Union<string, Pulumi.Azure Native. Notification Hubs. Access Rights>> - Gets or sets the rights associated with the rule.
Changes to this property will trigger replacement.
- Authorization Rule Name
- Location
Changes to this property will trigger replacement.
- Deprecated - only for compatibility.
- Primary
Key string - Gets a base64-encoded 256-bit primary key for signing and validating the SAS token.
- Secondary
Key string - Gets a base64-encoded 256-bit primary key for signing and validating the SAS token.
- Dictionary<string, string>
- Deprecated - only for compatibility.
- Namespace
Name This property is required. Changes to this property will trigger replacement.
- Namespace name
- Notification
Hub Name This property is required. Changes to this property will trigger replacement.
- Notification Hub name
- Resource
Group Name This property is required. Changes to this property will trigger replacement.
- The name of the resource group. The name is case insensitive.
- Rights
This property is required. []string - Gets or sets the rights associated with the rule.
Changes to this property will trigger replacement.
- Authorization Rule Name
- Location
Changes to this property will trigger replacement.
- Deprecated - only for compatibility.
- Primary
Key string - Gets a base64-encoded 256-bit primary key for signing and validating the SAS token.
- Secondary
Key string - Gets a base64-encoded 256-bit primary key for signing and validating the SAS token.
- map[string]string
- Deprecated - only for compatibility.
- namespace
Name This property is required. Changes to this property will trigger replacement.
- Namespace name
- notification
Hub Name This property is required. Changes to this property will trigger replacement.
- Notification Hub name
- resource
Group Name This property is required. Changes to this property will trigger replacement.
- The name of the resource group. The name is case insensitive.
- rights
This property is required. List<Either<String,AccessRights>> - Gets or sets the rights associated with the rule.
Changes to this property will trigger replacement.
- Authorization Rule Name
- location
Changes to this property will trigger replacement.
- Deprecated - only for compatibility.
- primary
Key String - Gets a base64-encoded 256-bit primary key for signing and validating the SAS token.
- secondary
Key String - Gets a base64-encoded 256-bit primary key for signing and validating the SAS token.
- Map<String,String>
- Deprecated - only for compatibility.
- namespace
Name This property is required. Changes to this property will trigger replacement.
- Namespace name
- notification
Hub Name This property is required. Changes to this property will trigger replacement.
- Notification Hub name
- resource
Group Name This property is required. Changes to this property will trigger replacement.
- The name of the resource group. The name is case insensitive.
- rights
This property is required. (string | AccessRights)[] - Gets or sets the rights associated with the rule.
Changes to this property will trigger replacement.
- Authorization Rule Name
- location
Changes to this property will trigger replacement.
- Deprecated - only for compatibility.
- primary
Key string - Gets a base64-encoded 256-bit primary key for signing and validating the SAS token.
- secondary
Key string - Gets a base64-encoded 256-bit primary key for signing and validating the SAS token.
- {[key: string]: string}
- Deprecated - only for compatibility.
- namespace_
name This property is required. Changes to this property will trigger replacement.
- Namespace name
- notification_
hub_ name This property is required. Changes to this property will trigger replacement.
- Notification Hub name
- resource_
group_ name This property is required. Changes to this property will trigger replacement.
- The name of the resource group. The name is case insensitive.
- rights
This property is required. Sequence[Union[str, AccessRights]] - Gets or sets the rights associated with the rule.
Changes to this property will trigger replacement.
- Authorization Rule Name
- location
Changes to this property will trigger replacement.
- Deprecated - only for compatibility.
- primary_
key str - Gets a base64-encoded 256-bit primary key for signing and validating the SAS token.
- secondary_
key str - Gets a base64-encoded 256-bit primary key for signing and validating the SAS token.
- Mapping[str, str]
- Deprecated - only for compatibility.
- namespace
Name This property is required. Changes to this property will trigger replacement.
- Namespace name
- notification
Hub Name This property is required. Changes to this property will trigger replacement.
- Notification Hub name
- resource
Group Name This property is required. Changes to this property will trigger replacement.
- The name of the resource group. The name is case insensitive.
- rights
This property is required. List<String | "Manage" | "Send" | "Listen"> - Gets or sets the rights associated with the rule.
Changes to this property will trigger replacement.
- Authorization Rule Name
- location
Changes to this property will trigger replacement.
- Deprecated - only for compatibility.
- primary
Key String - Gets a base64-encoded 256-bit primary key for signing and validating the SAS token.
- secondary
Key String - Gets a base64-encoded 256-bit primary key for signing and validating the SAS token.
- Map<String>
- Deprecated - only for compatibility.
Outputs
All input properties are implicitly available as output properties. Additionally, the NotificationHubAuthorizationRule resource produces the following output properties:
- Azure
Api stringVersion - The Azure API version of the resource.
- Claim
Type string - Gets a string that describes the claim type
- Claim
Value string - Gets a string that describes the claim value
- Created
Time string - Gets the created time for this rule
- Id string
- The provider-assigned unique ID for this managed resource.
- Key
Name string - Gets a string that describes the authorization rule.
- Modified
Time string - Gets the last modified time for this rule
- Name string
- The name of the resource
- Revision int
- Gets the revision number for the rule
- System
Data Pulumi.Azure Native. Notification Hubs. Outputs. System Data Response - Azure Resource Manager metadata containing createdBy and modifiedBy information.
- Type string
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- Azure
Api stringVersion - The Azure API version of the resource.
- Claim
Type string - Gets a string that describes the claim type
- Claim
Value string - Gets a string that describes the claim value
- Created
Time string - Gets the created time for this rule
- Id string
- The provider-assigned unique ID for this managed resource.
- Key
Name string - Gets a string that describes the authorization rule.
- Modified
Time string - Gets the last modified time for this rule
- Name string
- The name of the resource
- Revision int
- Gets the revision number for the rule
- System
Data SystemData Response - Azure Resource Manager metadata containing createdBy and modifiedBy information.
- Type string
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- azure
Api StringVersion - The Azure API version of the resource.
- claim
Type String - Gets a string that describes the claim type
- claim
Value String - Gets a string that describes the claim value
- created
Time String - Gets the created time for this rule
- id String
- The provider-assigned unique ID for this managed resource.
- key
Name String - Gets a string that describes the authorization rule.
- modified
Time String - Gets the last modified time for this rule
- name String
- The name of the resource
- revision Integer
- Gets the revision number for the rule
- system
Data SystemData Response - Azure Resource Manager metadata containing createdBy and modifiedBy information.
- type String
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- azure
Api stringVersion - The Azure API version of the resource.
- claim
Type string - Gets a string that describes the claim type
- claim
Value string - Gets a string that describes the claim value
- created
Time string - Gets the created time for this rule
- id string
- The provider-assigned unique ID for this managed resource.
- key
Name string - Gets a string that describes the authorization rule.
- modified
Time string - Gets the last modified time for this rule
- name string
- The name of the resource
- revision number
- Gets the revision number for the rule
- system
Data SystemData Response - Azure Resource Manager metadata containing createdBy and modifiedBy information.
- type string
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- azure_
api_ strversion - The Azure API version of the resource.
- claim_
type str - Gets a string that describes the claim type
- claim_
value str - Gets a string that describes the claim value
- created_
time str - Gets the created time for this rule
- id str
- The provider-assigned unique ID for this managed resource.
- key_
name str - Gets a string that describes the authorization rule.
- modified_
time str - Gets the last modified time for this rule
- name str
- The name of the resource
- revision int
- Gets the revision number for the rule
- system_
data SystemData Response - Azure Resource Manager metadata containing createdBy and modifiedBy information.
- type str
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- azure
Api StringVersion - The Azure API version of the resource.
- claim
Type String - Gets a string that describes the claim type
- claim
Value String - Gets a string that describes the claim value
- created
Time String - Gets the created time for this rule
- id String
- The provider-assigned unique ID for this managed resource.
- key
Name String - Gets a string that describes the authorization rule.
- modified
Time String - Gets the last modified time for this rule
- name String
- The name of the resource
- revision Number
- Gets the revision number for the rule
- system
Data Property Map - Azure Resource Manager metadata containing createdBy and modifiedBy information.
- type String
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
Supporting Types
AccessRights, AccessRightsArgs
- Manage
- Manage
- Send
- Send
- Listen
- Listen
- Access
Rights Manage - Manage
- Access
Rights Send - Send
- Access
Rights Listen - Listen
- Manage
- Manage
- Send
- Send
- Listen
- Listen
- Manage
- Manage
- Send
- Send
- Listen
- Listen
- MANAGE
- Manage
- SEND
- Send
- LISTEN
- Listen
- "Manage"
- Manage
- "Send"
- Send
- "Listen"
- Listen
SystemDataResponse, SystemDataResponseArgs
- Created
At string - The timestamp of resource creation (UTC).
- Created
By string - The identity that created the resource.
- Created
By stringType - The type of identity that created the resource.
- Last
Modified stringAt - The timestamp of resource last modification (UTC)
- Last
Modified stringBy - The identity that last modified the resource.
- Last
Modified stringBy Type - The type of identity that last modified the resource.
- Created
At string - The timestamp of resource creation (UTC).
- Created
By string - The identity that created the resource.
- Created
By stringType - The type of identity that created the resource.
- Last
Modified stringAt - The timestamp of resource last modification (UTC)
- Last
Modified stringBy - The identity that last modified the resource.
- Last
Modified stringBy Type - The type of identity that last modified the resource.
- created
At String - The timestamp of resource creation (UTC).
- created
By String - The identity that created the resource.
- created
By StringType - The type of identity that created the resource.
- last
Modified StringAt - The timestamp of resource last modification (UTC)
- last
Modified StringBy - The identity that last modified the resource.
- last
Modified StringBy Type - The type of identity that last modified the resource.
- created
At string - The timestamp of resource creation (UTC).
- created
By string - The identity that created the resource.
- created
By stringType - The type of identity that created the resource.
- last
Modified stringAt - The timestamp of resource last modification (UTC)
- last
Modified stringBy - The identity that last modified the resource.
- last
Modified stringBy Type - The type of identity that last modified the resource.
- created_
at str - The timestamp of resource creation (UTC).
- created_
by str - The identity that created the resource.
- created_
by_ strtype - The type of identity that created the resource.
- last_
modified_ strat - The timestamp of resource last modification (UTC)
- last_
modified_ strby - The identity that last modified the resource.
- last_
modified_ strby_ type - The type of identity that last modified the resource.
- created
At String - The timestamp of resource creation (UTC).
- created
By String - The identity that created the resource.
- created
By StringType - The type of identity that created the resource.
- last
Modified StringAt - The timestamp of resource last modification (UTC)
- last
Modified StringBy - The identity that last modified the resource.
- last
Modified StringBy Type - The type of identity that last modified the resource.
Import
An existing resource can be imported using its type token, name, and identifier, e.g.
$ pulumi import azure-native:notificationhubs:NotificationHubAuthorizationRule MyManageSharedAccessKey /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NotificationHubs/namespaces/{namespaceName}/notificationHubs/{notificationHubName}/authorizationRules/{authorizationRuleName}
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Azure Native pulumi/pulumi-azure-native
- License
- Apache-2.0