Skip to content

Commit

Permalink
azure-mgmt-notificationhubs 2.0.0 (#2610)
Browse files Browse the repository at this point in the history
* Generated from 7168a53201579dfb220af64389495a2e83d6f5ef (#2609)

Add suppressions for linting errors. Approved by Gaurav

* NotHubs auto packaging

* azure-mgmt-notificationhubs 2.0.0
  • Loading branch information
AutorestCI authored and lmazuel committed May 25, 2018
1 parent 3357a4f commit 3110473
Show file tree
Hide file tree
Showing 72 changed files with 2,444 additions and 764 deletions.
56 changes: 56 additions & 0 deletions azure-mgmt-notificationhubs/HISTORY.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,62 @@
Release History
===============

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)
++++++++++++++++++

Expand Down
6 changes: 3 additions & 3 deletions azure-mgmt-notificationhubs/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ This is the Microsoft Azure Notification Hubs Management Client Library.
Azure Resource Manager (ARM) is the next generation of management APIs that
replace the old Azure Service Management (ASM).

This package has been tested with Python 2.7, 3.3, 3.4, 3.5 and 3.6.
This package has been tested with Python 2.7, 3.4, 3.5 and 3.6.

For the older Azure Service Management (ASM) libraries, see
`azure-servicemanagement-legacy <https://pypi.python.org/pypi/azure-servicemanagement-legacy>`__ library.
Expand Down Expand Up @@ -37,8 +37,8 @@ Usage
=====

For code examples, see `Notification Hubs Management
<https://azure-sdk-for-python.readthedocs.org/en/latest/sample_azure-mgmt-notificationhubs.html>`__
on readthedocs.org.
<https://docs.microsoft.com/python/api/overview/azure/notification-hubs>`__
on docs.microsoft.com.


Provide Feedback
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,30 +9,61 @@
# regenerated.
# --------------------------------------------------------------------------

from .check_name_availability_request_parameters import CheckNameAvailabilityRequestParameters
from .check_name_availability_response import CheckNameAvailabilityResponse
from .sku import Sku
from .check_availability_parameters import CheckAvailabilityParameters
from .check_availability_result import CheckAvailabilityResult
from .namespace_create_or_update_parameters import NamespaceCreateOrUpdateParameters
from .namespace_patch_parameters import NamespacePatchParameters
from .namespace_resource import NamespaceResource
from .shared_access_authorization_rule_properties import SharedAccessAuthorizationRuleProperties
from .shared_access_authorization_rule_create_or_update_parameters import SharedAccessAuthorizationRuleCreateOrUpdateParameters
from .shared_access_authorization_rule_resource import SharedAccessAuthorizationRuleResource
from .resource_list_keys import ResourceListKeys
from .policykey_resource import PolicykeyResource
from .apns_credential import ApnsCredential
from .wns_credential import WnsCredential
from .gcm_credential import GcmCredential
from .mpns_credential import MpnsCredential
from .adm_credential import AdmCredential
from .baidu_credential import BaiduCredential
from .notification_hub_create_or_update_parameters import NotificationHubCreateOrUpdateParameters
from .notification_hub_resource import NotificationHubResource
from .pns_credentials_resource import PnsCredentialsResource
from .resource import Resource
from .sub_resource import SubResource
try:
from .operation_display_py3 import OperationDisplay
from .operation_py3 import Operation
from .error_response_py3 import ErrorResponse, ErrorResponseException
from .sku_py3 import Sku
from .check_availability_parameters_py3 import CheckAvailabilityParameters
from .check_availability_result_py3 import CheckAvailabilityResult
from .namespace_create_or_update_parameters_py3 import NamespaceCreateOrUpdateParameters
from .namespace_patch_parameters_py3 import NamespacePatchParameters
from .namespace_resource_py3 import NamespaceResource
from .shared_access_authorization_rule_properties_py3 import SharedAccessAuthorizationRuleProperties
from .shared_access_authorization_rule_create_or_update_parameters_py3 import SharedAccessAuthorizationRuleCreateOrUpdateParameters
from .shared_access_authorization_rule_resource_py3 import SharedAccessAuthorizationRuleResource
from .shared_access_authorization_rule_list_result_py3 import SharedAccessAuthorizationRuleListResult
from .resource_list_keys_py3 import ResourceListKeys
from .policykey_resource_py3 import PolicykeyResource
from .apns_credential_py3 import ApnsCredential
from .wns_credential_py3 import WnsCredential
from .gcm_credential_py3 import GcmCredential
from .mpns_credential_py3 import MpnsCredential
from .adm_credential_py3 import AdmCredential
from .baidu_credential_py3 import BaiduCredential
from .notification_hub_create_or_update_parameters_py3 import NotificationHubCreateOrUpdateParameters
from .notification_hub_resource_py3 import NotificationHubResource
from .pns_credentials_resource_py3 import PnsCredentialsResource
from .resource_py3 import Resource
from .sub_resource_py3 import SubResource
except (SyntaxError, ImportError):
from .operation_display import OperationDisplay
from .operation import Operation
from .error_response import ErrorResponse, ErrorResponseException
from .sku import Sku
from .check_availability_parameters import CheckAvailabilityParameters
from .check_availability_result import CheckAvailabilityResult
from .namespace_create_or_update_parameters import NamespaceCreateOrUpdateParameters
from .namespace_patch_parameters import NamespacePatchParameters
from .namespace_resource import NamespaceResource
from .shared_access_authorization_rule_properties import SharedAccessAuthorizationRuleProperties
from .shared_access_authorization_rule_create_or_update_parameters import SharedAccessAuthorizationRuleCreateOrUpdateParameters
from .shared_access_authorization_rule_resource import SharedAccessAuthorizationRuleResource
from .shared_access_authorization_rule_list_result import SharedAccessAuthorizationRuleListResult
from .resource_list_keys import ResourceListKeys
from .policykey_resource import PolicykeyResource
from .apns_credential import ApnsCredential
from .wns_credential import WnsCredential
from .gcm_credential import GcmCredential
from .mpns_credential import MpnsCredential
from .adm_credential import AdmCredential
from .baidu_credential import BaiduCredential
from .notification_hub_create_or_update_parameters import NotificationHubCreateOrUpdateParameters
from .notification_hub_resource import NotificationHubResource
from .pns_credentials_resource import PnsCredentialsResource
from .resource import Resource
from .sub_resource import SubResource
from .operation_paged import OperationPaged
from .namespace_resource_paged import NamespaceResourcePaged
from .shared_access_authorization_rule_resource_paged import SharedAccessAuthorizationRuleResourcePaged
from .notification_hub_resource_paged import NotificationHubResourcePaged
Expand All @@ -43,8 +74,9 @@
)

