This post presents how to have complementary information on your Azure billing and cost prediction at the end of the month.
Microsoft Azure has opened its Billing API for a few years, so we could query it and perform various calculations. Since the EA portal (Enterprise Agreement) has been re-organized, I wanted to show how to get the necessary information.
Here is the new portal : https://ea.azure.com/
PRE-REQUISITEWork with the person in charge of the Enterprise Agreement. This person must have the Enterprise Account Role of “Enterprise Administrator” (usually the super-Admin or the CFO that has purchased Azure).
To find out who he is or to your understand the Enterprise Account Roles, go to http://blog.thavo.com/2014/05/where-to-start-with-microsoft-azure.html
To help you estimate, you have a public Microsoft tool, although depricated, it could spare you many hours: http://aka.ms/azurecosttool
STEP 1: GETTING THE API ACCESS KEYOnce logged in, go to Reports : https://ea.azure.com/report/usagesummary
and “Download Usage”
which brings you to the page : https://ea.azure.com/report/downloadusage
On the far top-right menu, click on “API Access Key”, then you will have access to the Primary Key, that has an expiration date (important to remember particularly if you plug in a SaaS application).
If the Key has not yet been generated, please do so:
Then use the Primary Key (that has an expiry date)
STEP 2: DECLARE YOUR AZURE PARTNER (ACCREDITED BY MICROSOFT)For companies using Microsoft Azure, when applicable under conditions of being a very closed partner with Microsoft, you could activate benefits when you declare your “DPOR” Microsoft partner, Digital Partner of Reference.
Let us assume that the DPOR is VISEO of ID=3398971 and that you are using the old Azure portal https://manage.windowsazure.com/ (easier to illustrate):
CAUTION : * You must be the owner of the subscription, i.e. the Enterprise Account Role “Account Owner”
* Microsoft is performing a rework to better improve the Billing on the Enterprise Agreement portal. These steps might not work in the near future
1. Log in to the portal
2. Click on your name/email
3. Click “View my bill”
4. It will redirect to another portal called “Azure Account Center" (sometimes it takes a few minutes, for secured login using Single Sign On) : https://account.windowsazure.com/Subscriptions
5. Choose your subscription
6. Select “Partner information”, then fill in the number 3398971. When you click “Check ID” Azure finds the corresponding DPOR.
It will send an email to your DPOR (provided you have a subscription that has an explicit naming convention).
STEP 3: ACTIVATE YOUR BENEFITSIf you are entitled, you can ask for the benefits, such as discounts on Teevity Cloud Usage Analytics tools: http://www.teevity.com/
Insert the information, based on the previous EA portal,
Once DONE, you could access :
Cost per day:
- This type of data visualization is very valuable. For instance, it could be a challenge to understand when occurs various consumuption. For instance when does our Visual Studio Pro licenses occurs ? In the graph below, the patterns is obvious : it happens at the beginning of the month. To be honnest, I though that each VS Pro licences had it’s own 1 month date of anniversary for billing. At the scale of 1000 licences, small optimization can have a major impact !
You can have the cost history
You will receive email notifications of the prediction of consumption at the end of the month: