Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
35 commits
Select commit Hold shift + click to select a range
6978d33
Add initial Azure ManagedCleanroom toolset with first commands: colla…
Jun 15, 2026
0d431c4
Fix review feedback for managedcleanroom list/create scope
Jun 16, 2026
1b4eb28
Revert unstable cleanroom package/version bumps
Jun 16, 2026
b3aef3a
Use vendored Cleanroom SDKs in ManagedCleanroom service
Jun 16, 2026
3b62db7
Rename changelog entry, update architecture docs, solution files, and…
Jun 16, 2026
e567734
Return immediately after ARM accepts collaboration create request
Jun 16, 2026
10135b1
Split IManagedCleanroomService into control-plane and data-plane inte…
Jun 16, 2026
6608cb5
Restore SDK-based list call and add RetryPolicy to data-plane interfa…
Jun 16, 2026
043e680
Rename command group from 'collaboration' to 'collaborationArm' for A…
Jun 16, 2026
8c6fd88
Refactor cleanroom options and align create semantics
Jun 16, 2026
b145dd5
Fix ManagedCleanroom list command test signature
Jun 16, 2026
eb54a81
Fix CI blockers for analyze and windows build
Jun 16, 2026
b3b64b8
Stabilize missing-subscription unit tests
Jun 16, 2026
c583bf2
Fix consolidated tool mappings and metadata
Jun 16, 2026
471c9e1
Fix cleanroom create response payload
Jun 21, 2026
9ef5037
Update tools/Azure.Mcp.Tools.ManagedCleanroom/src/Commands/ManagedCle…
ShreyaSangwa Jun 25, 2026
e01450d
ManagedCleanroom: align create command metadata and update vendored f…
Jun 25, 2026
9e4ef10
Fix OptionAttribute named arguments for cleanroom options
Jun 25, 2026
47b79eb
Resolve OptionAttribute PR conflict with main
Jun 25, 2026
b36d609
Align OptionAttribute with main and update managedcleanroom options
Jun 25, 2026
a8fe09e
Merge remote-tracking branch 'upstream/main' into cleanrooms
Jun 25, 2026
5c4a60c
Fix managedcleanroom retry option containers
Jun 25, 2026
ef6639c
Refactor ManagedCleanroom services by plane
Jun 29, 2026
42ce733
Update ManagedCleanroom architecture documentation
Jun 29, 2026
97fcbc1
Fix final newline formatting in ManagedCleanroom services
Jun 29, 2026
f334474
Fix consolidated tool metadata idempotency alignment
Jun 29, 2026
efa1aff
Fix Cosmos playback by removing eager account read
Jun 30, 2026
2fe1b7a
Add recorded tests for ManagedCleanroom collaborations list and creat…
Jun 30, 2026
45466f2
Remove unrelated Advisor test change from cleanrooms PR
ShreyaSangwa Jun 30, 2026
8407f84
Merge branch 'microsoft:main' into cleanrooms
ShreyaSangwa Jun 30, 2026
a8a741f
Remove unrelated Cosmos change from cleanrooms PR
ShreyaSangwa Jun 30, 2026
949618b
Remove unrelated Extension Azqr test change from cleanrooms PR
ShreyaSangwa Jun 30, 2026
adc8b6e
Update ManagedCleanroom assets.json with recording tag
ShreyaSangwa Jun 30, 2026
2f3bdfc
Update ManagedCleanroom recorded test assets tag
ShreyaSangwa Jun 30, 2026
c962cba
Return raw ARM create output and align ManagedCleanroom playback asse…
ShreyaSangwa Jun 30, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
Expand Up @@ -281,6 +281,12 @@
# ServiceLabel: %tools-ManagedLustre
# ServiceOwners: @rebecca-makar @wolfgang-desalvador

# PRLabel: %tools-ManagedCleanroom
/tools/Azure.Mcp.Tools.ManagedCleanroom/ @ashank @yavohra @vaidmishra @microsoft/azure-mcp

# ServiceLabel: %tools-ManagedCleanroom
# ServiceOwners: @ashank @yavohra @vaidmishra @microsoft/azure-mcp

# PRLabel: %tools-Marketplace
/tools/Azure.Mcp.Tools.Marketplace/ @meirloichter @shaharsandak @obit91 @microsoft/azure-mcp

