Share via


Web Apps - Update Vnet Connection

Description for Adds a Virtual Network connection to an app or slot (PUT) or updates the connection properties (PATCH).

PATCH https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/virtualNetworkConnections/{vnetName}?api-version=2025-05-01

URI Parameters

Name In Required Type Description
name
path True

string

Name of the app.

resourceGroupName
path True

string

minLength: 1
maxLength: 90

The name of the resource group. The name is case insensitive.

subscriptionId
path True

string (uuid)

The ID of the target subscription. The value must be an UUID.

vnetName
path True

string

Name of the virtual network.

api-version
query True

string

minLength: 1

The API version to use for this operation.

Request Body

Name Type Description
kind

string

Kind of resource.

properties.certBlob

string

A certificate file (.cer) blob containing the public key of the private key used to authenticate a \nPoint-To-Site VPN connection.

properties.dnsServers

string

DNS servers to be used by this Virtual Network. This should be a comma-separated list of IP addresses.

properties.isSwift

boolean

Flag that is used to denote if this is VNET injection

properties.vnetResourceId

string

The Virtual Network's resource ID.

Responses

Name Type Description
200 OK

VnetInfoResource

Azure operation completed successfully.

Other Status Codes

DefaultErrorResponse

An unexpected error response.

Security

azure_auth

Azure Active Directory OAuth2 Flow.

Type: oauth2
Flow: implicit
Authorization URL: https://login.microsoftonline.com/common/oauth2/authorize

Scopes

Name Description
user_impersonation impersonate your user account

Definitions

Name Description
createdByType

The type of identity that created the resource.

DefaultErrorResponse

App Service error response.

DefaultErrorResponseError

Error model.

DefaultErrorResponseErrorDetailsItem

Detailed errors.

RouteType

The type of route this is: DEFAULT - By default, every app has routes to the local address ranges specified by RFC1918 INHERITED - Routes inherited from the real Virtual Network routes STATIC - Static route set on the app only

These values will be used for syncing an app's routes with those from a Virtual Network.

systemData

Metadata pertaining to creation and last modification of the resource.

VnetInfoResource

Virtual Network information ARM resource.

VnetRoute

Virtual Network route contract used to pass routing information for a Virtual Network.

createdByType

The type of identity that created the resource.

Value Description
User
Application
ManagedIdentity
Key

DefaultErrorResponse

App Service error response.

Name Type Description
error

DefaultErrorResponseError

Error model.

DefaultErrorResponseError

Error model.

Name Type Description
code

string

Standardized string to programmatically identify the error.

details

DefaultErrorResponseErrorDetailsItem[]

Detailed errors.

innererror

string

More information to debug error.

message

string

Detailed error description and debugging information.

target

string

Detailed error description and debugging information.

DefaultErrorResponseErrorDetailsItem

Detailed errors.

Name Type Description
code

string

Standardized string to programmatically identify the error.

message

string

Detailed error description and debugging information.

target

string

Detailed error description and debugging information.

RouteType

The type of route this is: DEFAULT - By default, every app has routes to the local address ranges specified by RFC1918 INHERITED - Routes inherited from the real Virtual Network routes STATIC - Static route set on the app only

These values will be used for syncing an app's routes with those from a Virtual Network.

Value Description
DEFAULT
INHERITED
STATIC

systemData

Metadata pertaining to creation and last modification of the resource.

Name Type Description
createdAt

string (date-time)

The timestamp of resource creation (UTC).

createdBy

string

The identity that created the resource.

createdByType

createdByType

The type of identity that created the resource.

lastModifiedAt

string (date-time)

The timestamp of resource last modification (UTC)

lastModifiedBy

string

The identity that last modified the resource.

lastModifiedByType

createdByType

The type of identity that last modified the resource.

VnetInfoResource

Virtual Network information ARM resource.

Name Type Description
id

string (arm-id)

Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}"

kind

string

Kind of resource.

name

string

The name of the resource

properties.certBlob

string

A certificate file (.cer) blob containing the public key of the private key used to authenticate a \nPoint-To-Site VPN connection.

properties.certThumbprint

string

The client certificate thumbprint.

properties.dnsServers

string

DNS servers to be used by this Virtual Network. This should be a comma-separated list of IP addresses.

properties.isSwift

boolean

Flag that is used to denote if this is VNET injection

properties.resyncRequired

boolean

true if a resync is required; otherwise, false.

properties.routes

VnetRoute[]

The routes that this Virtual Network connection uses.

properties.vnetResourceId

string

The Virtual Network's resource ID.

systemData

systemData

Azure Resource Manager metadata containing createdBy and modifiedBy information.

type

string

The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"

VnetRoute

Virtual Network route contract used to pass routing information for a Virtual Network.

Name Type Description
id

string (arm-id)

Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}"

kind

string

Kind of resource.

name

string

The name of the resource

properties.endAddress

string

The ending address for this route. If the start address is specified in CIDR notation, this must be omitted.

properties.routeType

RouteType

The type of route this is: DEFAULT - By default, every app has routes to the local address ranges specified by RFC1918 INHERITED - Routes inherited from the real Virtual Network routes STATIC - Static route set on the app only

These values will be used for syncing an app's routes with those from a Virtual Network.

properties.startAddress

string

The starting address for this route. This may also include a CIDR notation, in which case the end address must not be specified.

systemData

systemData

Azure Resource Manager metadata containing createdBy and modifiedBy information.

type

string

The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"