NamespacesOperations Class

Warning

DO NOT instantiate this class directly.

Instead, you should access the following operations through

EventHubManagementClient's

<xref:namespaces> attribute.

Inheritance
builtins.object
NamespacesOperations

Constructor

NamespacesOperations(*args, **kwargs)

Methods

begin_create_or_update

Creates or updates a namespace. Once created, this namespace's resource manifest is immutable. This operation is idempotent.

begin_delete

Deletes an existing namespace. This operation also removes all associated resources under the namespace.

check_name_availability

Check the give Namespace name availability.

create_or_update_authorization_rule

Creates or updates an AuthorizationRule for a Namespace.

create_or_update_ip_filter_rule

Creates or updates an IpFilterRule for a Namespace.

create_or_update_network_rule_set

Create or update NetworkRuleSet for a Namespace.

create_or_update_virtual_network_rule

Creates or updates an VirtualNetworkRule for a Namespace.

delete_authorization_rule

Deletes an AuthorizationRule for a Namespace.

delete_ip_filter_rule

Deletes an IpFilterRule for a Namespace.

delete_virtual_network_rule

Deletes an VirtualNetworkRule for a Namespace.

get

Gets the description of the specified namespace.

get_authorization_rule

Gets an AuthorizationRule for a Namespace by rule name.

get_ip_filter_rule

Gets an IpFilterRule for a Namespace by rule name.

get_network_rule_set

Gets NetworkRuleSet for a Namespace.

get_virtual_network_rule

Gets an VirtualNetworkRule for a Namespace by rule name.

list

Lists all the available Namespaces within a subscription, irrespective of the resource groups.

list_authorization_rules

Gets a list of authorization rules for a Namespace.

list_by_resource_group

Lists the available Namespaces within a resource group.

list_ip_filter_rules

Gets a list of IP Filter rules for a Namespace.

list_keys

Gets the primary and secondary connection strings for the Namespace.

list_virtual_network_rules

Gets a list of VirtualNetwork rules for a Namespace.

regenerate_keys

Regenerates the primary or secondary connection strings for the specified Namespace.

update

Creates or updates a namespace. Once created, this namespace's resource manifest is immutable. This operation is idempotent.

begin_create_or_update

Creates or updates a namespace. Once created, this namespace's resource manifest is immutable. This operation is idempotent.

async begin_create_or_update(resource_group_name: str, namespace_name: str, parameters: _models.EHNamespace, *, content_type: str = 'application/json', **kwargs: Any) -> AsyncLROPoller[_models.EHNamespace]

Parameters

Name Description
resource_group_name
Required
str

Name of the resource group within the azure subscription. Required.

namespace_name
Required
str

The Namespace name. Required.

parameters
Required

Parameters for creating a namespace resource. Is either a EHNamespace type or a IO type. Required.

Keyword-Only Parameters

Name Description
content_type
str

Body Parameter content-type. Known values are: 'application/json'. Default value is None.

cls

A custom type or function that will be passed the direct response

continuation_token
str

A continuation token to restart a poller from a saved state.

polling

By default, your polling method will be AsyncARMPolling. Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy.

polling_interval
int

Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

Type Description

An instance of AsyncLROPoller that returns either EHNamespace or the result of cls(response)

Exceptions

Type Description

begin_delete

Deletes an existing namespace. This operation also removes all associated resources under the namespace.

async begin_delete(resource_group_name: str, namespace_name: str, **kwargs: Any) -> AsyncLROPoller[None]

Parameters

Name Description
resource_group_name
Required
str

Name of the resource group within the azure subscription. Required.

namespace_name
Required
str

The Namespace name. Required.

Keyword-Only Parameters

Name Description
cls

A custom type or function that will be passed the direct response

continuation_token
str

A continuation token to restart a poller from a saved state.

polling

By default, your polling method will be AsyncARMPolling. Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy.

polling_interval
int

Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

Type Description

An instance of AsyncLROPoller that returns either None or the result of cls(response)

Exceptions

Type Description

check_name_availability

Check the give Namespace name availability.

async check_name_availability(parameters: _models.CheckNameAvailabilityParameter, *, content_type: str = 'application/json', **kwargs: Any) -> _models.CheckNameAvailabilityResult

Parameters

Name Description
parameters
Required

Parameters to check availability of the given Namespace name. Is either a CheckNameAvailabilityParameter type or a IO type. Required.

Keyword-Only Parameters

Name Description
content_type
str

Body Parameter content-type. Known values are: 'application/json'. Default value is None.

cls

A custom type or function that will be passed the direct response

Returns

Type Description

CheckNameAvailabilityResult or the result of cls(response)

Exceptions

