AppServicePlansOperations Class

AppServicePlansOperations async operations.

You should not instantiate this class directly. Instead, you should create a Client instance that instantiates it for you and attaches it as an attribute.

Inheritance
builtins.object
AppServicePlansOperations

Constructor

AppServicePlansOperations(client, config, serializer, deserializer)

Parameters

client
Required

Client for service requests.

config
Required

Configuration of service client.

serializer
Required

An object model serializer.

deserializer
Required

An object model deserializer.

Variables

models

Alias to model classes used in this operation group.

Methods

begin_create_or_update

Creates or updates an App Service Plan.

Description for Creates or updates an App Service Plan.

create_or_update_vnet_route

Create or update a Virtual Network route in an App Service plan.

Description for Create or update a Virtual Network route in an App Service plan.

delete

Delete an App Service plan.

Description for Delete an App Service plan.

delete_hybrid_connection

Delete a Hybrid Connection in use in an App Service plan.

Description for Delete a Hybrid Connection in use in an App Service plan.

delete_vnet_route

Delete a Virtual Network route in an App Service plan.

Description for Delete a Virtual Network route in an App Service plan.

get

Get an App Service plan.

Description for Get an App Service plan.

get_hybrid_connection

Retrieve a Hybrid Connection in use in an App Service plan.

Description for Retrieve a Hybrid Connection in use in an App Service plan.

get_hybrid_connection_plan_limit

Get the maximum number of Hybrid Connections allowed in an App Service plan.

Description for Get the maximum number of Hybrid Connections allowed in an App Service plan.

get_route_for_vnet

Get a Virtual Network route in an App Service plan.

Description for Get a Virtual Network route in an App Service plan.

get_server_farm_skus

Gets all selectable SKUs for a given App Service Plan.

Description for Gets all selectable SKUs for a given App Service Plan.

get_vnet_from_server_farm

Get a Virtual Network associated with an App Service plan.

Description for Get a Virtual Network associated with an App Service plan.

get_vnet_gateway

Get a Virtual Network gateway.

Description for Get a Virtual Network gateway.

list

Get all App Service plans for a subscription.

Description for Get all App Service plans for a subscription.

list_by_resource_group

Get all App Service plans in a resource group.

Description for Get all App Service plans in a resource group.

list_capabilities

List all capabilities of an App Service plan.

Description for List all capabilities of an App Service plan.

list_hybrid_connection_keys

Get the send key name and value of a Hybrid Connection.

Description for Get the send key name and value of a Hybrid Connection.

list_hybrid_connections

Retrieve all Hybrid Connections in use in an App Service plan.

Description for Retrieve all Hybrid Connections in use in an App Service plan.

list_routes_for_vnet

Get all routes that are associated with a Virtual Network in an App Service plan.

Description for Get all routes that are associated with a Virtual Network in an App Service plan.

list_usages

Gets server farm usage information.

Description for Gets server farm usage information.

list_vnets

Get all Virtual Networks associated with an App Service plan.

Description for Get all Virtual Networks associated with an App Service plan.

list_web_apps

Get all apps associated with an App Service plan.

Description for Get all apps associated with an App Service plan.

list_web_apps_by_hybrid_connection

Get all apps that use a Hybrid Connection in an App Service Plan.

Description for Get all apps that use a Hybrid Connection in an App Service Plan.

reboot_worker

Reboot a worker machine in an App Service plan.

Description for Reboot a worker machine in an App Service plan.

restart_web_apps

Restart all apps in an App Service plan.

Description for Restart all apps in an App Service plan.

update

Creates or updates an App Service Plan.

Description for Creates or updates an App Service Plan.

update_vnet_gateway

Update a Virtual Network gateway.

Description for Update a Virtual Network gateway.

update_vnet_route

Create or update a Virtual Network route in an App Service plan.

Description for Create or update a Virtual Network route in an App Service plan.

begin_create_or_update

Creates or updates an App Service Plan.

Description for Creates or updates an App Service Plan.