Expand Down
4 changes: 4 additions & 0 deletions Directory.Packages.props
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
<ItemGroup>
<PackageVersion Include="Apache.Arrow" Version="22.1.0" />
<PackageVersion Include="Azure.Containers.ContainerRegistry" Version="1.2.0" />
<!-- Cleanroom SDKs are temporarily added as vendored NuGet packages until they are published. -->
<PackageVersion Include="Azure.Cleanroom.Analytics.Frontend.Client" Version="1.0.0-beta.1" />
Comment thread
ShreyaSangwa marked this conversation as resolved.
<PackageVersion Include="Azure.Communication.Sms" Version="1.0.2" />
<PackageVersion Include="Azure.Communication.Email" Version="1.0.2" />
<PackageVersion Include="Azure.AI.Projects" Version="1.0.0-beta.9" />
Expand All @@ -31,6 +33,8 @@
<PackageVersion Include="Azure.ResourceManager.DesktopVirtualization" Version="1.3.2" />
<PackageVersion Include="Azure.ResourceManager.DeviceRegistry" Version="1.1.0-beta.2" />
<PackageVersion Include="Azure.ResourceManager.ContainerService" Version="1.2.5" />
<!-- Cleanroom SDKs are temporarily added as vendored NuGet packages until they are published. -->
<PackageVersion Include="Azure.ResourceManager.CleanRoom" Version="1.0.0-alpha.20260603.1" />
<PackageVersion Include="Azure.ResourceManager.EventGrid" Version="1.2.0-beta.2" />
<PackageVersion Include="Azure.ResourceManager.EventHubs" Version="1.2.1" />
<PackageVersion Include="Azure.ResourceManager.CognitiveServices" Version="1.5.1" />
Expand Down
7 changes: 7 additions & 0 deletions Microsoft.Mcp.slnx
Original file line number Diff line number Diff line change
Expand Up @@ -309,6 +309,13 @@
<Folder Name="/tools/Azure.Mcp.Tools.LoadTesting/tests/">
<Project Path="tools/Azure.Mcp.Tools.LoadTesting/tests/Azure.Mcp.Tools.LoadTesting.Tests/Azure.Mcp.Tools.LoadTesting.Tests.csproj" />
</Folder>
<Folder Name="/tools/Azure.Mcp.Tools.ManagedCleanroom/" />
<Folder Name="/tools/Azure.Mcp.Tools.ManagedCleanroom/src/">
<Project Path="tools/Azure.Mcp.Tools.ManagedCleanroom/src/Azure.Mcp.Tools.ManagedCleanroom.csproj" />
</Folder>
<Folder Name="/tools/Azure.Mcp.Tools.ManagedCleanroom/tests/">
<Project Path="tools/Azure.Mcp.Tools.ManagedCleanroom/tests/Azure.Mcp.Tools.ManagedCleanroom.Tests/Azure.Mcp.Tools.ManagedCleanroom.Tests.csproj" />
</Folder>
<Folder Name="/tools/Azure.Mcp.Tools.ManagedLustre/" />
<Folder Name="/tools/Azure.Mcp.Tools.ManagedLustre/src/">
<Project Path="tools/Azure.Mcp.Tools.ManagedLustre/src/Azure.Mcp.Tools.ManagedLustre.csproj" />
Expand Down
2 changes: 1 addition & 1 deletion eng/tools/ToolMetadataExporter/src/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ private static void ConfigureAzureServices(IServiceCollection services)
services.AddScoped<TokenCredential>(sp =>
{
var credential = new ChainedTokenCredential(
new ManagedIdentityCredential(),
new ManagedIdentityCredential(new ManagedIdentityCredentialOptions()),
new DefaultAzureCredential()
);

Expand Down
2 changes: 2 additions & 0 deletions nuget.config
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
<!-- Do not add any additional feeds. If new packages are needed, they need to come from our azure-sdk-for-net DevOps feed which has an upstream set to nuget.org -->
<!-- See the Central NuGet Feed documentation in CONTRIBUTING.md for more details -->
<add key="azure-sdk-for-net" value="https://pkgs.dev.azure.com/azure-sdk/public/_packaging/azure-sdk-for-net/nuget/v3/index.json" />
<!-- Temporary local feed for vendored Cleanroom SDK NuGet packages until those SDKs are published. -->
<add key="cleanroom-local" value="vendor/cleanroom-nupkgs" />
</packageSources>
<disabledPackageSources>
<clear />
Expand Down
7 changes: 7 additions & 0 deletions servers/Azure.Mcp.Server/Azure.Mcp.Server.slnx
Original file line number Diff line number Diff line change
Expand Up @@ -263,6 +263,13 @@
<Folder Name="/tools/Azure.Mcp.Tools.LoadTesting/tests/">
<Project Path="../../tools/Azure.Mcp.Tools.LoadTesting/tests/Azure.Mcp.Tools.LoadTesting.Tests/Azure.Mcp.Tools.LoadTesting.Tests.csproj" />
</Folder>
<Folder Name="/tools/Azure.Mcp.Tools.ManagedCleanroom/" />
<Folder Name="/tools/Azure.Mcp.Tools.ManagedCleanroom/src/">
<Project Path="../../tools/Azure.Mcp.Tools.ManagedCleanroom/src/Azure.Mcp.Tools.ManagedCleanroom.csproj" />
</Folder>
<Folder Name="/tools/Azure.Mcp.Tools.ManagedCleanroom/tests/">
<Project Path="../../tools/Azure.Mcp.Tools.ManagedCleanroom/tests/Azure.Mcp.Tools.ManagedCleanroom.Tests/Azure.Mcp.Tools.ManagedCleanroom.Tests.csproj" />
</Folder>
<Folder Name="/tools/Azure.Mcp.Tools.ManagedLustre/" />
<Folder Name="/tools/Azure.Mcp.Tools.ManagedLustre/src/">
<Project Path="../../tools/Azure.Mcp.Tools.ManagedLustre/src/Azure.Mcp.Tools.ManagedLustre.csproj" />
Expand Down
Comment thread
ShreyaSangwa marked this conversation as resolved.
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
changes:
- section: "New Features"
description: "Added Azure Managed Cleanroom toolset with two commands for interacting with Azure Cleanroom: `managedcleanroom collaborations list` and `managedcleanroom collaboration create`."
1 change: 1 addition & 0 deletions servers/Azure.Mcp.Server/src/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,7 @@ private static IAreaSetup[] RegisterAreas()
new Azure.Mcp.Tools.KeyVault.KeyVaultSetup(),
new Azure.Mcp.Tools.Kusto.KustoSetup(),
new Azure.Mcp.Tools.LoadTesting.LoadTestingSetup(),
new Azure.Mcp.Tools.ManagedCleanroom.ManagedCleanroomSetup(),
new Azure.Mcp.Tools.Marketplace.MarketplaceSetup(),
new Azure.Mcp.Tools.Quota.QuotaSetup(),
new Azure.Mcp.Tools.Monitor.MonitorSetup(),
Expand Down
66 changes: 66 additions & 0 deletions servers/Azure.Mcp.Server/src/Resources/consolidated-tools.json
Original file line number Diff line number Diff line change
Expand Up @@ -4332,6 +4332,72 @@
"sreagent_scheduledtasks_delete",
"sreagent_threads_delete"
]
},
{
"name": "list_azure_managed_cleanroom_collaborations",
"description": "List Azure Managed Cleanroom collaborations the calling user participates in via the Cleanroom Analytics Frontend service.",
"toolMetadata": {
"destructive": {
"value": false,
"description": "This tool performs only additive updates without deleting or modifying existing resources."
},
"idempotent": {
"value": true,
"description": "Running this operation multiple times with the same arguments produces the same result without additional effects."
},
"openWorld": {
"value": false,
"description": "This tool's domain of interaction is closed and well-defined, limited to a specific set of entities."
},
"readOnly": {
"value": true,
"description": "This tool only performs read operations without modifying any state or data."
},
"secret": {
"value": false,
"description": "This tool does not handle sensitive or secret information."
},
"localRequired": {
"value": false,
"description": "This tool is available in both local and remote server modes."
}
},
"mappedToolList": [
"managedcleanroom_collaborations_list"
]
},
{
"name": "create_azure_managed_cleanroom_collaboration",
"description": "Create an Azure Managed Cleanroom collaboration ARM resource in a resource group and region.",
"toolMetadata": {
"destructive": {
"value": false,
"description": "This tool performs only additive updates without deleting or modifying existing resources."
},
"idempotent": {
"value": false,
"description": "Running this operation multiple times with the same arguments produces the same result without additional effects."
},
"openWorld": {
"value": false,
"description": "This tool's domain of interaction is closed and well-defined, limited to a specific set of entities."
},
"readOnly": {
"value": false,
"description": "This tool may modify its environment by creating, updating, or deleting data."
},
"secret": {
"value": false,
"description": "This tool does not handle sensitive or secret information."
},
"localRequired": {
"value": false,
"description": "This tool is available in both local and remote server modes."
}
},
"mappedToolList": [
"managedcleanroom_collaborationarm_create"
]
}
]
}
105 changes: 105 additions & 0 deletions tools/Azure.Mcp.Tools.ManagedCleanroom/docs/architecture.md
Comment thread
ShreyaSangwa marked this conversation as resolved.
Original file line number Diff line number Diff line change
@@ -0,0 +1,105 @@
# Azure Managed Cleanroom MCP Toolset - Architecture
Comment thread
ShreyaSangwa marked this conversation as resolved.

