Skip to content

Commit

Permalink
Update from release/v3
Browse files Browse the repository at this point in the history
  • Loading branch information
SDK Automation committed Aug 26, 2020
1 parent 52bdd94 commit 7a490a6
Show file tree
Hide file tree
Showing 63 changed files with 3,158 additions and 2,482 deletions.
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
recursive-include tests *.py *.yaml
include *.md
include azure/__init__.py
include azure/mgmt/__init__.py
Expand Down
30 changes: 11 additions & 19 deletions sdk/managementgroups/azure-mgmt-managementgroups/README.md
Original file line number Diff line number Diff line change
@@ -1,29 +1,21 @@
## Microsoft Azure SDK for Python
# Microsoft Azure SDK for Python

This is the Microsoft Azure Management Groups Client Library.
This package has been tested with Python 2.7, 3.5, 3.6, 3.7 and 3.8.
For a more complete view of Azure libraries, see the [Github repo](https://github.com/Azure/azure-sdk-for-python/)

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.4, 3.5, 3.6 and 3.7.
# Usage

For the older Azure Service Management (ASM) libraries, see
[azure-servicemanagement-legacy](https://pypi.python.org/pypi/azure-servicemanagement-legacy)
library.
For code examples, see [Management Groups](https://docs.microsoft.com/python/api/overview/azure/)
on docs.microsoft.com.

For a more complete set of Azure libraries, see the
[azure sdk python release](https://aka.ms/azsdk/python/all).

## Usage
# Provide Feedback

For code examples, see [Management
Groups](https://docs.microsoft.com/python/api/overview/azure/) on
docs.microsoft.com.

## Provide Feedback

If you encounter any bugs or have suggestions, please file an issue in
the [Issues](https://github.com/Azure/azure-sdk-for-python/issues)
If you encounter any bugs or have suggestions, please file an issue in the
[Issues](https://github.com/Azure/azure-sdk-for-python/issues)
section of the project.

![image](https://azure-sdk-impressions.azurewebsites.net/api/impressions/azure-sdk-for-python%2Fazure-mgmt-managementgroups%2FREADME.png)

![Impressions](https://azure-sdk-impressions.azurewebsites.net/api/impressions/azure-sdk-for-python%2Fazure-mgmt-managementgroups%2FREADME.png)
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,11 @@
# regenerated.
# --------------------------------------------------------------------------

from .management_groups_api import ManagementGroupsAPI
from .version import VERSION
from ._configuration import ManagementGroupsAPIConfiguration
from ._management_groups_api import ManagementGroupsAPI
__all__ = ['ManagementGroupsAPI', 'ManagementGroupsAPIConfiguration']

__all__ = ['ManagementGroupsAPI']
from .version import VERSION

__version__ = VERSION

Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
# 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 msrestazure import AzureConfiguration

from .version import VERSION


class ManagementGroupsAPIConfiguration(AzureConfiguration):
"""Configuration for ManagementGroupsAPI
Note that all parameters used to create this instance are saved as instance
attributes.
:param credentials: Credentials needed for the client to connect to Azure.
:type credentials: :mod:`A msrestazure Credentials
object<msrestazure.azure_active_directory>`
:param operation_result_id: The id of the operation result. Possible
values include: 'create', 'delete'
:type operation_result_id: str
:param skip: Number of entities to skip over when retrieving results.
Passing this in will override $skipToken.
:type skip: int
:param top: Number of elements to return when retrieving results. Passing
this in will override $skipToken.
:type top: int
:param skiptoken: Page continuation token is only used if a previous
operation returned a partial result.
If a previous response contains a nextLink element, the value of the
nextLink element will include a token parameter that specifies a starting
point to use for subsequent calls.
:type skiptoken: str
:param str base_url: Service URL
"""

def __init__(
self, credentials, operation_result_id, skip=None, top=None, skiptoken=None, base_url=None):

if credentials is None:
raise ValueError("Parameter 'credentials' must not be None.")
if operation_result_id is None:
raise ValueError("Parameter 'operation_result_id' must not be None.")
if not base_url:
base_url = 'https://management.azure.com'

super(ManagementGroupsAPIConfiguration, self).__init__(base_url)

# Starting Autorest.Python 4.0.64, make connection pool activated by default
self.keep_alive = True

self.add_user_agent('azure-mgmt-managementgroups/{}'.format(VERSION))
self.add_user_agent('Azure-SDK-For-Python')

self.credentials = credentials
self.operation_result_id = operation_result_id
self.skip = skip
self.top = top
self.skiptoken = skiptoken
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
# 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.service_client import SDKClient
from msrest import Serializer, Deserializer

from ._configuration import ManagementGroupsAPIConfiguration
from .operations import ManagementGroupsAPIOperationsMixin
from .operations import ManagementGroupsOperations
from .operations import ManagementGroupSubscriptionsOperations
from .operations import HierarchySettingsOperations
from .operations import Operations
from .operations import EntitiesOperations
from . import models


class ManagementGroupsAPI(ManagementGroupsAPIOperationsMixin, SDKClient):
"""The Azure Management Groups API enables consolidation of multiple
subscriptions/resources into an organizational hierarchy and centrally
manage access control, policies, alerting and reporting for those resources.
:ivar config: Configuration for client.
:vartype config: ManagementGroupsAPIConfiguration
:ivar management_groups: ManagementGroups operations
:vartype management_groups: azure.mgmt.managementgroups.operations.ManagementGroupsOperations
:ivar management_group_subscriptions: ManagementGroupSubscriptions operations
:vartype management_group_subscriptions: azure.mgmt.managementgroups.operations.ManagementGroupSubscriptionsOperations
:ivar hierarchy_settings: HierarchySettings operations
:vartype hierarchy_settings: azure.mgmt.managementgroups.operations.HierarchySettingsOperations
:ivar operations: Operations operations
:vartype operations: azure.mgmt.managementgroups.operations.Operations
:ivar entities: Entities operations
:vartype entities: azure.mgmt.managementgroups.operations.EntitiesOperations
:param credentials: Credentials needed for the client to connect to Azure.
:type credentials: :mod:`A msrestazure Credentials
object<msrestazure.azure_active_directory>`
:param operation_result_id: The id of the operation result. Possible
values include: 'create', 'delete'
:type operation_result_id: str
:param skip: Number of entities to skip over when retrieving results.
Passing this in will override $skipToken.
:type skip: int
:param top: Number of elements to return when retrieving results. Passing
this in will override $skipToken.
:type top: int
:param skiptoken: Page continuation token is only used if a previous
operation returned a partial result.
If a previous response contains a nextLink element, the value of the
nextLink element will include a token parameter that specifies a starting
point to use for subsequent calls.
:type skiptoken: str
:param str base_url: Service URL
"""

def __init__(
self, credentials, operation_result_id, skip=None, top=None, skiptoken=None, base_url=None):

self.config = ManagementGroupsAPIConfiguration(credentials, operation_result_id, skip, top, skiptoken, base_url)
super(ManagementGroupsAPI, self).__init__(self.config.credentials, self.config)

client_models = {k: v for k, v in models.__dict__.items() if isinstance(v, type)}
self.api_version = '2020-02-01'
self._serialize = Serializer(client_models)
self._deserialize = Deserializer(client_models)

self.management_groups = ManagementGroupsOperations(
self._client, self.config, self._serialize, self._deserialize)
self.management_group_subscriptions = ManagementGroupSubscriptionsOperations(
self._client, self.config, self._serialize, self._deserialize)
self.hierarchy_settings = HierarchySettingsOperations(
self._client, self.config, self._serialize, self._deserialize)
self.operations = Operations(
self._client, self.config, self._serialize, self._deserialize)
self.entities = EntitiesOperations(
self._client, self.config, self._serialize, self._deserialize)
Original file line number Diff line number Diff line change
Expand Up @@ -10,81 +10,107 @@
# --------------------------------------------------------------------------

try:
from .error_details_py3 import ErrorDetails
from .error_response_py3 import ErrorResponse, ErrorResponseException
from .operation_display_properties_py3 import OperationDisplayProperties
from .operation_py3 import Operation
from .check_name_availability_result_py3 import CheckNameAvailabilityResult
from .tenant_backfill_status_result_py3 import TenantBackfillStatusResult
from .management_group_info_py3 import ManagementGroupInfo
from .parent_group_info_py3 import ParentGroupInfo
from .management_group_details_py3 import ManagementGroupDetails
from .management_group_child_info_py3 import ManagementGroupChildInfo
from .management_group_py3 import ManagementGroup
from .operation_results_py3 import OperationResults
from .entity_parent_group_info_py3 import EntityParentGroupInfo
from .entity_info_py3 import EntityInfo
from .entity_hierarchy_item_py3 import EntityHierarchyItem
from .patch_management_group_request_py3 import PatchManagementGroupRequest
from .create_parent_group_info_py3 import CreateParentGroupInfo
from .create_management_group_details_py3 import CreateManagementGroupDetails
from .create_management_group_child_info_py3 import CreateManagementGroupChildInfo
from .create_management_group_request_py3 import CreateManagementGroupRequest
from .check_name_availability_request_py3 import CheckNameAvailabilityRequest
from ._models_py3 import AzureAsyncOperationResults
from ._models_py3 import CheckNameAvailabilityRequest
from ._models_py3 import CheckNameAvailabilityResult
from ._models_py3 import CreateManagementGroupChildInfo
from ._models_py3 import CreateManagementGroupDetails
from ._models_py3 import CreateManagementGroupRequest
from ._models_py3 import CreateOrUpdateSettingsRequest
from ._models_py3 import CreateParentGroupInfo
from ._models_py3 import DescendantInfo
from ._models_py3 import DescendantParentGroupInfo
from ._models_py3 import EntityHierarchyItem
from ._models_py3 import EntityInfo
from ._models_py3 import EntityParentGroupInfo
from ._models_py3 import ErrorDetails
from ._models_py3 import ErrorResponse, ErrorResponseException
from ._models_py3 import HierarchySettings
from ._models_py3 import HierarchySettingsInfo
from ._models_py3 import HierarchySettingsList
from ._models_py3 import ManagementGroup
from ._models_py3 import ManagementGroupChildInfo
from ._models_py3 import ManagementGroupDetails
from ._models_py3 import ManagementGroupInfo
from ._models_py3 import ManagementGroupPathElement
from ._models_py3 import Operation
from ._models_py3 import OperationDisplayProperties
from ._models_py3 import OperationResults
from ._models_py3 import ParentGroupInfo
from ._models_py3 import PatchManagementGroupRequest
from ._models_py3 import TenantBackfillStatusResult
except (SyntaxError, ImportError):
from .error_details import ErrorDetails
from .error_response import ErrorResponse, ErrorResponseException
from .operation_display_properties import OperationDisplayProperties
from .operation import Operation
from .check_name_availability_result import CheckNameAvailabilityResult
from .tenant_backfill_status_result import TenantBackfillStatusResult
from .management_group_info import ManagementGroupInfo
from .parent_group_info import ParentGroupInfo
from .management_group_details import ManagementGroupDetails
from .management_group_child_info import ManagementGroupChildInfo
from .management_group import ManagementGroup
from .operation_results import OperationResults
from .entity_parent_group_info import EntityParentGroupInfo
from .entity_info import EntityInfo
from .entity_hierarchy_item import EntityHierarchyItem
from .patch_management_group_request import PatchManagementGroupRequest
from .create_parent_group_info import CreateParentGroupInfo
from .create_management_group_details import CreateManagementGroupDetails
from .create_management_group_child_info import CreateManagementGroupChildInfo
from .create_management_group_request import CreateManagementGroupRequest
from .check_name_availability_request import CheckNameAvailabilityRequest
from .management_group_info_paged import ManagementGroupInfoPaged
from .operation_paged import OperationPaged
from .entity_info_paged import EntityInfoPaged
from .management_groups_api_enums import (
from ._models import AzureAsyncOperationResults
from ._models import CheckNameAvailabilityRequest
from ._models import CheckNameAvailabilityResult
from ._models import CreateManagementGroupChildInfo
from ._models import CreateManagementGroupDetails
from ._models import CreateManagementGroupRequest
from ._models import CreateOrUpdateSettingsRequest
from ._models import CreateParentGroupInfo
from ._models import DescendantInfo
from ._models import DescendantParentGroupInfo
from ._models import EntityHierarchyItem
from ._models import EntityInfo
from ._models import EntityParentGroupInfo
from ._models import ErrorDetails
from ._models import ErrorResponse, ErrorResponseException
from ._models import HierarchySettings
from ._models import HierarchySettingsInfo
from ._models import HierarchySettingsList
from ._models import ManagementGroup
from ._models import ManagementGroupChildInfo
from ._models import ManagementGroupDetails
from ._models import ManagementGroupInfo
from ._models import ManagementGroupPathElement
from ._models import Operation
from ._models import OperationDisplayProperties
from ._models import OperationResults
from ._models import ParentGroupInfo
from ._models import PatchManagementGroupRequest
from ._models import TenantBackfillStatusResult
from ._paged_models import DescendantInfoPaged
from ._paged_models import EntityInfoPaged
from ._paged_models import ManagementGroupInfoPaged
from ._paged_models import OperationPaged
from ._management_groups_api_enums import (
Reason,
Status,
Type,
)

__all__ = [
'AzureAsyncOperationResults',
'CheckNameAvailabilityRequest',
'CheckNameAvailabilityResult',
'CreateManagementGroupChildInfo',
'CreateManagementGroupDetails',
'CreateManagementGroupRequest',
'CreateOrUpdateSettingsRequest',
'CreateParentGroupInfo',
'DescendantInfo',
'DescendantParentGroupInfo',
'EntityHierarchyItem',
'EntityInfo',
'EntityParentGroupInfo',
'ErrorDetails',
'ErrorResponse', 'ErrorResponseException',
'OperationDisplayProperties',
'Operation',
'CheckNameAvailabilityResult',
'TenantBackfillStatusResult',
'ManagementGroupInfo',
'ParentGroupInfo',
'ManagementGroupDetails',
'ManagementGroupChildInfo',
'HierarchySettings',
'HierarchySettingsInfo',
'HierarchySettingsList',
'ManagementGroup',
'ManagementGroupChildInfo',
'ManagementGroupDetails',
'ManagementGroupInfo',
'ManagementGroupPathElement',
'Operation',
'OperationDisplayProperties',
'OperationResults',
'EntityParentGroupInfo',
'EntityInfo',
'EntityHierarchyItem',
'ParentGroupInfo',
'PatchManagementGroupRequest',
'CreateParentGroupInfo',
'CreateManagementGroupDetails',
'CreateManagementGroupChildInfo',
'CreateManagementGroupRequest',
'CheckNameAvailabilityRequest',
'TenantBackfillStatusResult',
'ManagementGroupInfoPaged',
'DescendantInfoPaged',
'OperationPaged',
'EntityInfoPaged',
'Reason',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,4 +30,4 @@ class Status(str, Enum):

class Type(str, Enum):

providers_microsoft_managementmanagement_groups = "/providers/Microsoft.Management/managementGroups"
microsoft_managementmanagement_group = "Microsoft.Management/managementGroup"
Loading

0 comments on commit 7a490a6

Please sign in to comment.