Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
The Azure MCP Server lets you manage Azure SQL Database resources by using natural language prompts. This Azure SQL tools reference provides comprehensive commands for managing databases, servers, firewall rules, and elastic pools without complex syntax.
Azure SQL Database is a fully managed platform as a service (PaaS) database engine that handles most database management functions such as upgrading, patching, backups, and monitoring without user involvement.
Note
Tool parameters: The Azure MCP Server tools define parameters for data they need to complete tasks. Some of these parameters are specific to each tool and are documented below. Other parameters are global and shared by all tools. For more information, see Tool parameters.
Database: Create database
Create a new database on an existing Azure SQL Server. This command creates a database with configurable performance tiers, size limits, and other settings.
Example prompts include:
- Create database: "Create a new SQL database named 'sales-data' in server 'prod-sql-server' in resource group 'my-resource-group'"
- Specify tier: "Create a SQL database 'inventory' with Basic tier in server 'eastus-sql' in resource group 'my-resource-group'"
- Resource group: "Create a new database called 'customer-info' on SQL server 'analytics-sql' in resource group 'my-resource-group'"
| Parameter | Required or optional | Description |
|---|---|---|
| Resource group | Required | The name of the Azure resource group. This is a logical container for Azure resources. |
| Server | Required | The Azure SQL Server name. |
| Database | Required | The Azure SQL Database name. |
| SKU name | Optional | The SKU name for the database (for example, Basic, S0, P1, GP_Gen5_2). |
| SKU tier | Optional | The SKU tier for the database (for example, Basic, Standard, Premium, GeneralPurpose). |
| SKU capacity | Optional | The SKU capacity (DTU or vCore count) for the database. |
| Collation | Optional | The collation for the database (for example, SQL_Latin1_General_CP1_CI_AS). |
| Max size bytes | Optional | The maximum size of the database in bytes. |
| Elastic pool name | Optional | The name of the elastic pool to assign the database to. |
| Zone redundant | Optional | Whether the database should be zone redundant. |
| Read scale | Optional | Read scale option for the database (Enabled or Disabled). |
Destructive: ✅ | Idempotent: ❌ | Open World: ❌ | Read Only: ❌ | Secret: ❌ | Local Required: ❌
Database: Delete database
Delete a SQL database.
Example prompts include:
- Delete database: "Delete the SQL database 'sales-data' from server 'prod-sql-server' in resource group 'my-resource-group'"
- Remove from resource group: "Remove database 'inventory' from SQL server 'eastus-sql' in resource group 'my-resource-group'"
- Delete by name: "Delete the database called 'customer-info' on server 'analytics-sql' in resource group 'my-resource-group'"
| Parameter | Required or optional | Description |
|---|---|---|
| Resource group | Required | The name of the Azure resource group. This is a logical container for Azure resources. |
| Server | Required | The Azure SQL Server name. |
| Database | Required | The Azure SQL Database name. |
Destructive: ✅ | Idempotent: ✅ | Open World: ❌ | Read Only: ❌ | Secret: ❌ | Local Required: ❌
Database: List databases
Lists all databases in your cloud resource with their configuration, status, SKU, and performance details. Use when you need to: view database inventory, check database status, compare database configurations, or find databases for management operations.
Example prompts include:
- List databases: "Show me all databases on my 'eastus-sql' server in resource group 'my-resource-group'"
- Database inventory: "List databases in resource group 'my-resource-group' on server 'eastus-sql'"
- Check database status: "What databases are currently active on my 'eastus-sql' server in resource group 'my-resource-group'?"
| Parameter | Required or optional | Description |
|---|---|---|
| Resource group | Required | The name of the Azure resource group. This is a logical container for Azure resources. |
| Server | Required | The name of the resource. |
Destructive: ❌ | Idempotent: ✅ | Open World: ❌ | Read Only: ✅ | Secret: ❌ | Local Required: ❌
Database: Rename database
Rename an existing database to a new name within the same Azure SQL server.
Example prompts include:
- Rename database: "Rename the SQL database 'sales-data' on server 'prod-sql-server' in resource group 'my-resource-group' to 'sales-archive'"
- Rename with explicit server: "Rename my Azure SQL database 'inventory' to 'inventory-2025' on server 'eastus-sql' in resource group 'my-resource-group'"
| Parameter | Required or optional | Description |
|---|---|---|
| Resource group | Required | The name of the Azure resource group. This is a logical container for Azure resources. |
| Server | Required | The Azure SQL Server name. |
| Database | Required | The Azure SQL Database name. |
| New database name | Required | The new name for the Azure SQL Database. |
Destructive: ✅ | Idempotent: ❌ | Open World: ❌ | Read Only: ❌ | Secret: ❌ | Local Required: ❌
Database: Show database details
Retrieves detailed information about a specific database. Use this command to check the configuration, performance tier, size, and other characteristics of your database.
Example prompts include:
- View database details: "Show me details for the 'inventory' database on my 'eastus-sql' server in resource group 'my-resource-group'"
- Check database configuration: "Can you tell me the specifications and current state of my customer-db database on server 'prod-sql-server' in resource group 'my-resource-group'?"
- Check performance tier: "What service tier for server 'prod-sql-server' in resource group 'my-resource-group' is my analytics database using?"
| Parameter | Required or optional | Description |
|---|---|---|
| Resource group | Required | The name of the Azure resource group. This is a logical container for Azure resources. |
| Server | Required | The name of the resource. |
| Database | Required | The name of the database on the resource. |
Destructive: ❌ | Idempotent: ✅ | Open World: ❌ | Read Only: ✅ | Secret: ❌ | Local Required: ❌
Database: Update database
Update configuration settings for an existing Azure SQL Database.
Example prompts include:
- Update performance tier: "Update the performance tier of SQL database 'sales-data' on server 'prod-sql-server' in resource group 'my-resource-group'"
- Scale database SKU: "Scale SQL database 'inventory' on server 'eastus-sql' in resource group 'my-resource-group' to use S3 SKU"
- Change database settings: "Update the Azure SQL database 'analytics' to use Premium tier on server 'eastus-sql' in resource group 'my-resource-group'"
| Parameter | Required or optional | Description |
|---|---|---|
| Resource group | Required | The name of the Azure resource group. This is a logical container for Azure resources. |
| Server | Required | The Azure SQL Server name. |
| Database | Required | The Azure SQL Database name. |
| SKU name | Optional | The SKU name for the database (for example, Basic, S0, P1, GP_Gen5_2). |
| SKU tier | Optional | The SKU tier for the database (for example, Basic, Standard, Premium, GeneralPurpose). |
| SKU capacity | Optional | The SKU capacity (DTU or vCore count) for the database. |
| Collation | Optional | The collation for the database (for example, SQL_Latin1_General_CP1_CI_AS). |
| Max size bytes | Optional | The maximum size of the database in bytes. |
| Elastic pool name | Optional | The name of the elastic pool to assign the database to. |
| Zone redundant | Optional | Whether the database should be zone redundant. |
| Read scale | Optional | Read scale option for the database (Enabled or Disabled). |
Destructive: ✅ | Idempotent: ✅ | Open World: ❌ | Read Only: ❌ | Secret: ❌ | Local Required: ❌
Server authentication: List Microsoft Entra administrators
Lists Microsoft Entra ID administrators configured for an Azure SQL server. Use this command to manage and audit identity-based access to your resource.
Example prompts include:
- Check admin users: "Show me all Microsoft Entra administrators for my 'prod-sql' server in resource group 'my-resource-group'"
- Identity access: "List Microsoft Entra admins for SQL server 'finance-db' in resource group 'my-resource-group'"
- Security check: "Who has admin access to server 'prod-sql-server' in resource group 'my-resource-group'?"
| Parameter | Required or optional | Description |
|---|---|---|
| Resource group | Required | The name of the Azure resource group. This is a logical container for Azure resources. |
| Server | Required | The name of the Azure SQL Server resource. |
Destructive: ❌ | Idempotent: ✅ | Open World: ❌ | Read Only: ✅ | Secret: ❌ | Local Required: ❌
Server: Create server
Creates a new Azure SQL server in the specified resource group and location.
Example prompts include:
- Create SQL server: "Create a new Azure SQL server named 'prod-sql-server' in resource group 'my-resource-group' with admin user 'sqladmin' and password 'MyStr0ngP@ssw0rd!' in East US"
- Specify admin user: "Create an Azure SQL server with name 'eastus-sql' in resource group 'my-resource-group' in location 'East US' with admin user 'sqladmin' and password 'SecureP@ss123!'"
- Set up server in resource group: "Set up a new SQL server called 'analytics-sql' for admin user 'sqladmin' with password 'Analytics2024!' in West US 2 in resource group 'my-resource-group' with public network access enabled"
| Parameter | Required or optional | Description |
|---|---|---|
| Resource group | Required | The name of the Azure resource group. This is a logical container for Azure resources. |
| Server | Required | The name of the Azure SQL Server resource. |
| Administrator user | Required | The administrator login name for the SQL server. |
| Administrator password | Required | The administrator password for the SQL server. |
| Location | Required | The Azure region location where the SQL server is created. |
| Version | Optional | The version of SQL Server to create (for example, 12.0). |
| Public network access | Optional | Whether public network access is enabled for the SQL server (Enabled or Disabled). |
Destructive: ✅ | Idempotent: ❌ | Open World: ❌ | Read Only: ❌ | Secret: ❌ | Local Required: ❌
Server: Delete server
Deletes an Azure SQL server and all of its databases from the specified resource group.
Example prompts include:
- Delete SQL server: "Delete the Azure SQL server 'prod-sql-server' from resource group 'my-resource-group'"
- Remove from subscription: "Remove the SQL server 'test-sql-server' from resource group 'my-resource-group'"
- Permanent delete: "Delete SQL server 'analytics-sql' in resource group 'my-resource-group' permanently"
| Parameter | Required or optional | Description |
|---|---|---|
| Resource group | Required | The name of the Azure resource group. This is a logical container for Azure resources. |
| Server | Required | The name of the Azure SQL Server resource. |
| Force | Optional | Force delete the server without confirmation prompts. |
Destructive: ✅ | Idempotent: ✅ | Open World: ❌ | Read Only: ❌ | Secret: ❌ | Local Required: ❌
Server: List servers
Lists Azure SQL servers within a resource group.
Example prompts include:
- List SQL servers: "List all Azure SQL servers in resource group 'my-resource-group'"
- Show all servers: "Show me every SQL server available in resource group 'my-resource-group'"
- Server inventory: "What SQL servers do I have in resource group 'my-resource-group'?"
| Parameter | Required or optional | Description |
|---|---|---|
| Resource group | Required | The name of the Azure resource group. This is a logical container for Azure resources. |
| Resource group | Optional | The resource group to filter servers by. |
Destructive: ❌ | Idempotent: ✅ | Open World: ❌ | Read Only: ✅ | Secret: ❌ | Local Required: ❌
Server: Show server details
Retrieves detailed information about an Azure SQL server including its configuration, status, and properties such as the fully qualified domain name, version, administrator login, and network access settings.
Example prompts include:
- Show server details: "Show me the details of Azure SQL server 'prod-sql-server' in resource group 'my-resource-group'"
- Get configuration: "Get the configuration details for SQL server 'analytics-sql' in resource group 'my-resource-group'"
- Display properties: "Display the properties of SQL server 'eastus-sql' in resource group 'my-resource-group'"
| Parameter | Required or optional | Description |
|---|---|---|
| Resource group | Required | The name of the Azure resource group. This is a logical container for Azure resources. |
| Server | Required | The name of the Azure SQL Server resource. |
Destructive: ❌ | Idempotent: ✅ | Open World: ❌ | Read Only: ✅ | Secret: ❌ | Local Required: ❌
Server firewall: List rules
Lists all firewall rules for a specific resource. Use this command to manage and review the network access settings for your resource.
Example prompts include:
- View firewall settings: "Show me all firewall rules for my 'prod-sql-server' in resource group 'my-resource-group'"
- Check access controls: "Are there any firewall rules for my analytics-db SQL server in resource group 'my-resource-group'?"
- Security audit: "List the firewall rules for our finance-db server in resource group 'my-resource-group'"
| Parameter | Required or optional | Description |
|---|---|---|
| Resource group | Required | The name of the Azure resource group. This is a logical container for Azure resources. |
| Server | Required | The name of the Azure SQL Server resource. |
Destructive: ❌ | Idempotent: ✅ | Open World: ❌ | Read Only: ✅ | Secret: ❌ | Local Required: ❌
Server firewall: Create rule
Creates a firewall rule for a resource. Firewall rules control which IP addresses are allowed to connect to the resource. You can specify either a single IP address (by setting start and end IP to the same value) or a range of IP addresses.
Example prompts include:
- Add firewall rule: "Create a firewall rule named 'office-access' for my 'prod-sql' server in resource group 'my-resource-group' allowing IP range 192.168.1.1 to 192.168.1.100"
- Set access range: "I need to set a 'test' firewall rule on my 'analytics-sql' server in resource group 'my-resource-group' to allow access from IP range 10.0.0.1 to 10.0.0.255"
- Allow single IP: "Create a firewall rule 'allow-single-ip' to allow access from IP address 203.0.113.5 to my 'production-uswest' SQL server in resource group 'my-resource-group'"
| Parameter | Required or optional | Description |
|---|---|---|
| Resource group | Required | The name of the Azure resource group. This is a logical container for Azure resources. |
| Server | Required | The name of the Azure SQL Server resource. |
| Firewall rule | Required | The name of the firewall rule. |
| Start ip address | Required | The start IP address of the firewall rule range. |
| End ip address | Required | The end IP address of the firewall rule range. |
Destructive: ✅ | Idempotent: ❌ | Open World: ❌ | Read Only: ❌ | Secret: ❌ | Local Required: ❌
Server firewall: Delete rule
Deletes a firewall rule from a resource. This operation removes the specified firewall rule, potentially restricting access for the IP addresses that were previously allowed by this rule. If the rule doesn't exist, no error is returned.
Example prompts include:
- Remove firewall rule: "Delete the firewall rule named 'office-access' from my 'prod-sql' server in resource group 'my-resource-group'"
- Revoke access: "Revoke the firewall rule 'temp-access' on my 'test-sql' server in resource group 'my-resource-group'"
- Delete access rule: "Remove the firewall rule 'guest-access' from our development SQL server in resource group 'my-resource-group'"
| Parameter | Required or optional | Description |
|---|---|---|
| Resource group | Required | The name of the Azure resource group. This is a logical container for Azure resources. |
| Server | Required | The name of the Azure SQL Server resource. |
| Firewall rule | Required | The name of the firewall rule. |
Destructive: ✅ | Idempotent: ✅ | Open World: ❌ | Read Only: ❌ | Secret: ❌ | Local Required: ❌
Elastic pools: List elastic pools
Lists all elastic pools for a specific resource. Elastic pools are a resource allocation solution that lets you manage and scale multiple databases with varying resource demands.
Example prompts include:
- View resource pools: "Show me all elastic pools on my 'main-sql' server in resource group 'my-resource-group'"
- Check elasticity: "List any elastic pools we have running on our customer-db SQL server in resource group 'my-resource-group'"
- Pool inventory: "What elastic pools are deployed on SQL server 'main-sql' in resource group 'my-resource-group'?"
| Parameter | Required or optional | Description |
|---|---|---|
| Resource group | Required | The name of the Azure resource group. This is a logical container for Azure resources. |
| Server | Required | The name of the Azure SQL Server resource. |
Destructive: ❌ | Idempotent: ✅ | Open World: ❌ | Read Only: ✅ | Secret: ❌ | Local Required: ❌