## Overview

`Azure.Mcp.Tools.ManagedCleanroom` currently provides an initial set of operations for interacting with Azure Managed Cleanroom services. The current implementation includes `collaborations list` (data plane) and `collaborationarm create` (control plane), with additional command groups planned.

Commands interact with:
- **Data Plane APIs**: Cleanroom Analytics Frontend for read operations (list collaborations, queries, datasets)
- **Control Plane APIs**: Azure Resource Manager (ARM) for write operations (create collaboration, manage resources)

---

## Command Surfaces

- **Management Plane Commands**:

| Command Group | Command | Status |
| --- | --- | --- |
| CollaborationArm | `collaborationarm create` | Completed |
| CollaborationArm | `collaborationarm get` | Pending |
| CollaborationArm | `collaborationarm add-collaborator` | Pending |
| CollaborationArm | `collaborationarm enable-workload` | Pending |
| CollaborationArm | `collaborationarm get-readonly-kubeconfig` | Pending |

- **Data Plane Commands**:

| Command Group | Command | Status |
| --- | --- | --- |
| Collaborations | `collaborations list` | Completed |
| Collaborations | `collaborations get` | Pending |
| Analytics | `analytics get` | Pending |
| Analytics | `analytics skr-policy` | Pending |
| OIDC | `oidc issuer-info` | Pending |
| OIDC | `oidc keys` | Pending |
| OIDC | `oidc set-issuer-url` | Pending |
| Invitations | `invitations list` | Pending |
| Invitations | `invitations accept` | Pending |
| Datasets | `datasets publish` | Pending |
| Datasets | `datasets get` | Pending |
| Datasets | `datasets list` | Pending |
| Consent | `consent put` | Pending |
| Queries | `queries publish` | Pending |
| Queries | `queries get` | Pending |
| Queries | `queries list` | Pending |
| Queries | `queries vote` | Pending |
| Queries | `queries run` | Pending |
| Queries | `queries runs` | Pending |
| Runs | `runs get` | Pending |
| Audit Events | `auditevents list` | Pending |