Type Description

create_or_update_authorization_rule

Creates or updates an AuthorizationRule for a Namespace.

async create_or_update_authorization_rule(resource_group_name: str, namespace_name: str, authorization_rule_name: str, parameters: _models.AuthorizationRule, *, content_type: str = 'application/json', **kwargs: Any) -> _models.AuthorizationRule

Parameters

Name Description
resource_group_name
Required
str

Name of the resource group within the azure subscription. Required.

namespace_name
Required
str

The Namespace name. Required.

authorization_rule_name
Required
str

The authorization rule name. Required.

parameters
Required

The shared access AuthorizationRule. Is either a AuthorizationRule type or a IO type. Required.

Keyword-Only Parameters

Name Description
content_type
str

Body Parameter content-type. Known values are: 'application/json'. Default value is None.

cls

A custom type or function that will be passed the direct response

Returns

Type Description

AuthorizationRule or the result of cls(response)

Exceptions

Type Description

create_or_update_ip_filter_rule

Creates or updates an IpFilterRule for a Namespace.

async create_or_update_ip_filter_rule(resource_group_name: str, namespace_name: str, ip_filter_rule_name: str, parameters: _models.IpFilterRule, *, content_type: str = 'application/json', **kwargs: Any) -> _models.IpFilterRule

Parameters

Name Description
resource_group_name
Required
str

Name of the resource group within the azure subscription. Required.

namespace_name
Required
str

The Namespace name. Required.

ip_filter_rule_name
Required
str

The IP Filter Rule name. Required.

parameters
Required

The Namespace IpFilterRule. Is either a IpFilterRule type or a IO type. Required.

Keyword-Only Parameters

Name Description
content_type
str

Body Parameter content-type. Known values are: 'application/json'. Default value is None.

cls

A custom type or function that will be passed the direct response

Returns

Type Description

IpFilterRule or the result of cls(response)

Exceptions

Type Description

create_or_update_network_rule_set

Create or update NetworkRuleSet for a Namespace.

async create_or_update_network_rule_set(resource_group_name: str, namespace_name: str, parameters: _models.NetworkRuleSet, *, content_type: str = 'application/json', **kwargs: Any) -> _models.NetworkRuleSet

Parameters

Name Description
resource_group_name
Required
str

Name of the resource group within the azure subscription. Required.

namespace_name
Required
str

The Namespace name. Required.

parameters
Required

The Namespace IpFilterRule. Is either a NetworkRuleSet type or a IO type. Required.

Keyword-Only Parameters

Name Description
content_type
str

Body Parameter content-type. Known values are: 'application/json'. Default value is None.

cls

A custom type or function that will be passed the direct response

Returns

Type Description

NetworkRuleSet or the result of cls(response)

Exceptions

Type Description

create_or_update_virtual_network_rule

Creates or updates an VirtualNetworkRule for a Namespace.

async create_or_update_virtual_network_rule(resource_group_name: str, namespace_name: str, virtual_network_rule_name: str, parameters: _models.VirtualNetworkRule, *, content_type: str = 'application/json', **kwargs: Any) -> _models.VirtualNetworkRule

Parameters

Name Description
resource_group_name
Required
str

Name of the resource group within the azure subscription. Required.

namespace_name
Required
str

The Namespace name. Required.

virtual_network_rule_name
Required
str

The Virtual Network Rule name. Required.

parameters
Required

The Namespace VirtualNetworkRule. Is either a VirtualNetworkRule type or a IO type. Required.

Keyword-Only Parameters

Name Description
content_type
str

Body Parameter content-type. Known values are: 'application/json'. Default value is None.

cls

A custom type or function that will be passed the direct response

Returns

Type Description

VirtualNetworkRule or the result of cls(response)

Exceptions

Type Description

delete_authorization_rule

Deletes an AuthorizationRule for a Namespace.

async delete_authorization_rule(resource_group_name: str, namespace_name: str, authorization_rule_name: str, **kwargs: Any) -> None

Parameters

Name Description
resource_group_name
Required
str

Name of the resource group within the azure subscription. Required.

namespace_name
Required
str

The Namespace name. Required.

authorization_rule_name
Required
str

The authorization rule name. Required.

Keyword-Only Parameters

Name Description
cls

A custom type or function that will be passed the direct response

Returns

Type Description

None or the result of cls(response)

Exceptions

Type Description

delete_ip_filter_rule

Deletes an IpFilterRule for a Namespace.

async delete_ip_filter_rule(resource_group_name: str, namespace_name: str, ip_filter_rule_name: str, **kwargs: Any) -> None

Parameters

Name Description
resource_group_name
Required
str

Name of the resource group within the azure subscription. Required.

namespace_name
Required
str

The Namespace name. Required.

ip_filter_rule_name
Required
str

The IP Filter Rule name. Required.

Keyword-Only Parameters

Name Description
cls

A custom type or function that will be passed the direct response

Returns

Type Description

None or the result of cls(response)

Exceptions

Type Description

delete_virtual_network_rule

Deletes an VirtualNetworkRule for a Namespace.

async delete_virtual_network_rule(resource_group_name: str, namespace_name: str, virtual_network_rule_name: str, **kwargs: Any) -> None

Parameters

Name Description
resource_group_name
Required
str

Name of the resource group within the azure subscription. Required.

namespace_name
Required
str

The Namespace name. Required.

virtual_network_rule_name
Required
str

The Virtual Network Rule name. Required.

Keyword-Only Parameters

Name Description
cls

A custom type or function that will be passed the direct response

Returns

Type Description

None or the result of cls(response)

Exceptions

Type Description

get

Gets the description of the specified namespace.

async get(resource_group_name: str, namespace_name: str, **kwargs: Any) -> EHNamespace

Parameters

Name Description
resource_group_name
Required
str

Name of the resource group within the azure subscription. Required.

namespace_name
Required
str

The Namespace name. Required.

Keyword-Only Parameters

Name Description
cls

A custom type or function that will be passed the direct response

Returns

Type Description

EHNamespace or the result of cls(response)

Exceptions

Type Description

get_authorization_rule

Gets an AuthorizationRule for a Namespace by rule name.

async get_authorization_rule(resource_group_name: str, namespace_name: str, authorization_rule_name: str, **kwargs: Any) -> AuthorizationRule

Parameters

Name Description
resource_group_name
Required
str

Name of the resource group within the azure subscription. Required.

namespace_name
Required
str

The Namespace name. Required.

authorization_rule_name
Required
str

The authorization rule name. Required.

Keyword-Only Parameters

Name Description
cls

A custom type or function that will be passed the direct response

Returns

Type Description

AuthorizationRule or the result of cls(response)

Exceptions

Type Description

get_ip_filter_rule

Gets an IpFilterRule for a Namespace by rule name.

async get_ip_filter_rule(resource_group_name: str, namespace_name: str, ip_filter_rule_name: str, **kwargs: Any) -> IpFilterRule

Parameters

Name Description
resource_group_name
Required
str

Name of the resource group within the azure subscription. Required.

namespace_name
Required
str

The Namespace name. Required.

ip_filter_rule_name
Required
str

The IP Filter Rule name. Required.

Keyword-Only Parameters

Name Description
cls

A custom type or function that will be passed the direct response

Returns

Type Description

IpFilterRule or the result of cls(response)

Exceptions

Type Description

get_network_rule_set

Gets NetworkRuleSet for a Namespace.

async get_network_rule_set(resource_group_name: str, namespace_name: str, **kwargs: Any) -> NetworkRuleSet

Parameters

Name Description
resource_group_name
Required
str

Name of the resource group within the azure subscription. Required.

namespace_name
Required
str

The Namespace name. Required.

Keyword-Only Parameters

Name Description
cls

A custom type or function that will be passed the direct response

Returns

Type Description

NetworkRuleSet or the result of cls(response)

Exceptions

Type Description

get_virtual_network_rule

Gets an VirtualNetworkRule for a Namespace by rule name.

async get_virtual_network_rule(resource_group_name: str, namespace_name: str, virtual_network_rule_name: str, **kwargs: Any) -> VirtualNetworkRule

Parameters

Name Description
resource_group_name
Required
str

Name of the resource group within the azure subscription. Required.

namespace_name
Required
str

The Namespace name. Required.

virtual_network_rule_name
Required
str

The Virtual Network Rule name. Required.

Keyword-Only Parameters

Name Description
cls

A custom type or function that will be passed the direct response

Returns

Type Description

VirtualNetworkRule or the result of cls(response)

Exceptions

Type Description

list

Lists all the available Namespaces within a subscription, irrespective of the resource groups.

list(**kwargs: Any) -> AsyncIterable[EHNamespace]

Keyword-Only Parameters

Name Description
cls

A custom type or function that will be passed the direct response

Returns

Type Description

An iterator like instance of either EHNamespace or the result of cls(response)

Exceptions

Type Description

list_authorization_rules

Gets a list of authorization rules for a Namespace.

list_authorization_rules(resource_group_name: str, namespace_name: str, **kwargs: Any) -> AsyncIterable[AuthorizationRule]

Parameters

Name Description
resource_group_name
Required
str

Name of the resource group within the azure subscription. Required.

