Skill

Provision and Manage Azure Playwright Workspaces

.NET management-plane SDK for Microsoft Playwright Testing - provision workspaces, quotas, and name checks via ARM.

Works with azureplaywright

75
Spark score
out of 100
Updated 10 days ago
Version 15.7.0

Add to Favorites

Why it matters

Automate the provisioning and management of Microsoft Playwright Testing workspaces within Azure. This asset enables efficient setup and configuration for large-scale cloud browser testing environments.

Outcomes

What it gets done

01

Create and configure Playwright testing workspaces in Azure.

02

Manage workspace lifecycle, including updates and deletion.

03

Check resource name availability for new workspaces.

04

Retrieve subscription and workspace-level quota information.

Install

Add it to your toolbox

Run in your project directory:

curl -fsSL https://spark.entire.vc/get/ag-azure-resource-manager-playwright-dotnet | bash

Overview

Azure.ResourceManager.Playwright (.NET)

A .NET SDK reference for provisioning Microsoft Playwright Testing workspaces through Azure Resource Manager - creation, name checks, quotas, and handoff to test execution. Use when provisioning or managing Playwright Testing workspace infrastructure from .NET, not for writing or running the tests themselves.

What it does

Azure.ResourceManager.Playwright is the .NET management-plane SDK for provisioning Microsoft Playwright Testing workspaces through Azure Resource Manager - creating, listing, updating, and deleting PlaywrightWorkspaceResource objects, checking workspace-name availability, and reading subscription- and workspace-level quotas. It is explicitly separate from Azure.Developer.MicrosoftPlaywrightTesting.NUnit, the test-execution SDK that actually runs Playwright tests at scale on cloud browsers once a workspace exists.

When to use - and when NOT to

Use this skill when provisioning or managing the cloud infrastructure behind Microsoft Playwright Testing - creating a workspace in a given Azure region, checking a proposed name is available before creating it, monitoring quota usage, or tagging and updating workspace metadata. It is not for writing or running Playwright tests themselves; once a workspace is created, its DataplaneUri is handed off to the separate test-execution SDK, which is where actual browser test runs happen.

Inputs and outputs

Workspace creation takes a PlaywrightWorkspaceData with a location, optional RegionalAffinity and LocalAuth settings, and tags, submitted via workspaceCollection.CreateOrUpdateAsync(WaitUntil.Completed, name, data) as a long-running operation; the returned PlaywrightWorkspaceResource exposes DataplaneUri (the URL test execution connects to) and a WorkspaceId GUID. Updates go through PlaywrightWorkspacePatch (typically just tags). Name checks use PlaywrightCheckNameAvailabilityContent against subscription.CheckPlaywrightNameAvailabilityAsync, returning IsNameAvailable plus a reason if not. Quota reads (subscription.GetPlaywrightQuotasAsync(location) at the subscription level, workspace.GetAllPlaywrightWorkspaceQuota() per workspace) return Limit/Used pairs.

var workspaceData = new PlaywrightWorkspaceData(AzureLocation.WestUS3)
{
    RegionalAffinity = PlaywrightRegionalAffinity.Enabled,
    LocalAuth = PlaywrightLocalAuth.Enabled
};
var operation = await workspaceCollection.CreateOrUpdateAsync(
    WaitUntil.Completed, "my-playwright-workspace", workspaceData);

Integrations

Authenticates via DefaultAzureCredential; the resource sits under the Microsoft.LoadTestService resource provider (Microsoft.LoadTestService/playwrightWorkspaces, API version 2025-09-01). After creating a workspace, its DataplaneUri is typically set as the PLAYWRIGHT_SERVICE_URL environment variable consumed by Azure.Developer.MicrosoftPlaywrightTesting.NUnit (test execution at scale) or Azure.Developer.Playwright (the Playwright client library) - this SDK only sets up the infrastructure those packages then run against.

Who it's for

.NET platform teams and developers automating Microsoft Playwright Testing infrastructure - creating workspaces per team or environment, tracking regional quota usage, and wiring a newly-created workspace's DataplaneUri into CI pipelines that run the actual test suites via the separate execution SDKs. The skill's own best practices call out storing DataplaneUri immediately after creation, using CreateOrUpdateAsync for idempotent provisioning, always authenticating with DefaultAzureCredential, and handling RequestFailedException explicitly for 409 (workspace already exists) and 400 (bad request) cases. WaitUntil.Completed is recommended for provisioning steps that must finish before the pipeline continues, while WaitUntil.Started suits cases where the caller wants to poll status manually or kick off several long-running operations in parallel.

FAQ

Common questions

Discussion

Questions & comments · 0

Sign In Sign in to leave a comment.