Skip to main content

Microsoft Azure Notificationhubs Management Client Library for Python

Project description

Microsoft Azure SDK for Python

This is the Microsoft Azure Notification Hubs Management Client Library. This package has been tested with Python 3.10+. For a more complete view of Azure libraries, see the azure sdk python release.

Disclaimer

Azure SDK Python packages support for Python 2.7 has ended 01 January 2022. For more information and questions, please refer to https://github.com/Azure/azure-sdk-for-python/issues/20691

Getting started

Prerequisites

Install the package

pip install azure-mgmt-notificationhubs
pip install azure-identity

Authentication

By default, Microsoft Entra token authentication depends on correct configuration of the following environment variables.

  • AZURE_CLIENT_ID for Azure client ID.
  • AZURE_TENANT_ID for Azure tenant ID.
  • AZURE_CLIENT_SECRET for Azure client secret.

In addition, Azure subscription ID can be configured via environment variable AZURE_SUBSCRIPTION_ID.

With above configuration, client can be authenticated by following code:

from azure.identity import DefaultAzureCredential
from azure.mgmt.notificationhubs import NotificationHubsManagementClient
import os

sub_id = os.getenv("AZURE_SUBSCRIPTION_ID")
client = NotificationHubsManagementClient(credential=DefaultAzureCredential(), subscription_id=sub_id)

Examples

Code samples for this package can be found at:

Troubleshooting

Next steps

Provide Feedback

If you encounter any bugs or have suggestions, please file an issue in the Issues section of the project.

Release History

8.1.0b3 (2026-07-08)

Features Added

  • Client NotificationHubsManagementClient added parameter cloud_setting in method __init__
  • Client NotificationHubsManagementClient added method send_request

Breaking Changes

  • This version introduces new hybrid models which have dual dictionary and model nature. Please follow https://aka.ms/azsdk/python/migrate/hybrid-models for migration.
  • Model AdmCredential moved instance variables client_id, client_secret and auth_token_url under property properties whose type is AdmCredentialProperties
  • Model ApnsCredential moved instance variables apns_certificate, certificate_key, endpoint, thumbprint, key_id, app_name, app_id and token under property properties whose type is ApnsCredentialProperties
  • Model BaiduCredential moved instance variables baidu_api_key, baidu_end_point and baidu_secret_key under property properties whose type is BaiduCredentialProperties
  • Model BrowserCredential moved instance variables subject, vapid_private_key and vapid_public_key under property properties whose type is BrowserCredentialProperties
  • Model DebugSendResponse moved instance variables success, failure and results under property properties whose type is DebugSendResult
  • Model FcmV1Credential moved instance variables client_email, private_key and project_id under property properties whose type is FcmV1CredentialProperties
  • Model GcmCredential moved instance variables gcm_endpoint and google_api_key under property properties whose type is GcmCredentialProperties
  • Model MpnsCredential moved instance variables mpns_certificate, certificate_key and thumbprint under property properties whose type is MpnsCredentialProperties
  • Model NamespaceResource moved instance variables name_properties_name, provisioning_state, status, enabled, critical, subscription_id, region, metric_id, created_at, updated_at, namespace_type, replication_region, zone_redundancy, network_acls, pns_credentials, service_bus_endpoint, private_endpoint_connections, scale_unit, data_center and public_network_access under property properties whose type is NamespaceProperties
  • Model NotificationHubPatchParameters moved instance variables name, registration_ttl, authorization_rules, apns_credential, wns_credential, gcm_credential, mpns_credential, adm_credential, baidu_credential, browser_credential, xiaomi_credential, fcm_v1_credential and daily_max_active_devices under property properties whose type is NotificationHubProperties
  • Model NotificationHubResource moved instance variables name_properties_name, registration_ttl, authorization_rules, apns_credential, wns_credential, gcm_credential, mpns_credential, adm_credential, baidu_credential, browser_credential, xiaomi_credential, fcm_v1_credential and daily_max_active_devices under property properties whose type is NotificationHubProperties
  • Model PnsCredentialsResource moved instance variables adm_credential, apns_credential, baidu_credential, browser_credential, gcm_credential, mpns_credential, wns_credential, xiaomi_credential and fcm_v1_credential under property properties whose type is PnsCredentials
  • Model SharedAccessAuthorizationRuleResource moved instance variables rights, primary_key, secondary_key, key_name, modified_time, created_time, claim_type, claim_value and revision under property properties whose type is SharedAccessAuthorizationRuleProperties
  • Model WnsCredential moved instance variables package_sid, secret_key, windows_live_endpoint, certificate_key and wns_certificate under property properties whose type is WnsCredentialProperties
  • Model XiaomiCredential moved instance variables app_secret and endpoint under property properties whose type is XiaomiCredentialProperties
  • Method NamespacesOperations.list changed its parameter skip_token from positional_or_keyword to keyword_only
  • Parameter top of NamespacesOperations.list is now optional
  • Method NamespacesOperations.list_all changed its parameter skip_token from positional_or_keyword to keyword_only
  • Parameter top of NamespacesOperations.list_all is now optional
  • Method NotificationHubsOperations.list changed its parameter skip_token from positional_or_keyword to keyword_only
  • Parameter top of NotificationHubsOperations.list is now optional