__all__ = [
'CheckNameAvailabilityRequestParameters',
'CheckNameAvailabilityResponse',
'OperationDisplay',
'Operation',
'ErrorResponse', 'ErrorResponseException',
'Sku',
'CheckAvailabilityParameters',
'CheckAvailabilityResult',
Expand All @@ -54,6 +86,7 @@
'SharedAccessAuthorizationRuleProperties',
'SharedAccessAuthorizationRuleCreateOrUpdateParameters',
'SharedAccessAuthorizationRuleResource',
'SharedAccessAuthorizationRuleListResult',
'ResourceListKeys',
'PolicykeyResource',
'ApnsCredential',
Expand All @@ -67,6 +100,7 @@
'PnsCredentialsResource',
'Resource',
'SubResource',
'OperationPaged',
'NamespaceResourcePaged',
'SharedAccessAuthorizationRuleResourcePaged',
'NotificationHubResourcePaged',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,8 @@ class AdmCredential(Model):
'auth_token_url': {'key': 'properties.authTokenUrl', 'type': 'str'},
}

def __init__(self, client_id=None, client_secret=None, auth_token_url=None):
self.client_id = client_id
self.client_secret = client_secret
self.auth_token_url = auth_token_url
def __init__(self, **kwargs):
super(AdmCredential, self).__init__(**kwargs)
self.client_id = kwargs.get('client_id', None)
self.client_secret = kwargs.get('client_secret', None)
self.auth_token_url = kwargs.get('auth_token_url', None)
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from msrest.serialization import Model


class AdmCredential(Model):
"""Description of a NotificationHub AdmCredential.
:param client_id: The client identifier.
:type client_id: str
:param client_secret: The credential secret access key.
:type client_secret: str
:param auth_token_url: The URL of the authorization token.
:type auth_token_url: str
"""

_attribute_map = {
'client_id': {'key': 'properties.clientId', 'type': 'str'},
'client_secret': {'key': 'properties.clientSecret', 'type': 'str'},
'auth_token_url': {'key': 'properties.authTokenUrl', 'type': 'str'},
}

def __init__(self, *, client_id: str=None, client_secret: str=None, auth_token_url: str=None, **kwargs) -> None:
super(AdmCredential, self).__init__(**kwargs)
self.client_id = client_id
self.client_secret = client_secret
self.auth_token_url = auth_token_url
Original file line number Diff line number Diff line change
Expand Up @@ -47,12 +47,13 @@ class ApnsCredential(Model):
'token': {'key': 'properties.token', 'type': 'str'},
}