async begin_create_or_update(resource_group_name: str, name: str, app_service_plan: azure.mgmt.web.v2021_01_15.models._models_py3.AppServicePlan, **kwargs: Any) -> azure.core.polling._async_poller.AsyncLROPoller[azure.mgmt.web.v2021_01_15.models._models_py3.AppServicePlan]

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of the App Service plan.

app_service_plan
AppServicePlan
Required

Details of the App Service plan.

cls
callable

A custom type or function that will be passed the direct response

continuation_token
str

A continuation token to restart a poller from a saved state.

polling
bool or AsyncPollingMethod

By default, your polling method will be AsyncARMPolling. Pass in False for this operation to not poll, or pass in your own initialized polling object for a personal polling strategy.

polling_interval
int

Default waiting time between two polls for LRO operations if no Retry-After header is present.

Returns

An instance of AsyncLROPoller that returns either AppServicePlan or the result of cls(response)

Return type

Exceptions

create_or_update_vnet_route

Create or update a Virtual Network route in an App Service plan.

Description for Create or update a Virtual Network route in an App Service plan.

async create_or_update_vnet_route(resource_group_name: str, name: str, vnet_name: str, route_name: str, route: azure.mgmt.web.v2021_01_15.models._models_py3.VnetRoute, **kwargs: Any) -> azure.mgmt.web.v2021_01_15.models._models_py3.VnetRoute

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of the App Service plan.

vnet_name
str
Required

Name of the Virtual Network.

route_name
str
Required

Name of the Virtual Network route.

route
VnetRoute
Required

Definition of the Virtual Network route.

cls
callable

A custom type or function that will be passed the direct response

Returns

VnetRoute, or the result of cls(response)

Return type

Exceptions

delete

Delete an App Service plan.

Description for Delete an App Service plan.

async delete(resource_group_name: str, name: str, **kwargs: Any) -> None

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of the App Service plan.

cls
callable

A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

Exceptions

delete_hybrid_connection

Delete a Hybrid Connection in use in an App Service plan.

Description for Delete a Hybrid Connection in use in an App Service plan.

async delete_hybrid_connection(resource_group_name: str, name: str, namespace_name: str, relay_name: str, **kwargs: Any) -> None

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of the App Service plan.

namespace_name
str
Required

Name of the Service Bus namespace.

relay_name
str
Required

Name of the Service Bus relay.

cls
callable

A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

Exceptions

delete_vnet_route

Delete a Virtual Network route in an App Service plan.

Description for Delete a Virtual Network route in an App Service plan.

async delete_vnet_route(resource_group_name: str, name: str, vnet_name: str, route_name: str, **kwargs: Any) -> None

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of the App Service plan.

vnet_name
str
Required

Name of the Virtual Network.

route_name
str
Required

Name of the Virtual Network route.

cls
callable

A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

Exceptions

get

Get an App Service plan.

Description for Get an App Service plan.

async get(resource_group_name: str, name: str, **kwargs: Any) -> azure.mgmt.web.v2021_01_15.models._models_py3.AppServicePlan

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of the App Service plan.

cls
callable

A custom type or function that will be passed the direct response

Returns

AppServicePlan, or the result of cls(response)

Return type

Exceptions

get_hybrid_connection

Retrieve a Hybrid Connection in use in an App Service plan.

Description for Retrieve a Hybrid Connection in use in an App Service plan.

async get_hybrid_connection(resource_group_name: str, name: str, namespace_name: str, relay_name: str, **kwargs: Any) -> azure.mgmt.web.v2021_01_15.models._models_py3.HybridConnection

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of the App Service plan.

namespace_name
str
Required

Name of the Service Bus namespace.

relay_name
str
Required

Name of the Service Bus relay.

cls
callable

A custom type or function that will be passed the direct response

Returns

HybridConnection, or the result of cls(response)

Return type

Exceptions

get_hybrid_connection_plan_limit

Get the maximum number of Hybrid Connections allowed in an App Service plan.

Description for Get the maximum number of Hybrid Connections allowed in an App Service plan.

