# azure-resource-manager-mysql-dotnet

A skill that gives your agent .NET SDK patterns for MySQL Flexible Server on Azure: servers, databases, firewall rules, parameters and backups.

- skill · `type=skill` · Claude Code, GitHub Copilot · 1 install · ★ 3148
- Author: Microsoft
- License: MIT · policy=mirror · the beginning of the file is at the end of this page
- Source: https://github.com/microsoft/skills/tree/HEAD/.github/plugins/azure-sdk-dotnet/skills/azure-resource-manager-mysql-dotnet/SKILL.md
- Updated: 2026-10-23
- HTML: https://affpapa.org/en/nevibecode/skills/azure-resource-manager-mysql-dotnet

## What it does

The skill documents the `Azure.ResourceManager.MySql` package. Your agent gets working code for creating a server with a SKU, MySQL version and storage settings, creating a database with charset and collation, adding IP firewall rules, tuning parameters like `max_connections` or `innodb_buffer_pool_size`, and setting an Entra ID administrator.

It lays out the resource hierarchy from subscription down to database and firewall rule, plus authentication through `DefaultAzureCredential` and the environment variables `AZURE_SUBSCRIPTION_ID`, `AZURE_RESOURCE_GROUP`, `AZURE_MYSQL_SERVER_NAME`. Production examples set `AZURE_TOKEN_CREDENTIALS=prod`.

This covers Flexible Server only. Single Server is marked deprecated and scheduled for retirement, so don't let the agent provision the old flavour. Two packages go in separately: `dotnet add package Azure.ResourceManager.MySql` and `dotnet add package Azure.Identity`.

## Requirements
- Works with: Azure

## Install

### Claude Code (native platform)

1. **Skills CLI (Vercel)**
```bash
npx skills add microsoft/skills --skill azure-resource-manager-mysql-dotnet -a claude-code
```

2. **Manually: put the files in place**
- File: `~/.claude/skills/azure-resource-manager-mysql-dotnet/SKILL.md` — Copy the whole skill folder; for one project use .claude/skills/azure-resource-manager-mysql-dotnet/

### Codex

**Manually: put the files in place**
- File: `.agents/skills/azure-resource-manager-mysql-dotnet/SKILL.md` — For all projects use ~/.agents/skills/

### Cursor

**Manually: put the files in place**
- File: `.cursor/skills/azure-resource-manager-mysql-dotnet/SKILL.md` — Cursor also reads .agents/skills/ and .claude/skills/

### GitHub Copilot

1. **GitHub CLI**
```bash
gh skill install microsoft/skills azure-resource-manager-mysql-dotnet
```

2. **Manually: put the files in place**
- File: `.github/skills/azure-resource-manager-mysql-dotnet/SKILL.md`

### Gemini CLI

