{ "swagger": "2.0", "info": { "title": "SqlManagementClient", "version": "2025-01-01", "description": "The Azure SQL Database management API provides a RESTful set of web APIs that interact with Azure SQL Database services to manage your databases. The API enables users to create, retrieve, update, and delete databases, servers, and other entities.", "x-typespec-generated": [ { "emitter": "@azure-tools/typespec-autorest" } ] }, "schemes": [ "https" ], "host": "management.azure.com", "produces": [ "application/json" ], "consumes": [ "application/json" ], "security": [ { "azure_auth": [ "user_impersonation" ] } ], "securityDefinitions": { "azure_auth": { "type": "oauth2", "description": "Azure Active Directory OAuth2 Flow.", "flow": "implicit", "authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize", "scopes": { "user_impersonation": "impersonate your user account" } } }, "tags": [ { "name": "MaintenanceWindowOptions" } ], "paths": { "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/maintenanceWindowOptions/current": { "get": { "operationId": "MaintenanceWindowOptions_Get", "tags": [ "MaintenanceWindowOptions" ], "description": "Gets a list of available maintenance windows.", "parameters": [ { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/ApiVersionParameter" }, { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/SubscriptionIdParameter" }, { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/ResourceGroupNameParameter" }, { "name": "serverName", "in": "path", "description": "The name of the server.", "required": true, "type": "string" }, { "name": "databaseName", "in": "path", "description": "The name of the database.", "required": true, "type": "string" }, { "name": "maintenanceWindowOptionsName", "in": "query", "description": "Maintenance window options name.", "required": true, "type": "string" } ], "responses": { "200": { "description": "Azure operation completed successfully.", "schema": { "$ref": "#/definitions/MaintenanceWindowOptions" } }, "default": { "description": "An unexpected error response.", "schema": { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/definitions/ErrorResponse" } } }, "x-ms-examples": { "Gets a list of available maintenance windows for a selected database.": { "$ref": "./examples/GetMaintenanceWindowOptions.json" } } } } }, "definitions": { "MaintenanceWindowOptions": { "type": "object", "description": "Maintenance window options.", "properties": { "properties": { "$ref": "#/definitions/MaintenanceWindowOptionsProperties", "description": "Resource properties.", "x-ms-client-flatten": true } }, "allOf": [ { "$ref": "../../../../../../common-types/resource-management/v5/types.json#/definitions/ProxyResource" } ] }, "MaintenanceWindowOptionsProperties": { "type": "object", "description": "Maintenance window options properties.", "properties": { "isEnabled": { "type": "boolean", "description": "Whether maintenance windows are enabled for the database." }, "maintenanceWindowCycles": { "type": "array", "description": "Available maintenance cycles e.g. {Saturday, 0, 48*60}, {Wednesday, 0, 24*60}.", "items": { "$ref": "./common.json#/definitions/MaintenanceWindowTimeRange" } }, "minDurationInMinutes": { "type": "integer", "format": "int32", "description": "Minimum duration of maintenance window." }, "defaultDurationInMinutes": { "type": "integer", "format": "int32", "description": "Default duration for maintenance window." }, "minCycles": { "type": "integer", "format": "int32", "description": "Minimum number of maintenance windows cycles to be set on the database." }, "timeGranularityInMinutes": { "type": "integer", "format": "int32", "description": "Time granularity in minutes for maintenance windows." }, "allowMultipleMaintenanceWindowsPerCycle": { "type": "boolean", "description": "Whether we allow multiple maintenance windows per cycle." } } } }, "parameters": {} }