---
title: Billing access for EA (PowerShell)
canonical: "https://cloudmonitor.ai/docs/installing-cloudmonitor/powershell-allow-cloudmonitor-access-view-billing-information-ea-enterprise-agreement-customers/"
description: "Azure PowerShell automation that grants CloudMonitor access to view Billing Information for Enterprise Agreement (EA) customers, scripted end to end."
---

Follow these steps to allow CloudMonitor to access, and view Billing Information for Enterprise Agreement (EA) customers.

:::tip
These instructions show how to grant the read-only EnrollmentReader role to the CloudMonitor Service Principal for customers that have Legacy Enterprise Agreements (EA) with Microsoft.

Only Department Administrators and Account Owners are allowed to assign the EnrollmentReader Role to the CloudMonitor Service Principal. If you do not have any of these 2 roles ask your Enterprise Administrator to [assign these roles to you](https://cloudmonitor.ai/docs/how-to-articles/how-assign-roles-as-an-enterprise-administrator-enterprise-agreement-customers/).
:::

:::tip
The following steps will utilize the Azure REST API to grant the read-only EnrollmentReader role to a Service Principal.

Microsoft has confirmed that this is a known limitation of the Azure Portal and provided this alternative method. Customers on MCA agreements do not need to do this step.
:::

### Step 1

Please find the "3_AssignEnrollmentReaderToCloudMonitorServicePrincipal.ps1" from the ConfigureCloudMonitorServicePrincipal folder and execute it in the PowerShell.

Please provide the necessary inputs when required.

### Step 2

If the final output looks like below,\
\
**IAM Enrollment Reader role assigned to CloudMonitor Service Principal with Billing Account - `<YourbillingAccountId>`, TenantId - `<YourtenantId>`.**

It means the user creation is successful.

:::tip
You have successfully granted the read-only EnrollmentReader role to the CloudMonitor Service Principal.

Please proceed with the next step:[Configuring Storage for CloudMonitor to schedule Exports : CloudMonitor Helpdesk](https://cloudmonitor.ai/docs/installing-cloudmonitor/powershell-configuring-storage-cloudmonitor-schedule-exports/)
:::