namespace_name
Required
str

The Namespace name. Required.

Keyword-Only Parameters

Name Description
cls

A custom type or function that will be passed the direct response

Returns

Type Description

An iterator like instance of either AuthorizationRule or the result of cls(response)

Exceptions

Type Description

list_by_resource_group

Lists the available Namespaces within a resource group.

list_by_resource_group(resource_group_name: str, **kwargs: Any) -> AsyncIterable[EHNamespace]

Parameters

Name Description
resource_group_name
Required
str

Name of the resource group within the azure subscription. Required.

Keyword-Only Parameters

Name Description
cls

A custom type or function that will be passed the direct response

Returns

Type Description

An iterator like instance of either EHNamespace or the result of cls(response)

Exceptions

Type Description

list_ip_filter_rules

Gets a list of IP Filter rules for a Namespace.

list_ip_filter_rules(resource_group_name: str, namespace_name: str, **kwargs: Any) -> AsyncIterable[IpFilterRule]

Parameters

Name Description
resource_group_name
Required
str

Name of the resource group within the azure subscription. Required.

namespace_name
Required
str

The Namespace name. Required.

Keyword-Only Parameters

Name Description
cls

A custom type or function that will be passed the direct response

Returns

Type Description

An iterator like instance of either IpFilterRule or the result of cls(response)

Exceptions

Type Description

list_keys

Gets the primary and secondary connection strings for the Namespace.

async list_keys(resource_group_name: str, namespace_name: str, authorization_rule_name: str, **kwargs: Any) -> AccessKeys

Parameters

Name Description
resource_group_name
Required
str

Name of the resource group within the azure subscription. Required.

namespace_name
Required
str

The Namespace name. Required.

authorization_rule_name
Required
str

The authorization rule name. Required.

Keyword-Only Parameters

Name Description
cls

A custom type or function that will be passed the direct response

Returns

Type Description

AccessKeys or the result of cls(response)

Exceptions

Type Description

list_virtual_network_rules

Gets a list of VirtualNetwork rules for a Namespace.

list_virtual_network_rules(resource_group_name: str, namespace_name: str, **kwargs: Any) -> AsyncIterable[VirtualNetworkRule]

Parameters

Name Description
resource_group_name
Required
str

Name of the resource group within the azure subscription. Required.

namespace_name
Required
str

The Namespace name. Required.

Keyword-Only Parameters

Name Description
cls

A custom type or function that will be passed the direct response

Returns

Type Description

An iterator like instance of either VirtualNetworkRule or the result of cls(response)

Exceptions

Type Description

regenerate_keys

Regenerates the primary or secondary connection strings for the specified Namespace.

async regenerate_keys(resource_group_name: str, namespace_name: str, authorization_rule_name: str, parameters: _models.RegenerateAccessKeyParameters, *, content_type: str = 'application/json', **kwargs: Any) -> _models.AccessKeys

Parameters

Name Description
resource_group_name
Required
str

Name of the resource group within the azure subscription. Required.

namespace_name
Required
str

The Namespace name. Required.

authorization_rule_name
Required
str

The authorization rule name. Required.

parameters
Required

Parameters required to regenerate the connection string. Is either a RegenerateAccessKeyParameters type or a IO type. Required.

Keyword-Only Parameters

Name Description
content_type
str

Body Parameter content-type. Known values are: 'application/json'. Default value is None.

cls

A custom type or function that will be passed the direct response

Returns

Type Description

AccessKeys or the result of cls(response)

Exceptions

Type Description

update

Creates or updates a namespace. Once created, this namespace's resource manifest is immutable. This operation is idempotent.

async update(resource_group_name: str, namespace_name: str, parameters: _models.EHNamespace, *, content_type: str = 'application/json', **kwargs: Any) -> _models.EHNamespace | None

Parameters

Name Description
resource_group_name
Required
str

Name of the resource group within the azure subscription. Required.

namespace_name
Required
str

The Namespace name. Required.

parameters
Required

Parameters for updating a namespace resource. Is either a EHNamespace type or a IO type. Required.

Keyword-Only Parameters

Name Description
content_type
str

Body Parameter content-type. Known values are: 'application/json'. Default value is None.

cls

A custom type or function that will be passed the direct response

Returns

Type Description

EHNamespace or None or the result of cls(response)

Exceptions

Type Description

Attributes

models

models = <module 'azure.mgmt.eventhub.v2018_01_01_preview.models' from 'C:\\hostedtoolcache\\windows\\Python\\3.11.9\\x64\\Lib\\site-packages\\azure\\mgmt\\eventhub\\v2018_01_01_preview\\models\\__init__.py'>