async get_hybrid_connection_plan_limit(resource_group_name: str, name: str, **kwargs: Any) -> azure.mgmt.web.v2021_01_15.models._models_py3.HybridConnectionLimits

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of the App Service plan.

cls
callable

A custom type or function that will be passed the direct response

Returns

HybridConnectionLimits, or the result of cls(response)

Return type

Exceptions

get_route_for_vnet

Get a Virtual Network route in an App Service plan.

Description for Get a Virtual Network route in an App Service plan.

async get_route_for_vnet(resource_group_name: str, name: str, vnet_name: str, route_name: str, **kwargs: Any) -> List[azure.mgmt.web.v2021_01_15.models._models_py3.VnetRoute]

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of the App Service plan.

vnet_name
str
Required

Name of the Virtual Network.

route_name
str
Required

Name of the Virtual Network route.

cls
callable

A custom type or function that will be passed the direct response

Returns

list of VnetRoute, or the result of cls(response)

Return type

Exceptions

get_server_farm_skus

Gets all selectable SKUs for a given App Service Plan.

Description for Gets all selectable SKUs for a given App Service Plan.

async get_server_farm_skus(resource_group_name: str, name: str, **kwargs: Any) -> Any

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of App Service Plan.

cls
callable

A custom type or function that will be passed the direct response

Returns

any, or the result of cls(response)

Return type

any

Exceptions

get_vnet_from_server_farm

Get a Virtual Network associated with an App Service plan.

Description for Get a Virtual Network associated with an App Service plan.

async get_vnet_from_server_farm(resource_group_name: str, name: str, vnet_name: str, **kwargs: Any) -> azure.mgmt.web.v2021_01_15.models._models_py3.VnetInfo

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of the App Service plan.

vnet_name
str
Required

Name of the Virtual Network.

cls
callable

A custom type or function that will be passed the direct response

Returns

VnetInfo, or the result of cls(response)

Return type

Exceptions

get_vnet_gateway

Get a Virtual Network gateway.

Description for Get a Virtual Network gateway.

async get_vnet_gateway(resource_group_name: str, name: str, vnet_name: str, gateway_name: str, **kwargs: Any) -> azure.mgmt.web.v2021_01_15.models._models_py3.VnetGateway

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of the App Service plan.

vnet_name
str
Required

Name of the Virtual Network.

gateway_name
str
Required

Name of the gateway. Only the 'primary' gateway is supported.

cls
callable

A custom type or function that will be passed the direct response

Returns

VnetGateway, or the result of cls(response)

Return type

Exceptions

list

Get all App Service plans for a subscription.

Description for Get all App Service plans for a subscription.

list(detailed: Optional[bool] = None, **kwargs: Any) -> AsyncIterable[azure.mgmt.web.v2021_01_15.models._models_py3.AppServicePlanCollection]

Parameters

detailed
bool
default value: None

Specify <code>true</code> to return all App Service plan properties. The default is <code>false</code>, which returns a subset of the properties.

Retrieval of all properties may increase the API latency.

cls
callable

A custom type or function that will be passed the direct response

Returns

An iterator like instance of either AppServicePlanCollection or the result of cls(response)

Return type

Exceptions

list_by_resource_group

Get all App Service plans in a resource group.

Description for Get all App Service plans in a resource group.

list_by_resource_group(resource_group_name: str, **kwargs: Any) -> AsyncIterable[azure.mgmt.web.v2021_01_15.models._models_py3.AppServicePlanCollection]

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

cls
callable

A custom type or function that will be passed the direct response

Returns

An iterator like instance of either AppServicePlanCollection or the result of cls(response)

Return type

Exceptions

list_capabilities

List all capabilities of an App Service plan.

Description for List all capabilities of an App Service plan.

async list_capabilities(resource_group_name: str, name: str, **kwargs: Any) -> List[azure.mgmt.web.v2021_01_15.models._models_py3.Capability]

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of the App Service plan.

cls
callable

A custom type or function that will be passed the direct response

Returns

list of Capability, or the result of cls(response)

Return type

Exceptions