def __init__(self, apns_certificate=None, certificate_key=None, endpoint=None, thumbprint=None, key_id=None, app_name=None, app_id=None, token=None):
self.apns_certificate = apns_certificate
self.certificate_key = certificate_key
self.endpoint = endpoint
self.thumbprint = thumbprint
self.key_id = key_id
self.app_name = app_name
self.app_id = app_id
self.token = token
def __init__(self, **kwargs):
super(ApnsCredential, self).__init__(**kwargs)
self.apns_certificate = kwargs.get('apns_certificate', None)
self.certificate_key = kwargs.get('certificate_key', None)
self.endpoint = kwargs.get('endpoint', None)
self.thumbprint = kwargs.get('thumbprint', None)
self.key_id = kwargs.get('key_id', None)
self.app_name = kwargs.get('app_name', None)
self.app_id = kwargs.get('app_id', None)
self.token = kwargs.get('token', None)
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from msrest.serialization import Model


class ApnsCredential(Model):
"""Description of a NotificationHub ApnsCredential.
:param apns_certificate: The APNS certificate.
:type apns_certificate: str
:param certificate_key: The certificate key.
:type certificate_key: str
:param endpoint: The endpoint of this credential.
:type endpoint: str
:param thumbprint: The Apns certificate Thumbprint
:type thumbprint: str
:param key_id: A 10-character key identifier (kid) key, obtained from your
developer account
:type key_id: str
:param app_name: The name of the application
:type app_name: str
:param app_id: The issuer (iss) registered claim key, whose value is your
10-character Team ID, obtained from your developer account
:type app_id: str
:param token: Provider Authentication Token, obtained through your
developer account
:type token: str
"""

_attribute_map = {
'apns_certificate': {'key': 'properties.apnsCertificate', 'type': 'str'},
'certificate_key': {'key': 'properties.certificateKey', 'type': 'str'},
'endpoint': {'key': 'properties.endpoint', 'type': 'str'},
'thumbprint': {'key': 'properties.thumbprint', 'type': 'str'},
'key_id': {'key': 'properties.keyId', 'type': 'str'},
'app_name': {'key': 'properties.appName', 'type': 'str'},
'app_id': {'key': 'properties.appId', 'type': 'str'},
'token': {'key': 'properties.token', 'type': 'str'},
}

def __init__(self, *, apns_certificate: str=None, certificate_key: str=None, endpoint: str=None, thumbprint: str=None, key_id: str=None, app_name: str=None, app_id: str=None, token: str=None, **kwargs) -> None:
super(ApnsCredential, self).__init__(**kwargs)
self.apns_certificate = apns_certificate
self.certificate_key = certificate_key
self.endpoint = endpoint
self.thumbprint = thumbprint
self.key_id = key_id
self.app_name = app_name
self.app_id = app_id
self.token = token
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,8 @@ class BaiduCredential(Model):
'baidu_secret_key': {'key': 'properties.baiduSecretKey', 'type': 'str'},
}

def __init__(self, baidu_api_key=None, baidu_end_point=None, baidu_secret_key=None):
self.baidu_api_key = baidu_api_key
self.baidu_end_point = baidu_end_point
self.baidu_secret_key = baidu_secret_key
def __init__(self, **kwargs):
super(BaiduCredential, self).__init__(**kwargs)
self.baidu_api_key = kwargs.get('baidu_api_key', None)
self.baidu_end_point = kwargs.get('baidu_end_point', None)
self.baidu_secret_key = kwargs.get('baidu_secret_key', None)
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------

from msrest.serialization import Model


class BaiduCredential(Model):
"""Description of a NotificationHub BaiduCredential.
:param baidu_api_key: Baidu Api Key.
:type baidu_api_key: str
:param baidu_end_point: Baidu Endpoint.
:type baidu_end_point: str
:param baidu_secret_key: Baidu Secret Key
:type baidu_secret_key: str
"""

_attribute_map = {
'baidu_api_key': {'key': 'properties.baiduApiKey', 'type': 'str'},
'baidu_end_point': {'key': 'properties.baiduEndPoint', 'type': 'str'},
'baidu_secret_key': {'key': 'properties.baiduSecretKey', 'type': 'str'},
}

def __init__(self, *, baidu_api_key: str=None, baidu_end_point: str=None, baidu_secret_key: str=None, **kwargs) -> None:
super(BaiduCredential, self).__init__(**kwargs)
self.baidu_api_key = baidu_api_key
self.baidu_end_point = baidu_end_point
self.baidu_secret_key = baidu_secret_key
Loading

0 comments on commit 3110473

Please sign in to comment.