Other Changes

  • Deleted model NamespaceListResult/NotificationHubListResult/OperationListResult/PrivateEndpointConnectionResourceListResult/PrivateLinkResourceListResult/SharedAccessAuthorizationRuleListResult which actually were not used by SDK users
  • Deleted model ConnectionDetails/GroupConnectivityInformation/PrivateLinkServiceConnection which actually were not used by SDK users

8.1.0b2 (2024-03-21)

Features Added

  • Added operation NamespacesOperations.delete
  • Added operation NamespacesOperations.get_pns_credentials
  • Added operation NamespacesOperations.update
  • Added operation NotificationHubsOperations.update
  • Added operation group PrivateEndpointConnectionsOperations
  • Model CheckAvailabilityResult has a new parameter system_data
  • Model DebugSendResponse has a new parameter system_data
  • Model ErrorResponse has a new parameter error
  • Model NamespacePatchParameters has a new parameter properties
  • Model NamespaceResource has a new parameter network_acls
  • Model NamespaceResource has a new parameter pns_credentials
  • Model NamespaceResource has a new parameter private_endpoint_connections
  • Model NamespaceResource has a new parameter public_network_access
  • Model NamespaceResource has a new parameter replication_region
  • Model NamespaceResource has a new parameter system_data
  • Model NamespaceResource has a new parameter zone_redundancy
  • Model NotificationHubPatchParameters has a new parameter browser_credential
  • Model NotificationHubPatchParameters has a new parameter daily_max_active_devices
  • Model NotificationHubPatchParameters has a new parameter fcm_v1_credential
  • Model NotificationHubPatchParameters has a new parameter xiaomi_credential
  • Model NotificationHubResource has a new parameter browser_credential
  • Model NotificationHubResource has a new parameter daily_max_active_devices
  • Model NotificationHubResource has a new parameter fcm_v1_credential
  • Model NotificationHubResource has a new parameter system_data
  • Model NotificationHubResource has a new parameter xiaomi_credential
  • Model Operation has a new parameter is_data_action
  • Model Operation has a new parameter properties
  • Model OperationDisplay has a new parameter description
  • Model PnsCredentialsResource has a new parameter browser_credential
  • Model PnsCredentialsResource has a new parameter fcm_v1_credential
  • Model PnsCredentialsResource has a new parameter system_data
  • Model PnsCredentialsResource has a new parameter xiaomi_credential
  • Model Resource has a new parameter system_data
  • Model SharedAccessAuthorizationRuleResource has a new parameter system_data
  • Model WnsCredential has a new parameter certificate_key
  • Model WnsCredential has a new parameter wns_certificate
  • Operation NamespacesOperations.list has a new optional parameter skip_token
  • Operation NamespacesOperations.list has a new optional parameter top
  • Operation NamespacesOperations.list_all has a new optional parameter skip_token
  • Operation NamespacesOperations.list_all has a new optional parameter top
  • Operation NotificationHubsOperations.list has a new optional parameter skip_token
  • Operation NotificationHubsOperations.list has a new optional parameter top

