{ "swagger": "2.0", "info": { "title": "Microsoft.ServiceLinker", "description": "Microsoft.ServiceLinker provider", "version": "2021-11-01-preview" }, "host": "management.azure.com", "schemes": [ "https" ], "consumes": [ "application/json" ], "produces": [ "application/json" ], "security": [ { "azure_auth": [ "user_impersonation" ] } ], "securityDefinitions": { "azure_auth": { "type": "oauth2", "authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize", "flow": "implicit", "description": "Azure Active Directory OAuth2 Flow.", "scopes": { "user_impersonation": "impersonate your user account" } } }, "paths": { "/{resourceUri}/providers/Microsoft.ServiceLinker/linkers": { "get": { "deprecated": false, "description": "Returns list of Linkers which connects to the resource.", "operationId": "Linker_List", "x-ms-examples": { "LinkList": { "$ref": "./examples/LinkList.json" } }, "parameters": [ { "$ref": "#/parameters/ResourceUriParameter" }, { "$ref": "../../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" } ], "responses": { "200": { "description": "linker details.", "schema": { "$ref": "#/definitions/LinkerList" } }, "default": { "description": "Error response describing why the operation failed.", "schema": { "$ref": "../../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse" } } }, "x-ms-pageable": { "nextLinkName": "nextLink" } } }, "/{resourceUri}/providers/Microsoft.ServiceLinker/linkers/{linkerName}": { "get": { "description": "Returns Linker resource for a given name.", "operationId": "Linker_Get", "x-ms-examples": { "Link": { "$ref": "./examples/Link.json" } }, "parameters": [ { "$ref": "#/parameters/ResourceUriParameter" }, { "$ref": "../../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" }, { "$ref": "#/parameters/LinkerNameParameter" } ], "responses": { "200": { "description": "Linker details.", "schema": { "$ref": "#/definitions/LinkerResource" } }, "default": { "description": "Error response describing why the operation failed.", "schema": { "$ref": "../../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse" } } } }, "put": { "description": "Create or update linker resource.", "operationId": "Linker_CreateOrUpdate", "x-ms-long-running-operation": true, "x-ms-long-running-operation-options": { "final-state-via": "azure-async-operation" }, "x-ms-examples": { "PutLink": { "$ref": "./examples/PutLink.json" }, "PutLinkWithServiceEndpoint": { "$ref": "./examples/PutLinkWithServiceEndpoint.json" } }, "parameters": [ { "$ref": "#/parameters/ResourceUriParameter" }, { "$ref": "../../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" }, { "$ref": "#/parameters/LinkerNameParameter" }, { "name": "parameters", "description": "Linker details.", "in": "body", "required": true, "schema": { "$ref": "#/definitions/LinkerResource" } } ], "responses": { "200": { "description": "Successful.", "schema": { "$ref": "#/definitions/LinkerResource" } }, "201": { "description": "Long running operation.", "schema": { "$ref": "#/definitions/LinkerResource" } }, "default": { "description": "Error response describing why the operation failed.", "schema": { "$ref": "../../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse" } } } }, "delete": { "tags": [ "Links" ], "operationId": "Linker_Delete", "x-ms-long-running-operation": true, "x-ms-long-running-operation-options": { "final-state-via": "azure-async-operation" }, "description": "Delete a link.", "x-ms-examples": { "DeleteLink": { "$ref": "./examples/DeleteLink.json" } }, "parameters": [ { "$ref": "#/parameters/ResourceUriParameter" }, { "$ref": "../../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" }, { "$ref": "#/parameters/LinkerNameParameter" } ], "responses": { "200": { "description": "OK. The link is deleted." }, "204": { "description": "Deleted. The link is not found." }, "202": { "description": "Long running operation." }, "default": { "description": "Error response describing why the operation failed.", "schema": { "$ref": "../../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse" } } } }, "patch": { "tags": [ "Links" ], "operationId": "Linker_Update", "description": "Operation to update an existing link.", "x-ms-long-running-operation": true, "x-ms-long-running-operation-options": { "final-state-via": "azure-async-operation" }, "x-ms-examples": { "PatchLink": { "$ref": "./examples/PatchLink.json" } }, "parameters": [ { "$ref": "#/parameters/ResourceUriParameter" }, { "$ref": "../../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" }, { "$ref": "#/parameters/LinkerNameParameter" }, { "name": "parameters", "description": "Linker details.", "in": "body", "required": true, "schema": { "$ref": "#/definitions/LinkerPatch" } } ], "responses": { "200": { "description": "Success. The response describes a link.", "schema": { "$ref": "#/definitions/LinkerResource" } }, "201": { "description": "Long running operation.", "schema": { "$ref": "#/definitions/LinkerResource" } }, "default": { "description": "Error response describing why the operation failed.", "schema": { "$ref": "../../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse" } } } } }, "/{resourceUri}/providers/Microsoft.ServiceLinker/linkers/{linkerName}/validateLinker": { "post": { "tags": [ "Links" ], "operationId": "Linker_Validate", "description": "Validate a link.", "x-ms-long-running-operation": true, "x-ms-long-running-operation-options": { "final-state-via": "azure-async-operation" }, "x-ms-examples": { "ValidateLinkSuccess": { "$ref": "./examples/ValidateLinkSuccess.json" }, "ValidateLinkFailure": { "$ref": "./examples/ValidateLinkFailure.json" } }, "parameters": [ { "$ref": "#/parameters/ResourceUriParameter" }, { "$ref": "../../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" }, { "$ref": "#/parameters/LinkerNameParameter" } ], "responses": { "200": { "description": "OK. The request has succeeded.", "schema": { "$ref": "#/definitions/ValidateResult" } }, "202": { "description": "Accepted - Returns this status until the asynchronous operation has completed." }, "default": { "description": "Error response describing why the operation failed.", "schema": { "$ref": "../../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse" } } } } }, "/{resourceUri}/providers/Microsoft.ServiceLinker/linkers/{linkerName}/listConfigurations": { "post": { "tags": [ "Links" ], "operationId": "Linker_ListConfigurations", "description": "list source configurations for a linker.", "x-ms-examples": { "GetConfiguration": { "$ref": "./examples/GetConfigurations.json" } }, "parameters": [ { "$ref": "#/parameters/ResourceUriParameter" }, { "$ref": "../../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" }, { "$ref": "#/parameters/LinkerNameParameter" } ], "responses": { "200": { "description": "OK. The request has succeeded.", "schema": { "$ref": "#/definitions/SourceConfigurationResult" } }, "default": { "description": "Error response describing why the operation failed.", "schema": { "$ref": "../../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse" } } } } }, "/providers/Microsoft.ServiceLinker/operations": { "get": { "tags": [ "Operations" ], "operationId": "Operations_List", "description": "Lists the available ServiceLinker REST API operations.", "x-ms-examples": { "GetConfiguration": { "$ref": "./examples/OperationsList.json" } }, "parameters": [ { "$ref": "../../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter" } ], "responses": { "200": { "description": "OK. The request has succeeded.", "schema": { "$ref": "../../../../../../common-types/resource-management/v2/types.json#/definitions/OperationListResult" } }, "default": { "description": "Error response describing why the operation failed.", "schema": { "$ref": "../../../../../../common-types/resource-management/v2/types.json#/definitions/ErrorResponse" } } }, "x-ms-pageable": { "nextLinkName": "nextLink" } } } }, "definitions": { "AuthType": { "description": "The authentication type.", "type": "string", "enum": [ "systemAssignedIdentity", "userAssignedIdentity", "servicePrincipalSecret", "servicePrincipalCertificate", "secret" ], "x-ms-enum": { "name": "AuthType", "modelAsString": true } }, "AuthInfoBase": { "description": "The authentication info", "discriminator": "authType", "type": "object", "properties": { "authType": { "description": "The authentication type.", "$ref": "#/definitions/AuthType" } }, "required": [ "authType" ] }, "SecretAuthInfo": { "x-ms-discriminator-value": "secret", "type": "object", "description": "The authentication info when authType is secret", "allOf": [ { "$ref": "#/definitions/AuthInfoBase" } ], "properties": { "name": { "description": "Username or account name for secret auth.", "type": "string" }, "secret": { "description": "Password or account key for secret auth.", "type": "string", "x-ms-secret": true } } }, "UserAssignedIdentityAuthInfo": { "x-ms-discriminator-value": "userAssignedIdentity", "type": "object", "description": "The authentication info when authType is userAssignedIdentity", "allOf": [ { "$ref": "#/definitions/AuthInfoBase" } ], "properties": { "clientId": { "description": "Client Id for userAssignedIdentity.", "type": "string" }, "subscriptionId": { "description": "Subscription id for userAssignedIdentity.", "type": "string" } }, "required": [ "clientId", "subscriptionId" ] }, "SystemAssignedIdentityAuthInfo": { "x-ms-discriminator-value": "systemAssignedIdentity", "type": "object", "description": "The authentication info when authType is systemAssignedIdentity", "allOf": [ { "$ref": "#/definitions/AuthInfoBase" } ] }, "ServicePrincipalSecretAuthInfo": { "x-ms-discriminator-value": "servicePrincipalSecret", "type": "object", "description": "The authentication info when authType is servicePrincipal secret", "allOf": [ { "$ref": "#/definitions/AuthInfoBase" } ], "properties": { "clientId": { "description": "ServicePrincipal application clientId for servicePrincipal auth.", "type": "string" }, "principalId": { "description": "Principal Id for servicePrincipal auth.", "type": "string" }, "secret": { "description": "Secret for servicePrincipal auth.", "type": "string", "x-ms-secret": true } }, "required": [ "clientId", "principalId", "secret" ] }, "ServicePrincipalCertificateAuthInfo": { "x-ms-discriminator-value": "servicePrincipalCertificate", "type": "object", "description": "The authentication info when authType is servicePrincipal certificate", "allOf": [ { "$ref": "#/definitions/AuthInfoBase" } ], "properties": { "clientId": { "description": "Application clientId for servicePrincipal auth.", "type": "string" }, "principalId": { "description": "Principal Id for servicePrincipal auth.", "type": "string" }, "certificate": { "description": "ServicePrincipal certificate for servicePrincipal auth.", "type": "string", "x-ms-secret": true } }, "required": [ "clientId", "principalId", "certificate" ] }, "LinkerResource": { "type": "object", "description": "Linker of source and target resource", "allOf": [ { "$ref": "../../../../../../common-types/resource-management/v2/types.json#/definitions/ProxyResource", "description": "The resource model definition for an Azure Resource Manager proxy resource." } ], "required": [ "properties" ], "properties": { "properties": { "description": "The properties of the linker.", "$ref": "#/definitions/LinkerProperties", "x-ms-client-flatten": true }, "systemData": { "readOnly": true, "$ref": "../../../../../../common-types/resource-management/v2/types.json#/definitions/systemData", "description": "The system data." } } }, "LinkerPatch": { "description": "A linker to be updated.", "type": "object", "properties": { "properties": { "description": "Linker properties", "type": "object", "x-ms-client-flatten": true, "$ref": "#/definitions/LinkerProperties" } } }, "LinkerList": { "description": "The list of Linker.", "type": "object", "properties": { "nextLink": { "description": "The link used to get the next page of Linker list.", "type": "string" }, "value": { "description": "The list of Linkers.", "type": "array", "items": { "$ref": "#/definitions/LinkerResource" } } } }, "LinkerProperties": { "description": "The properties of the linker.", "type": "object", "properties": { "targetId": { "description": "The resource Id of target service.", "type": "string" }, "authInfo": { "description": "The authentication type.", "$ref": "#/definitions/AuthInfoBase" }, "clientType": { "description": "The application client type", "type": "string", "enum": [ "none", "dotnet", "java", "python", "go", "php", "ruby", "django", "nodejs", "springBoot" ], "x-ms-enum": { "name": "clientType", "modelAsString": true } }, "provisioningState": { "readOnly": true, "type": "string", "description": "The provisioning state. " }, "vNetSolution": { "description": "The VNet solution.", "$ref": "#/definitions/VNetSolution" }, "secretStore": { "description": "An option to store secret value in secure place", "$ref": "#/definitions/SecretStore" } } }, "SourceConfiguration": { "description": "A configuration item for source resource", "type": "object", "properties": { "name": { "description": "The name of setting.", "type": "string" }, "value": { "description": "The value of setting", "type": "string" } } }, "SourceConfigurationResult": { "description": "Configurations for source resource, include appSettings, connectionString and serviceBindings", "type": "object", "properties": { "configurations": { "description": "The configuration properties for source resource.", "type": "array", "items": { "$ref": "#/definitions/SourceConfiguration" }, "x-ms-identifiers": [ "name" ] } } }, "ValidateResult": { "description": "The validation result for a linker.", "type": "object", "properties": { "name": { "description": "The linker name.", "type": "string" }, "linkerStatus": { "description": "Specifies if the linker is healthy.", "type": "string", "enum": [ "Healthy", "Not healthy" ], "x-ms-enum": { "name": "linkerStatus", "modelAsString": true } }, "reason": { "description": "The reason of the error.", "type": "string" }, "reportStartTimeUtc": { "type": "string", "format": "date-time", "description": "The start time of the validation report." }, "reportEndTimeUtc": { "type": "string", "format": "date-time", "description": "The end time of the validation report." }, "targetId": { "description": "The resource Id of target service.", "type": "string" }, "authType": { "description": "The authentication type.", "$ref": "#/definitions/AuthType" } } }, "VNetSolution": { "type": "object", "description": "The VNet solution for linker", "properties": { "type": { "description": "Type of VNet solution.", "type": "string", "enum": [ "serviceEndpoint", "privateLink" ], "x-ms-enum": { "name": "vNetSolutionType", "modelAsString": true } } } }, "SecretStore": { "type": "object", "description": "An option to store secret value in secure place", "properties": { "keyVaultId": { "type": "string", "description": "The key vault id to store secret" } } } }, "parameters": { "LinkerNameParameter": { "name": "linkerName", "in": "path", "required": true, "type": "string", "description": "The name Linker resource.", "x-ms-parameter-location": "method" }, "ResourceUriParameter": { "name": "resourceUri", "in": "path", "required": true, "type": "string", "description": "The fully qualified Azure Resource manager identifier of the resource to be connected.", "x-ms-skip-url-encoding": true, "x-ms-parameter-location": "method" } } }