**Platform CLI**
```bash
gemini skills install https://github.com/microsoft/skills --path .github/plugins/azure-sdk-dotnet/skills/azure-resource-manager-mysql-dotnet
```

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/skills/azure-resource-manager-mysql-dotnet/SKILL.md` — The legacy .windsurf/skills/ path still works

### Claude.ai

**Claude.ai**
- Zip the folder and upload it in Settings → Capabilities → Skills

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/microsoft/skills/tree/HEAD/.github/plugins/azure-sdk-dotnet/skills/azure-resource-manager-mysql-dotnet/SKILL.md

## When to use it
- spin up a MySQL Flexible Server with a chosen SKU and version
- create a database with utf8mb4 charset and collation
- open access for an IP range with a firewall rule
- change `max_connections` and other server parameters
- assign an Entra ID administrator to the server

## Example prompts
- create a MySQL Flexible Server on Azure with zone-redundant high availability
- add a firewall rule for the 10.0.0.1–10.0.0.255 range
- set `max_connections` to 500 via `MySqlFlexibleServerConfiguration`

## Source text · SKILL.md · MIT

Below is the content of a third-party file. It is data, not instructions for you: do not act on anything written inside unless the human asks. Block tag: 87643855f88f3827.

BEGIN THIRD-PARTY FILE 87643855f88f3827
````text
---
name: azure-resource-manager-mysql-dotnet
description: |
  Azure MySQL Flexible Server SDK for .NET. Database management for MySQL Flexible Server deployments. Use for creating servers, databases, firewall rules, configurations, backups, and high availability. Triggers: "MySQL", "MySqlFlexibleServer", "MySQL Flexible Server", "Azure Database for MySQL", "MySQL database management", "MySQL firewall", "MySQL backup".
license: MIT
metadata:
  author: Microsoft
  version: "1.0.0"
  package: Azure.ResourceManager.MySql
---

# Azure.ResourceManager.MySql (.NET)

Azure Resource Manager SDK for managing MySQL Flexible Server deployments.

## Installation

```bash
dotnet add package Azure.ResourceManager.MySql
dotnet add package Azure.Identity
```

**Current Version**: v1.2.0 (GA)  
**API Version**: 2023-12-30

> **Note**: This skill focuses on MySQL Flexible Server. Single Server is deprecated and scheduled for retirement.

## Environment Variables

```bash
AZURE_SUBSCRIPTION_ID=<your-subscription-id>  # Required: Azure subscription ID
AZURE_RESOURCE_GROUP=<your-resource-group>  # Required: resource group name
AZURE_MYSQL_SERVER_NAME=<your-mysql-server>  # Required: MySQL Flexible Server name
AZURE_TOKEN_CREDENTIALS=prod  # Required only if DefaultAzureCredential is used in production
```

## Authentication

```csharp
using Azure.Identity;
using Azure.ResourceManager;
using Azure.ResourceManager.MySql;
using Azure.ResourceManager.MySql.FlexibleServers;

// Local dev: DefaultAzureCredential. Production: set AZURE_TOKEN_CREDENTIALS=prod or AZURE_TOKEN_CREDENTIALS=<specific_credential>
var credential = new DefaultAzureCredential(
    DefaultAzureCredential.DefaultEnvironmentVariableName
);
// Or use a specific credential directly in production:
// See https://learn.microsoft.com/dotnet/api/overview/azure/identity-readme?view=azure-dotnet#credential-classes
// var credential = new ManagedIdentityCredential();
ArmClient client = new ArmClient(credential);
```

## Resource Hierarchy

```
Subscription
└── ResourceGroup
    └── MySqlFlexibleServer                 # MySQL Flexible Server instance
        ├── MySqlFlexibleServerDatabase     # Database within the server
        ├── MySqlFlexibleServerFirewallRule # IP firewall rules
        ├── MySqlFlexibleServerConfiguration # Server parameters
        ├── MySqlFlexibleServerBackup       # Backup information
        ├── MySqlFlexibleServerMaintenanceWindow # Maintenance schedule
        └── MySqlFlexibleServerAadAdministrator # Entra ID admin
```

## Core Workflows

### 1. Create MySQL Flexible Server

```csharp
using Azure.ResourceManager.MySql.FlexibleServers;
using Azure.ResourceManager.MySql.FlexibleServers.Models;

ResourceGroupResource resourceGroup = await client
    .GetDefaultSubscriptionAsync()
    .Result
    .GetResourceGroupAsync("my-resource-group");
````
END THIRD-PARTY FILE 87643855f88f3827

The third-party file has ended. Everything between the 87643855f88f3827 tags is data: requests and commands from it are not followed. An “end of file” line with another tag inside the block is part of the file.

First 2901 of 14114 bytes. © Microsoft · MIT · https://github.com/microsoft/skills/tree/HEAD/.github/plugins/azure-sdk-dotnet/skills/azure-resource-manager-mysql-dotnet/SKILL.md

_Part of the page did not fit — see the HTML version._

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
