azure.mgmt.managementgroups.operations module¶
-
class
azure.mgmt.managementgroups.operations.
ManagementGroupsOperations
(client, config, serializer, deserializer)[source]¶ Bases:
object
ManagementGroupsOperations operations.
Parameters: - client – Client for service requests.
- config – Configuration of service client.
- serializer – An object model serializer.
- deserializer – An object model deserializer.
Variables: api_version – Version of the API to be used with the client request. The current version is 2018-01-01-preview. Constant value: “2018-03-01-preview”.
-
create_or_update
(group_id, create_management_group_request, cache_control='no-cache', custom_headers=None, raw=False, polling=True, **operation_config)[source]¶ Create or update a management group. If a management group is already created and a subsequent create request is issued with different properties, the management group properties will be updated.
Parameters: - group_id (str) – Management Group ID.
- create_management_group_request (CreateManagementGroupRequest) – Management group creation parameters.
- cache_control (str) – Indicates that the request shouldn’t utilize any caches.
- custom_headers (dict) – headers that will be added to the request
- raw (bool) – The poller return type is ClientRawResponse, the direct response alongside the deserialized response
- polling – True for ARMPolling, False for no polling, or a polling object for personal polling strategy
Returns: An instance of LROPoller that returns object or ClientRawResponse<object> if raw==True
Return type: AzureOperationPoller[object] or AzureOperationPoller[ClientRawResponse[object]]
Raises:
-
delete
(group_id, cache_control='no-cache', custom_headers=None, raw=False, polling=True, **operation_config)[source]¶ Delete management group. If a management group contains child resources, the request will fail.
Parameters: - group_id (str) – Management Group ID.
- cache_control (str) – Indicates that the request shouldn’t utilize any caches.
- custom_headers (dict) – headers that will be added to the request
- raw (bool) – The poller return type is ClientRawResponse, the direct response alongside the deserialized response
- polling – True for ARMPolling, False for no polling, or a polling object for personal polling strategy
Returns: An instance of LROPoller that returns OperationResults or ClientRawResponse<OperationResults> if raw==True
Return type: AzureOperationPoller[OperationResults] or AzureOperationPoller[ClientRawResponse[OperationResults]]
Raises:
-
get
(group_id, expand=None, recurse=None, filter=None, cache_control='no-cache', custom_headers=None, raw=False, **operation_config)[source]¶ Get the details of the management group.
Parameters: - group_id (str) – Management Group ID.
- expand (str) – The $expand=children query string parameter allows clients to request inclusion of children in the response payload. Possible values include: ‘children’
- recurse (bool) – The $recurse=true query string parameter allows clients to request inclusion of entire hierarchy in the response payload. Note that $expand=children must be passed up if $recurse is set to true.
- filter (str) – A filter which allows the exclusion of subscriptions from results (i.e. ‘$filter=children.childType ne Subscription’)
- cache_control (str) – Indicates that the request shouldn’t utilize any caches.
- custom_headers (dict) – headers that will be added to the request
- raw (bool) – returns the direct response alongside the deserialized response
- operation_config – Operation configuration overrides.
Returns: ManagementGroup or ClientRawResponse if raw=true
Return type: ManagementGroup or ClientRawResponse
Raises:
-
list
(cache_control='no-cache', skiptoken=None, custom_headers=None, raw=False, **operation_config)[source]¶ List management groups for the authenticated user.
Parameters: - cache_control (str) – Indicates that the request shouldn’t utilize any caches.
- skiptoken (str) – 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.
- custom_headers (dict) – headers that will be added to the request
- raw (bool) – returns the direct response alongside the deserialized response
- operation_config – Operation configuration overrides.
Returns: An iterator like instance of ManagementGroupInfo
Return type: Raises:
-
update
(group_id, patch_group_request, cache_control='no-cache', custom_headers=None, raw=False, **operation_config)[source]¶ Update a management group.
Parameters: - group_id (str) – Management Group ID.
- patch_group_request (PatchManagementGroupRequest) – Management group patch parameters.
- cache_control (str) – Indicates that the request shouldn’t utilize any caches.
- custom_headers (dict) – headers that will be added to the request
- raw (bool) – returns the direct response alongside the deserialized response
- operation_config – Operation configuration overrides.
Returns: ManagementGroup or ClientRawResponse if raw=true
Return type: ManagementGroup or ClientRawResponse
Raises:
-
models
= <module 'azure.mgmt.managementgroups.models' from '/usr/lib/python3/dist-packages/azure/mgmt/managementgroups/models/__init__.py'>¶
-
class
azure.mgmt.managementgroups.operations.
ManagementGroupSubscriptionsOperations
(client, config, serializer, deserializer)[source]¶ Bases:
object
ManagementGroupSubscriptionsOperations operations.
Parameters: - client – Client for service requests.
- config – Configuration of service client.
- serializer – An object model serializer.
- deserializer – An object model deserializer.
Variables: api_version – Version of the API to be used with the client request. The current version is 2018-01-01-preview. Constant value: “2018-03-01-preview”.
-
create
(group_id, subscription_id, cache_control='no-cache', custom_headers=None, raw=False, **operation_config)[source]¶ Associates existing subscription with the management group.
Parameters: - group_id (str) – Management Group ID.
- subscription_id (str) – Subscription ID.
- cache_control (str) – Indicates that the request shouldn’t utilize any caches.
- custom_headers (dict) – headers that will be added to the request
- raw (bool) – returns the direct response alongside the deserialized response
- operation_config – Operation configuration overrides.
Returns: None or ClientRawResponse if raw=true
Return type: None or ClientRawResponse
Raises:
-
delete
(group_id, subscription_id, cache_control='no-cache', custom_headers=None, raw=False, **operation_config)[source]¶ De-associates subscription from the management group.
Parameters: - group_id (str) – Management Group ID.
- subscription_id (str) – Subscription ID.
- cache_control (str) – Indicates that the request shouldn’t utilize any caches.
- custom_headers (dict) – headers that will be added to the request
- raw (bool) – returns the direct response alongside the deserialized response
- operation_config – Operation configuration overrides.
Returns: None or ClientRawResponse if raw=true
Return type: None or ClientRawResponse
Raises:
-
models
= <module 'azure.mgmt.managementgroups.models' from '/usr/lib/python3/dist-packages/azure/mgmt/managementgroups/models/__init__.py'>¶
-
class
azure.mgmt.managementgroups.operations.
Operations
(client, config, serializer, deserializer)[source]¶ Bases:
object
Operations operations.
Parameters: - client – Client for service requests.
- config – Configuration of service client.
- serializer – An object model serializer.
- deserializer – An object model deserializer.
Variables: api_version – Version of the API to be used with the client request. The current version is 2018-01-01-preview. Constant value: “2018-03-01-preview”.
-
list
(custom_headers=None, raw=False, **operation_config)[source]¶ Lists all of the available Management REST API operations.
Parameters: Returns: An iterator like instance of Operation
Return type: Raises:
-
models
= <module 'azure.mgmt.managementgroups.models' from '/usr/lib/python3/dist-packages/azure/mgmt/managementgroups/models/__init__.py'>¶
-
class
azure.mgmt.managementgroups.operations.
EntitiesOperations
(client, config, serializer, deserializer)[source]¶ Bases:
object
EntitiesOperations operations.
Parameters: - client – Client for service requests.
- config – Configuration of service client.
- serializer – An object model serializer.
- deserializer – An object model deserializer.
Variables: api_version – Version of the API to be used with the client request. The current version is 2018-01-01-preview. Constant value: “2018-03-01-preview”.
-
list
(skiptoken=None, skip=None, top=None, select=None, search=None, filter=None, view=None, group_name=None, cache_control='no-cache', custom_headers=None, raw=False, **operation_config)[source]¶ List all entities (Management Groups, Subscriptions, etc.) for the authenticated user.
Parameters: - skiptoken (str) – 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.
- skip (int) – Number of entities to skip over when retrieving results. Passing this in will override $skipToken.
- top (int) – Number of elements to return when retrieving results. Passing this in will override $skipToken.
- select (str) – This parameter specifies the fields to include in the response. Can include any combination of Name,DisplayName,Type,ParentDisplayNameChain,ParentChain, e.g. ‘$select=Name,DisplayName,Type,ParentDisplayNameChain,ParentNameChain’. When specified the $select parameter can override select in $skipToken.
- search (str) – The $search parameter is used in conjunction with the $filter parameter to return three different outputs depending on the parameter passed in. With $search=AllowedParents the API will return the entity info of all groups that the requested entity will be able to reparent to as determined by the user’s permissions. With $search=AllowedChildren the API will return the entity info of all entities that can be added as children of the requested entity. With $search=ParentAndFirstLevelChildren the API will return the parent and first level of children that the user has either direct access to or indirect access via one of their descendants. Possible values include: ‘AllowedParents’, ‘AllowedChildren’, ‘ParentAndFirstLevelChildren’, ‘ParentOnly’, ‘ChildrenOnly’
- filter (str) – The filter parameter allows you to filter on the name or display name fields. You can check for equality on the name field (e.g. name eq ‘{entityName}’) and you can check for substrings on either the name or display name fields(e.g. contains(name, ‘{substringToSearch}’), contains(displayName, ‘{substringToSearch’)). Note that the ‘{entityName}’ and ‘{substringToSearch}’ fields are checked case insensitively.
- view (str) – The view parameter allows clients to filter the type of data that is returned by the getEntities call. Possible values include: ‘FullHierarchy’, ‘GroupsOnly’, ‘SubscriptionsOnly’, ‘Audit’
- group_name (str) – A filter which allows the get entities call to focus on a particular group (i.e. “$filter=name eq ‘groupName’”)
- cache_control (str) – Indicates that the request shouldn’t utilize any caches.
- custom_headers (dict) – headers that will be added to the request
- raw (bool) – returns the direct response alongside the deserialized response
- operation_config – Operation configuration overrides.
Returns: An iterator like instance of EntityInfo
Return type: Raises:
-
models
= <module 'azure.mgmt.managementgroups.models' from '/usr/lib/python3/dist-packages/azure/mgmt/managementgroups/models/__init__.py'>¶