---

## Project Structure

```
Azure.Mcp.Tools.ManagedCleanroom/
├── src/
│ ├── ManagedCleanroomSetup.cs # DI registration & command tree
│ ├── Commands/
│ │ ├── ManagedCleanroomJsonContext.cs # AOT-safe JSON serialization
│ │ ├── Collaboration/
│ │ │ ├── CollaborationCreateCommand.cs
│ │ │ └── [Other collaboration commands ]
│ │ ├── Collaborations/
│ │ │ ├── CollaborationsListCommand.cs
│ │ │ └── [Other collaboration commands ]
│ │ ├── Analytics/ # Analytics operations
│ │ ├── Oidc/ # OIDC configuration
│ │ ├── Invitations/ # Invitation management
│ │ ├── Datasets/ # Dataset operations
│ │ ├── Consent/ # Consent documents
│ │ ├── Queries/ # Query operations
│ │ ├── Runs/ # Query run tracking
│ │ └── AuditEvents/ # Audit event listing
│ ├── Options/
│ │ ├── ManagedCleanroomOptionDescriptions.cs
│ │ ├── Collaboration/
│ │ │ └── [Options classes - mixed status]
│ │ └── [Options for all command groups]
Comment thread
ShreyaSangwa marked this conversation as resolved.
│ ├── Models/
│ │ └── CollaborationCreateResult.cs
│ └── Services/
│ ├── IManagedCleanroomServiceDataPlane.cs
│ ├── IManagedCleanroomServiceControlPlane.cs
│ ├── ManagedCleanroomDataPlaneService.cs
│ └── ManagedCleanroomControlPlaneService.cs
└── tests/
└── Azure.Mcp.Tools.ManagedCleanroom.Tests/
├── CollaborationArm/
│ ├── CollaborationCreateCommandTests.cs
│ └── [Other tests - ⏳]
├── Collaborations/
│ ├── CollaborationsListCommandTests.cs
│ └── [Other tests - ⏳]
└── [Tests for remaining command groups - ⏳]
```

---

## Implementation Notes

- **Completed**: `collaborations list`, `collaboration create`
- **Pending**: 25 additional commands across 9 command groups
- Commands span both data plane and control plane operations