list_hybrid_connection_keys

Get the send key name and value of a Hybrid Connection.

Description for Get the send key name and value of a Hybrid Connection.

async list_hybrid_connection_keys(resource_group_name: str, name: str, namespace_name: str, relay_name: str, **kwargs: Any) -> azure.mgmt.web.v2021_01_15.models._models_py3.HybridConnectionKey

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of the App Service plan.

namespace_name
str
Required

The name of the Service Bus namespace.

relay_name
str
Required

The name of the Service Bus relay.

cls
callable

A custom type or function that will be passed the direct response

Returns

HybridConnectionKey, or the result of cls(response)

Return type

Exceptions

list_hybrid_connections

Retrieve all Hybrid Connections in use in an App Service plan.

Description for Retrieve all Hybrid Connections in use in an App Service plan.

list_hybrid_connections(resource_group_name: str, name: str, **kwargs: Any) -> AsyncIterable[azure.mgmt.web.v2021_01_15.models._models_py3.HybridConnectionCollection]

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of the App Service plan.

cls
callable

A custom type or function that will be passed the direct response

Returns

An iterator like instance of either HybridConnectionCollection or the result of cls(response)

Return type

Exceptions

list_routes_for_vnet

Get all routes that are associated with a Virtual Network in an App Service plan.

Description for Get all routes that are associated with a Virtual Network in an App Service plan.

async list_routes_for_vnet(resource_group_name: str, name: str, vnet_name: str, **kwargs: Any) -> List[azure.mgmt.web.v2021_01_15.models._models_py3.VnetRoute]

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of the App Service plan.

vnet_name
str
Required

Name of the Virtual Network.

cls
callable

A custom type or function that will be passed the direct response

Returns

list of VnetRoute, or the result of cls(response)

Return type

Exceptions

list_usages

Gets server farm usage information.

Description for Gets server farm usage information.

list_usages(resource_group_name: str, name: str, filter: Optional[str] = None, **kwargs: Any) -> AsyncIterable[azure.mgmt.web.v2021_01_15.models._models_py3.CsmUsageQuotaCollection]

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of App Service Plan.

filter
str
default value: None

Return only usages/metrics specified in the filter. Filter conforms to odata syntax. Example: $filter=(name.value eq 'Metric1' or name.value eq 'Metric2').

cls
callable

A custom type or function that will be passed the direct response

Returns

An iterator like instance of either CsmUsageQuotaCollection or the result of cls(response)

Return type

Exceptions

list_vnets

Get all Virtual Networks associated with an App Service plan.

Description for Get all Virtual Networks associated with an App Service plan.

async list_vnets(resource_group_name: str, name: str, **kwargs: Any) -> List[azure.mgmt.web.v2021_01_15.models._models_py3.VnetInfo]

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of the App Service plan.

cls
callable

A custom type or function that will be passed the direct response

Returns

list of VnetInfo, or the result of cls(response)

Return type

Exceptions

list_web_apps

Get all apps associated with an App Service plan.

Description for Get all apps associated with an App Service plan.

list_web_apps(resource_group_name: str, name: str, skip_token: Optional[str] = None, filter: Optional[str] = None, top: Optional[str] = None, **kwargs: Any) -> AsyncIterable[azure.mgmt.web.v2021_01_15.models._models_py3.WebAppCollection]

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of the App Service plan.

skip_token
str
default value: None

Skip to a web app in the list of webapps associated with app service plan. If specified, the resulting list will contain web apps starting from (including) the skipToken. Otherwise, the resulting list contains web apps from the start of the list.

filter
str
default value: None

Supported filter: $filter=state eq running. Returns only web apps that are currently running.

top
str
default value: None

List page size. If specified, results are paged.

cls
callable

A custom type or function that will be passed the direct response

Returns

An iterator like instance of either WebAppCollection or the result of cls(response)

Return type

Exceptions

list_web_apps_by_hybrid_connection

Get all apps that use a Hybrid Connection in an App Service Plan.

Description for Get all apps that use a Hybrid Connection in an App Service Plan.

