{ "swagger": "2.0", "info": { "title": "Azure SQL Database replication links", "description": "Provides read, delete, and failover functionality for Azure SQL Database replication links.", "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}/replicationLinks/{linkId}": { "delete": { "tags": [ "DatabaseReplicationLinks" ], "operationId": "ReplicationLinks_Delete", "description": "Deletes a database replication link. Cannot be done during failover.", "x-ms-examples": { "Delete a replication link": { "$ref": "./examples/ReplicationLinkDelete.json" } }, "parameters": [ { "$ref": "./common/v1/types.json#/parameters/ApiVersionParameter" }, { "$ref": "./common/v1/types.json#/parameters/SubscriptionIdParameter" }, { "$ref": "./common/v1/types.json#/parameters/ResourceGroupParameter" }, { "$ref": "#/parameters/ServerNameParameter" }, { "name": "databaseName", "in": "path", "required": true, "type": "string", "description": "The name of the database that has the replication link to be dropped." }, { "name": "linkId", "in": "path", "required": true, "type": "string", "description": "The ID of the replication link to be deleted." } ], "responses": { "200": { "description": "OK" }, "204": { "description": "NoContent" } } } }, "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/replicationLinks/{linkId}/failover": { "post": { "tags": [ "DatabaseReplicationLinks" ], "operationId": "ReplicationLinks_Failover", "description": "Sets which replica database is primary by failing over from the current primary replica database.", "x-ms-examples": { "Failover a replication link": { "$ref": "./examples/ReplicationLinkFailover.json" } }, "parameters": [ { "$ref": "./common/v1/types.json#/parameters/ApiVersionParameter" }, { "$ref": "./common/v1/types.json#/parameters/SubscriptionIdParameter" }, { "$ref": "./common/v1/types.json#/parameters/ResourceGroupParameter" }, { "$ref": "#/parameters/ServerNameParameter" }, { "name": "databaseName", "in": "path", "required": true, "type": "string", "description": "The name of the database that has the replication link to be failed over." }, { "name": "linkId", "in": "path", "required": true, "type": "string", "description": "The ID of the replication link to be failed over." } ], "responses": { "204": { "description": "No Content" }, "202": { "description": "Accepted" } }, "x-ms-long-running-operation": true } }, "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/replicationLinks/{linkId}/forceFailoverAllowDataLoss": { "post": { "tags": [ "DatabaseReplicationLinks" ], "operationId": "ReplicationLinks_FailoverAllowDataLoss", "description": "Sets which replica database is primary by failing over from the current primary replica database. This operation might result in data loss.", "x-ms-examples": { "Failover a replication link": { "$ref": "./examples/ReplicationLinkFailover.json" } }, "parameters": [ { "$ref": "./common/v1/types.json#/parameters/ApiVersionParameter" }, { "$ref": "./common/v1/types.json#/parameters/SubscriptionIdParameter" }, { "$ref": "./common/v1/types.json#/parameters/ResourceGroupParameter" }, { "$ref": "#/parameters/ServerNameParameter" }, { "name": "databaseName", "in": "path", "required": true, "type": "string", "description": "The name of the database that has the replication link to be failed over." }, { "name": "linkId", "in": "path", "required": true, "type": "string", "description": "The ID of the replication link to be failed over." } ], "responses": { "204": { "description": "No Content" }, "202": { "description": "Accepted" } }, "x-ms-long-running-operation": true } }, "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/replicationLinks/{linkId}/unlink": { "post": { "tags": [ "DatabaseReplicationLinks" ], "operationId": "ReplicationLinks_Unlink", "description": "Deletes a database replication link in forced or friendly way.", "x-ms-examples": { "Delete replication link": { "$ref": "./examples/ReplicationLinkUnlink.json" } }, "parameters": [ { "$ref": "./common/v1/types.json#/parameters/ApiVersionParameter" }, { "$ref": "./common/v1/types.json#/parameters/SubscriptionIdParameter" }, { "$ref": "./common/v1/types.json#/parameters/ResourceGroupParameter" }, { "$ref": "#/parameters/ServerNameParameter" }, { "name": "databaseName", "in": "path", "required": true, "type": "string", "description": "The name of the database that has the replication link to be failed over." }, { "name": "linkId", "in": "path", "required": true, "type": "string", "description": "The ID of the replication link to be failed over." }, { "name": "parameters", "in": "body", "required": true, "schema": { "$ref": "#/definitions/UnlinkParameters" }, "description": "The required parameters for unlinking replication link." } ], "responses": { "204": { "description": "No Content" }, "202": { "description": "Accepted" } }, "x-ms-long-running-operation": true } } }, "definitions": { "UnlinkParameters": { "properties": { "forcedTermination": { "type": "boolean", "description": "Determines whether link will be terminated in a forced or a friendly way." } }, "description": "Represents the parameters for Unlink Replication Link request." } }, "parameters": { "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" } } } }