1 change: 1 addition & 0 deletions tools/Azure.Mcp.Tools.ManagedCleanroom/docs/skills.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
TBD
6 changes: 6 additions & 0 deletions tools/Azure.Mcp.Tools.ManagedCleanroom/src/AssemblyInfo.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.

using System.Runtime.CompilerServices;

[assembly: InternalsVisibleTo("Azure.Mcp.Tools.ManagedCleanroom.Tests")]
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<IsAotCompatible>true</IsAotCompatible>
<AzureSupportedClouds>AzureCloud</AzureSupportedClouds>
</PropertyGroup>
<ItemGroup>
<ProjectReference Include="..\..\..\core\Azure.Mcp.Core\src\Azure.Mcp.Core.csproj" />
</ItemGroup>
<ItemGroup>
<!-- Cleanroom SDKs are temporarily vendored as NuGet packages until they are published. -->
<PackageReference Include="Azure.Cleanroom.Analytics.Frontend.Client" />
<PackageReference Include="Azure.Core" VersionOverride="1.57.0" />
<PackageReference Include="Azure.Identity" />
<PackageReference Include="Azure.ResourceManager.CleanRoom" />
<PackageReference Include="Azure.ResourceManager.Resources" />
<PackageReference Include="Microsoft.Extensions.DependencyInjection" />
<PackageReference Include="ModelContextProtocol" />
<PackageReference Include="System.CommandLine" />
</ItemGroup>
</Project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.

using System.Net;
using System.Text.Json;
using Azure.Mcp.Core.Commands.Subscription;
using Azure.Mcp.Core.Services.Azure.Subscription;
using Azure.Mcp.Tools.ManagedCleanroom.Options.CollaborationArm;
using Azure.Mcp.Tools.ManagedCleanroom.Services;
using Microsoft.Extensions.Logging;
using Microsoft.Mcp.Core.Commands;
using Microsoft.Mcp.Core.Models.Command;

namespace Azure.Mcp.Tools.ManagedCleanroom.Commands.CollaborationArm;

[CommandMetadata(
Id = "e247b9e0-2d87-43a7-8e5d-57eea22237a3",
Name = "create",
Title = "Create Cleanroom Collaboration",
Description = """
Creates an Azure Cleanroom collaboration ARM resource in the specified resource group and location.
Returns immediately once the request is accepted by ARM. Provisioning runs in the background and typically takes ~25 minutes.
You can check the status by asking to get the collaboration by name once the request is accepted.
""",
Destructive = false,
Idempotent = false,
OpenWorld = false,
ReadOnly = false,
Secret = false,
LocalRequired = false)]
public sealed class CollaborationCreateCommand(
ILogger<CollaborationCreateCommand> logger,
IManagedCleanroomServiceControlPlane service,
ISubscriptionResolver subscriptionResolver)
: SubscriptionCommand<CollaborationCreateOptions, JsonElement>(subscriptionResolver)
{
private readonly ILogger<CollaborationCreateCommand> _logger = logger;
private readonly IManagedCleanroomServiceControlPlane _service = service;

public override async Task<CommandResponse> ExecuteAsync(
CommandContext context, CollaborationCreateOptions options, CancellationToken cancellationToken)
{
try
{
var result = await _service.CreateCollaborationArmResourceAsync(
options.Name,
options.ResourceGroup,
options.Subscription!,
options.Location,
options.ResourceLocation,
options.Collaborators,
options.Tenant,
options.RetryPolicy,
cancellationToken).ConfigureAwait(false);

context.Response.Message = result.Message;
context.Response.Results = ResponseResult.Create(
result.Properties,
ManagedCleanroomJsonContext.Default.JsonElement);
}
catch (Exception ex)
{
_logger.LogError(ex,
"Error creating cleanroom collaboration. Name: {Name}, ResourceGroup: {ResourceGroup}, Subscription: {Subscription}",
options.Name, options.ResourceGroup, options.Subscription);
HandleException(context, ex);
}

return context.Response;
}

protected override string GetErrorMessage(Exception ex) => ex switch
{
RequestFailedException reqEx when reqEx.Status == (int)HttpStatusCode.Conflict =>
"A collaboration with this name already exists in the resource group.",
RequestFailedException reqEx when reqEx.Status == (int)HttpStatusCode.Forbidden =>
$"Authorization failed creating the collaboration. Details: {reqEx.Message}",
RequestFailedException reqEx when reqEx.Status == (int)HttpStatusCode.NotFound =>
"Requested resource was not found. Verify the resource group, subscription, and access.",
RequestFailedException reqEx => reqEx.Message,
_ => base.GetErrorMessage(ex)
};

}
Loading