Breaking Changes

  • Model DebugSendResponse no longer has parameter sku
  • Model ErrorResponse no longer has parameter code
  • Model ErrorResponse no longer has parameter message
  • Model NotificationHubPatchParameters no longer has parameter id
  • Model NotificationHubPatchParameters no longer has parameter location
  • Model NotificationHubPatchParameters no longer has parameter name_properties_name
  • Model NotificationHubPatchParameters no longer has parameter type
  • Model PnsCredentialsResource no longer has parameter sku
  • Model Resource no longer has parameter location
  • Model Resource no longer has parameter sku
  • Model Resource no longer has parameter tags
  • Model SharedAccessAuthorizationRuleResource no longer has parameter sku
  • Operation NotificationHubsOperations.debug_send no longer has parameter parameters
  • Parameter auth_token_url of model AdmCredential is now required
  • Parameter baidu_api_key of model BaiduCredential is now required
  • Parameter baidu_end_point of model BaiduCredential is now required
  • Parameter baidu_secret_key of model BaiduCredential is now required
  • Parameter certificate_key of model MpnsCredential is now required
  • Parameter client_id of model AdmCredential is now required
  • Parameter client_secret of model AdmCredential is now required
  • Parameter endpoint of model ApnsCredential is now required
  • Parameter google_api_key of model GcmCredential is now required
  • Parameter location of model NamespaceResource is now required
  • Parameter location of model NotificationHubResource is now required
  • Parameter mpns_certificate of model MpnsCredential is now required
  • Parameter rights of model SharedAccessAuthorizationRuleProperties is now required
  • Parameter sku of model NamespaceResource is now required
  • Parameter thumbprint of model MpnsCredential is now required
  • Removed operation NamespacesOperations.begin_delete
  • Removed operation NamespacesOperations.patch
  • Removed operation NotificationHubsOperations.patch
  • Renamed operation NamespacesOperations.create_or_update to NamespacesOperations.begin_create_or_update

8.1.0b1 (2022-11-11)

Other Changes

  • Added generated samples in github repo
  • Drop support for python<3.7.0

8.0.0 (2022-01-06)

Breaking changes

  • Return type of list_keys in NamespacesOperions changed from SharedAccessAuthorizationRuleListResult to ResourceListKeys

7.0.0 (2020-12-22)

  • GA release

7.0.0b1 (2020-10-28)

This is beta preview version.

This version uses a next-generation code generator that introduces important breaking changes, but also important new features (like unified authentication and async programming).

General breaking changes

  • Credential system has been completly revamped:

    • azure.common.credentials or msrestazure.azure_active_directory instances are no longer supported, use the azure-identity classes instead: https://pypi.org/project/azure-identity/
    • credentials parameter has been renamed credential
  • The config attribute no longer exists on a client, configuration should be passed as kwarg. Example: MyClient(credential, subscription_id, enable_logging=True). For a complete set of supported options, see the parameters accept in init documentation of azure-core

  • You can't import a version module anymore, use __version__ instead

  • Operations that used to return a msrest.polling.LROPoller now returns a azure.core.polling.LROPoller and are prefixed with begin_.

  • Exceptions tree have been simplified and most exceptions are now azure.core.exceptions.HttpResponseError (CloudError has been removed).

  • Most of the operation kwarg have changed. Some of the most noticeable:

General new features

  • Type annotations support using typing. SDKs are mypy ready.
  • This client has now stable and official support for async. Check the aio namespace of your package to find the async client.
  • This client now support natively tracing library like OpenCensus or OpenTelemetry. See this tracing quickstart for an overview.

2.1.0 (2019-04-30)

Features

  • Added operation NotificationHubsOperations.patch
  • Added operation NotificationHubsOperations.debug_send

2.0.0 (2018-05-25)

Features

  • Model NamespaceResource has a new parameter updated_at
  • Model NamespaceResource has a new parameter metric_id
  • Model NamespaceResource has a new parameter data_center
  • Model NamespaceCreateOrUpdateParameters has a new parameter updated_at
  • Model NamespaceCreateOrUpdateParameters has a new parameter metric_id
  • Model NamespaceCreateOrUpdateParameters has a new parameter data_center
  • Added operation NotificationHubsOperations.check_notification_hub_availability
  • Added operation group Operations
  • Client class can be used as a context manager to keep the underlying HTTP session open for performance

