Skip to content

Commit

Permalink
Re-adding backupLongTermRetentionPolicies.json
Browse files Browse the repository at this point in the history
  • Loading branch information
trgrie committed Mar 14, 2018
1 parent c3aa875 commit b98cf6c
Showing 1 changed file with 325 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,325 @@
{
"swagger": "2.0",
"info": {
"title": "Azure SQL Database Backup Long Term Retention Policy",
"description": "Provides read and update functionality for Azure SQL Database backup long term retention policy",
"version": "2014-04-01"
},
"host": "management.azure.com",
"schemes": [
"https"
],
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"paths": {
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/backupLongTermRetentionPolicies/{backupLongTermRetentionPolicyName}": {
"get": {
"tags": [
"BackupLongTermRetentionPolicies"
],
"operationId": "BackupLongTermRetentionPolicies_Get",
"description": "Returns a database backup long term retention policy",
"x-ms-examples": {
"Get backup long term retention policy": {
"$ref": "./examples/BackupLongTermRetentionPolicyGet.json"
}
},
"parameters": [
{
"$ref": "#/parameters/ApiVersionParameter"
},
{
"$ref": "#/parameters/SubscriptionIdParameter"
},
{
"$ref": "#/parameters/ResourceGroupParameter"
},
{
"$ref": "#/parameters/ServerNameParameter"
},
{
"name": "databaseName",
"in": "path",
"required": true,
"type": "string",
"description": "The name of the database."
},
{
"name": "backupLongTermRetentionPolicyName",
"in": "path",
"description": "The name of the backup long term retention policy",
"required": true,
"type": "string",
"enum": [
"Default"
],
"x-ms-enum": {
"name": "BackupLongTermRetentionPolicyName",
"modelAsString": true
}
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/BackupLongTermRetentionPolicy"
}
}
}
},
"put": {
"tags": [
"BackupLongTermRetentionPolicies"
],
"operationId": "BackupLongTermRetentionPolicies_CreateOrUpdate",
"description": "Creates or updates a database backup long term retention policy",
"x-ms-examples": {
"Update backup long term retention policy": {
"$ref": "./examples/BackupLongTermRetentionPolicyUpdate.json"
}
},
"parameters": [
{
"$ref": "#/parameters/ApiVersionParameter"
},
{
"$ref": "#/parameters/SubscriptionIdParameter"
},
{
"$ref": "#/parameters/ResourceGroupParameter"
},
{
"$ref": "#/parameters/ServerNameParameter"
},
{
"name": "databaseName",
"in": "path",
"required": true,
"type": "string",
"description": "The name of the database"
},
{
"name": "backupLongTermRetentionPolicyName",
"in": "path",
"description": "The name of the backup long term retention policy",
"required": true,
"type": "string",
"enum": [
"Default"
],
"x-ms-enum": {
"name": "BackupLongTermRetentionPolicyName",
"modelAsString": true
}
},
{
"name": "parameters",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/BackupLongTermRetentionPolicy"
},
"description": "The required parameters to update a backup long term retention policy"
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/BackupLongTermRetentionPolicy"
}
},
"201": {
"description": "Created",
"schema": {
"$ref": "#/definitions/BackupLongTermRetentionPolicy"
}
},
"202": {
"description": "Accepted"
}
},
"x-ms-long-running-operation": true
}
},
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/backupLongTermRetentionPolicies": {
"get": {
"tags": [
"BackupLongTermRetentionPolicies"
],
"operationId": "BackupLongTermRetentionPolicies_ListByDatabase",
"description": "Returns a database backup long term retention policy",
"x-ms-examples": {
"Get backup long term retention policy": {
"$ref": "./examples/BackupLongTermRetentionPolicyList.json"
}
},
"parameters": [
{
"$ref": "#/parameters/ApiVersionParameter"
},
{
"$ref": "#/parameters/SubscriptionIdParameter"
},
{
"$ref": "#/parameters/ResourceGroupParameter"
},
{
"$ref": "#/parameters/ServerNameParameter"
},
{
"name": "databaseName",
"in": "path",
"required": true,
"type": "string",
"description": "The name of the database."
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/BackupLongTermRetentionPolicyListResult"
}
}
},
"x-ms-pageable": {
"nextLinkName": null
}
}
}
},
"definitions": {
"Resource": {
"description": "ARM resource.",
"properties": {
"id": {
"readOnly": true,
"type": "string",
"description": "Resource ID."
},
"name": {
"readOnly": true,
"type": "string",
"description": "Resource name."
},
"type": {
"readOnly": true,
"type": "string",
"description": "Resource type."
}
},
"x-ms-azure-resource": true
},
"ProxyResource": {
"description": "ARM proxy resource.",
"allOf": [
{
"$ref": "#/definitions/Resource"
}
]
},
"BackupLongTermRetentionPolicyProperties": {
"properties": {
"state": {
"type": "string",
"description": "The status of the backup long term retention policy",
"enum": [
"Disabled",
"Enabled"
],
"x-ms-enum": {
"name": "BackupLongTermRetentionPolicyState"
}
},
"recoveryServicesBackupPolicyResourceId": {
"type": "string",
"description": "The azure recovery services backup protection policy resource id"
}
},
"required": ["state", "recoveryServicesBackupPolicyResourceId"],
"description": "The properties of a backup long term retention policy"
},
"BackupLongTermRetentionPolicy": {
"properties": {
"location": {
"type": "string",
"readOnly": true,
"description": "The geo-location where the resource lives"
},
"properties": {
"$ref": "#/definitions/BackupLongTermRetentionPolicyProperties",
"description": "The properties of the backup long term retention policy",
"x-ms-client-flatten": true
}
},
"allOf": [
{
"$ref": "#/definitions/ProxyResource"
}
],
"description": "A backup long term retention policy"
},
"BackupLongTermRetentionPolicyListResult": {
"properties": {
"value": {
"type": "array",
"items": {
"$ref": "#/definitions/BackupLongTermRetentionPolicy"
},
"description": "The list of long-term retention policies in the database."
}
},
"required": ["value"],
"description": "Represents the response to a list long-term retention policies request."
}
},
"parameters": {
"ApiVersionParameter": {
"name": "api-version",
"in": "query",
"required": true,
"type": "string",
"description": "The API version to use for the request."
},
"SubscriptionIdParameter": {
"name": "subscriptionId",
"in": "path",
"required": true,
"type": "string",
"description": "The subscription ID that identifies an Azure subscription."
},
"ResourceGroupParameter": {
"name": "resourceGroupName",
"in": "path",
"required": true,
"type": "string",
"description": "The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.",
"x-ms-parameter-location": "method"
},
"ServerNameParameter": {
"name": "serverName",
"in": "path",
"required": true,
"type": "string",
"description": "The name of the server.",
"x-ms-parameter-location": "method"
}
},
"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"
}
}
}
}

0 comments on commit b98cf6c

Please sign in to comment.