Overview
This article explains how to connect your Azure account to Greenly so your cloud billing data can be used to measure and monitor your cloud emissions. You will check your Cost Management access, retrieve your Tenant ID, create a service principal, and grant it billing rights. These details are then entered in your connector setup form on the Greenly platform.
Before starting, make sure you have access to your Azure portal with the rights to register applications and manage access at the tenant level. During the tutorial, you will collect your Tenant ID, Application (client) ID, and a client secret value that you will need to provide in your connector setup form.
1. Before starting: check you have access to your Cost Management
Open any costing view (select Daily costs for example)
If you can't see any data, you need to ask your Azure subscription provider to unblock Cost Management
2. Find your Tenant ID
Go to Home > Microsoft Entra ID
Make a note of your Tenant ID. You will need it to fill in your connector setup form
3. Create a service principal
Create a new Registration
Enter Greenly as Name
Select account type: Account in this organizational directory only
Don't enter any redirect URI
Make a note of your Application (client) ID. You will need it to fill in your connector setup form.
In the same screen, click on client credentials
Add a new client secret
Set Expires: 365 days
Take note of the secret value. You can discard the secret ID as we won't need it.
4. Provide billing rights to the Service Principal
Go to Home > Management groups
Click on Tenant Root Group
Go to Access control (IAM) on the left bar
Click on Add
Select role Cost Management Reader
Click on'+ Select members' then select the Greenly user you just created and confirm