Breaking changes

  • Operation NotificationHubsOperations.create_or_update_authorization_rule has a new signature
  • Operation NamespacesOperations.create_or_update_authorization_rule has a new signature
  • Removed operation NotificationHubsOperations.check_availability (replaced by NotificationHubsOperations.check_notification_hub_availability)
  • Model SharedAccessAuthorizationRuleResource has a new signature
  • Model SharedAccessAuthorizationRuleProperties has a new signature
  • Model SharedAccessAuthorizationRuleCreateOrUpdateParameters has a new signature
  • Removed operation group NameOperations (replaced by NotificationHubsOperations.check_notification_hub_availability)
  • Removed operation group HubsOperations (merged in NotificationHubsOperations)

General Breaking changes

This version uses a next-generation code generator that might introduce breaking changes.

  • Model signatures now use only keyword-argument syntax. All positional arguments must be re-written as keyword-arguments. To keep auto-completion in most cases, models are now generated for Python 2 and Python 3. Python 3 uses the "*" syntax for keyword-only arguments.
  • Enum types now use the "str" mixin (class AzureEnum(str, Enum)) to improve the behavior when unrecognized enum values are encountered. While this is not a breaking change, the distinctions are important, and are documented here: https://docs.python.org/3/library/enum.html#others At a glance:
    • "is" should not be used at all.
    • "format" will return the string value, where "%s" string formatting will return NameOfEnum.stringvalue. Format syntax should be prefered.
  • New Long Running Operation:
    • Return type changes from msrestazure.azure_operation.AzureOperationPoller to msrest.polling.LROPoller. External API is the same.
    • Return type is now always a msrest.polling.LROPoller, regardless of the optional parameters used.
    • The behavior has changed when using raw=True. Instead of returning the initial call result as ClientRawResponse, without polling, now this returns an LROPoller. After polling, the final resource will be returned as a ClientRawResponse.
    • New polling parameter. The default behavior is Polling=True which will poll using ARM algorithm. When Polling=False, the response of the initial call will be returned without polling.
    • polling parameter accepts instances of subclasses of msrest.polling.PollingMethod.
    • add_done_callback will no longer raise if called after polling is finished, but will instead execute the callback right away.

Bugfixes

  • Compatibility of the sdist with wheel 0.31.0

1.0.0 (2017-06-27)

  • New API Version 2017-04-01
  • Expect breaking changes, migrating from an unstable client

This wheel package is built with the azure wheel extension

0.30.0 (2016-10-05)

  • Preview release. Based on API version 2016-03-01.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

azure_mgmt_notificationhubs-8.1.0b3.tar.gz (105.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

azure_mgmt_notificationhubs-8.1.0b3-py3-none-any.whl (102.1 kB view details)

Uploaded Python 3

File details

Details for the file azure_mgmt_notificationhubs-8.1.0b3.tar.gz.

File metadata

File hashes

Hashes for azure_mgmt_notificationhubs-8.1.0b3.tar.gz
Algorithm Hash digest
SHA256 cde85cb210dc8354ac0b8ad31e1af4f7194cdee1d2402d0e58515f730670a9d5
MD5 22ae67833427d65e36ec5d07a584ed74
BLAKE2b-256 85912159c8295df7e7ebe62696967bd0ee0f57eec7b08d110d3ea680eec2bc75

See more details on using hashes here.

File details

Details for the file azure_mgmt_notificationhubs-8.1.0b3-py3-none-any.whl.

File metadata

File hashes

Hashes for azure_mgmt_notificationhubs-8.1.0b3-py3-none-any.whl
Algorithm Hash digest
SHA256 0ec62d120a4dd76a29d9e67a58f7e91c48e75be45a7397c87650de90eab971d1
MD5 b706c644672cd1c791b330d1952771b0
BLAKE2b-256 2f5d406b689d8e76919fdb74d8b1857484c179d5c09bbd9fc99b53c1204c8ef7

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page