Automating Monthly Cowork and Copilot Usage Reports

Zayan zay 40 Reputation points
2026-11-19T19:40:21.15+00:00

Hi,

I need to obtain monthly usage reports for Cowork and Copilot. How can we set up an automation to generate and receive these reports every month?

Thanks
Zayan

Microsoft Copilot | Other
0 comments No comments

1 answer

Sort by: Newest
  1. AI answer

    2026-11-19T19:43:38.17+00:00

    Automate the licensed Microsoft 365 Copilot report through Microsoft Graph and email the resulting CSV monthly; export Cowork separately from its admin-center dashboard because no programmatic Cowork export API is documented.

    1. Configure Microsoft 365 Copilot automation

    The supported Graph v1.0 report returns a CSV and requires the Reports.Read.All application permission. Its available periods are D7, D28, D90, D180, and ALL—not a calendar-month selector.^1^

    1. Create an Entra application registration for the automation.
    2. Add Microsoft Graph Application permission Reports.Read.All.
    3. Have an appropriately privileged tenant administrator grant tenant-wide admin consent.
    4. Add a certificate to the application and make that certificate available to the automation account.
    5. Create an Azure Automation PowerShell runbook and schedule it monthly.
    6. Have the runbook authenticate using the application certificate and download:
      • User-level details: getMicrosoft365CopilotUsageUserDetail
      • Optional organization summary: getMicrosoft365CopilotUserCountSummary

    Example runbook core:

    param(
        [string]$TenantId,
        [string]$ClientId,
        [string]$CertificateThumbprint
    )
    
    Connect-MgGraph -TenantId $TenantId -ClientId $ClientId `
        -CertificateThumbprint $CertificateThumbprint -NoWelcome
    
    $folder = Join-Path $env:TEMP (Get-Date -Format "yyyy-MM")
    New-Item $folder -ItemType Directory -Force | Out-Null
    
    Invoke-MgGraphRequest -Method GET `
      -Uri "https://graph.microsoft.com/v1.0/copilot/reports/getMicrosoft365CopilotUsageUserDetail(period='D28')" `
      -OutputFilePath (Join-Path $folder "Copilot-UserDetail-D28.csv")
    
    Invoke-MgGraphRequest -Method GET `
      -Uri "https://graph.microsoft.com/v1.0/copilot/reports/getMicrosoft365CopilotUserCountSummary(period='D28')" `
      -OutputFilePath (Join-Path $folder "Copilot-Summary-D28.csv")
    

    The summary report includes enabled and active users by application, total prompts, and average prompts.^2^

    Do not rely on files remaining in $env:TEMP. Add a final runbook step that uploads the generated files to a persistent SharePoint library, OneDrive folder, or Azure Blob container accessible to the delivery flow.

    2. Deliver the files with Power Automate

    Create a Scheduled cloud flow that runs after the monthly runbook schedule:

    1. Add Azure Automation – Create job to start the runbook.
    2. Poll the job until it reaches its completed state.
    3. Add Azure Automation – Get job output to retrieve the stored-file identifier or path emitted by the runbook. Microsoft documents this Azure Automation/Power Automate orchestration pattern.^3^
    4. Use the matching storage connector’s Get file content action.
    5. Add Office 365 Outlook – Send an email (V2):
      • To: report recipients
      • Subject: Microsoft 365 Copilot usage – <month>
      • Attachment Name: CSV filename
      • Attachment Content: output from Get file content
    6. Test the runbook, file handoff, and email before enabling recurrence.

    Power Automate cannot retrieve a file merely because it was written to an Automation worker’s temporary directory; the persistent-storage handoff is required.

    Calendar-month limitation

    D28 means the previous 28 days, not the previous calendar month. The admin-center Copilot report likewise offers rolling 7-, 28-, 90-, or 180-day ranges, and data typically appears within 48 hours.^4^

    If the requirement is strictly “the first through the last day of the previous month”:

    • Collect and retain daily organization-level trend results, then aggregate only dates belonging to that month. The user-count trend endpoint is available with Reports.Read.All.^5^
    • Do not attempt to reconstruct an exact calendar month from occasional D28 snapshots; they are rolling aggregates.
    • For exact user-level calendar-month measures, additional daily/raw collection is required because the documented user-detail endpoint accepts only the predefined rolling periods.

    The Graph usage-detail API covers users with Microsoft 365 Copilot licenses. Unlicensed Copilot Chat usage is not returned by this reporting API.^1^

    3. Export Cowork usage

    Cowork is not included in the Copilot Agents usage report; it has a dedicated report.^6^

    With an account holding an appropriate Microsoft 365 usage-reporting role:

    1. Open Microsoft 365 admin center.
    2. Select Copilot → Cowork → Usage.
    3. Choose the required date range.
    4. Check Last updated for data recency.
    5. Select Export above Cowork usage details.

    The CSV includes user ID, display name, total tasks, scheduled and user-initiated tasks, active days, and last activity date.^7^

    The currently documented Cowork reporting interface provides a dashboard export but does not document a Graph endpoint for automating that export. Therefore, a fully unattended combined Copilot-and-Cowork monthly email is not supported by these documented interfaces; the Cowork CSV must presently be exported manually and attached or placed in the delivery folder.


    References

    1. copilotReportRoot: getMicrosoft365CopilotUsageUserDetail (graph-v1)
    2. copilotReportRoot: getMicrosoft365CopilotUserCountSummary (graph-v1)
    3. Email notifications for automatic tuning
    4. Microsoft Copilot usage report
    5. copilotReportRoot: getMicrosoft365CopilotUserCountTrend (graph-v1)
    6. Microsoft Copilot Agents usage report
    7. Copilot Cowork usage
    AI-generated content may be incorrect. Read our transparency notes for more information.

    Was this answer helpful?

Your answer

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