list_web_apps_by_hybrid_connection(resource_group_name: str, name: str, namespace_name: str, relay_name: str, **kwargs: Any) -> AsyncIterable[azure.mgmt.web.v2021_01_15.models._models_py3.ResourceCollection]

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of the App Service plan.

namespace_name
str
Required

Name of the Hybrid Connection namespace.

relay_name
str
Required

Name of the Hybrid Connection relay.

cls
callable

A custom type or function that will be passed the direct response

Returns

An iterator like instance of either ResourceCollection or the result of cls(response)

Return type

Exceptions

reboot_worker

Reboot a worker machine in an App Service plan.

Description for Reboot a worker machine in an App Service plan.

async reboot_worker(resource_group_name: str, name: str, worker_name: str, **kwargs: Any) -> None

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of the App Service plan.

worker_name
str
Required

Name of worker machine, which typically starts with RD.

cls
callable

A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

Exceptions

restart_web_apps

Restart all apps in an App Service plan.

Description for Restart all apps in an App Service plan.

async restart_web_apps(resource_group_name: str, name: str, soft_restart: Optional[bool] = None, **kwargs: Any) -> None

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of the App Service plan.

soft_restart
bool
default value: None

Specify <code>true</code> to perform a soft restart, applies the configuration settings and restarts the apps if necessary. The default is <code>false</code>, which always restarts and reprovisions the apps.

cls
callable

A custom type or function that will be passed the direct response

Returns

None, or the result of cls(response)

Return type

Exceptions

update

Creates or updates an App Service Plan.

Description for Creates or updates an App Service Plan.

async update(resource_group_name: str, name: str, app_service_plan: azure.mgmt.web.v2021_01_15.models._models_py3.AppServicePlanPatchResource, **kwargs: Any) -> azure.mgmt.web.v2021_01_15.models._models_py3.AppServicePlan

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of the App Service plan.

app_service_plan
AppServicePlanPatchResource
Required

Details of the App Service plan.

cls
callable

A custom type or function that will be passed the direct response

Returns

AppServicePlan, or the result of cls(response)

Return type

Exceptions

update_vnet_gateway

Update a Virtual Network gateway.

Description for Update a Virtual Network gateway.

async update_vnet_gateway(resource_group_name: str, name: str, vnet_name: str, gateway_name: str, connection_envelope: azure.mgmt.web.v2021_01_15.models._models_py3.VnetGateway, **kwargs: Any) -> azure.mgmt.web.v2021_01_15.models._models_py3.VnetGateway

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of the App Service plan.

vnet_name
str
Required

Name of the Virtual Network.

gateway_name
str
Required

Name of the gateway. Only the 'primary' gateway is supported.

connection_envelope
VnetGateway
Required

Definition of the gateway.

cls
callable

A custom type or function that will be passed the direct response

Returns

VnetGateway, or the result of cls(response)

Return type

Exceptions

update_vnet_route

Create or update a Virtual Network route in an App Service plan.

Description for Create or update a Virtual Network route in an App Service plan.

async update_vnet_route(resource_group_name: str, name: str, vnet_name: str, route_name: str, route: azure.mgmt.web.v2021_01_15.models._models_py3.VnetRoute, **kwargs: Any) -> azure.mgmt.web.v2021_01_15.models._models_py3.VnetRoute

Parameters

resource_group_name
str
Required

Name of the resource group to which the resource belongs.

name
str
Required

Name of the App Service plan.

vnet_name
str
Required

Name of the Virtual Network.

route_name
str
Required

Name of the Virtual Network route.

route
VnetRoute
Required

Definition of the Virtual Network route.

cls
callable

A custom type or function that will be passed the direct response

Returns

VnetRoute, or the result of cls(response)

Return type

Exceptions

Attributes

models

models = <module 'azure.mgmt.web.v2021_01_15.models' from 'C:\\hostedtoolcache\\windows\\Python\\3.9.13\\x64\\lib\\site-packages\\azure\\mgmt\\web\\v2021_01_15\\models\\__init__.py'>