Azure Subscription movement from one Management Group to Another

Abrar Adil S 216 Reputation points
2023-10-30T12:12:56.5566667+00:00

An alert to be received when a Subscription has been created is achievable by using the Azure Logic Apps, but how can we move the subscription which is created to a specific Management group based on the offer type of the subscription.

Example: if a Visual Studio Enterprise Subscription is created under the Tenant Root Group, the subscription needs to be moved to Visual Studio Enterprise Management Group, and for the subscription with offer type as EA needs to be moved to EA Management Group.

Azure Cost Management
Azure Cost Management
A Microsoft offering that enables tracking of cloud usage and expenditures for Azure and other cloud providers.
2,781 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. AirGordon 7,125 Reputation points
    2023-10-31T17:28:43.3133333+00:00

    Subscription type is set at the Subscription level.
    Management Groups can host subscriptions of different types. The Subscription simply needs to move to another management group via the normal UI.
    https://learn.microsoft.com/en-us/azure/governance/management-groups/manage#move-subscriptions


  2. Ryan Hill 29,211 Reputation points Microsoft Employee
    2023-11-14T21:30:06.7666667+00:00

    @Abrar Adil S you can use the Management Group Subscriptions REST API to move subscription groups. Since you're creating the subscription dynamically via a Logic App, you can include this API call as part of that flow.

    If you observe the network traffic when you perform the operation in the portal, you should see a similar request(s).

    PUT https://management.azure.com/providers/Microsoft.Management/managementGroups/{groupId}/subscriptions/{subscriptionId}?api-version=2020-05-01
    

    You may also want to consider using the Azure Resource Manager connector. I personally have not used this connector but it's work investigating. It should be a wrapper for the management API.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.