ServiceOperations Class

Warning

DO NOT instantiate this class directly.

Instead, you should access the following operations through

CosmosDBManagementClient's

<xref:service> attribute.

Inheritance
builtins.object
ServiceOperations

Constructor

ServiceOperations(*args, **kwargs)

Methods

begin_create

Creates a service.

begin_delete

Deletes service with the given serviceName.

get

Gets the status of service.

list

Gets the status of service.

begin_create

Creates a service.

async begin_create(resource_group_name: str, account_name: str, service_name: str, create_update_parameters: _models.ServiceResourceCreateUpdateParameters, *, content_type: str = 'application/json', **kwargs: Any) -> AsyncLROPoller[_models.ServiceResource]

Parameters

Name Description
resource_group_name
Required
str

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

account_name
Required
str

Cosmos DB database account name. Required.

service_name
Required
str

Cosmos DB service name. Required.

create_update_parameters
Required

The Service resource parameters. Is either a ServiceResourceCreateUpdateParameters type or a IO[bytes] type. Required.

Returns

Type Description

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

Exceptions

Type Description

begin_delete

Deletes service with the given serviceName.

async begin_delete(resource_group_name: str, account_name: str, service_name: str, **kwargs: Any) -> AsyncLROPoller[None]

Parameters

Name Description
resource_group_name
Required
str

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

account_name
Required
str

Cosmos DB database account name. Required.

service_name
Required
str

Cosmos DB service name. Required.

Returns

Type Description

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

Exceptions

Type Description

get

Gets the status of service.

async get(resource_group_name: str, account_name: str, service_name: str, **kwargs: Any) -> ServiceResource

Parameters

Name Description
resource_group_name
Required
str

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

account_name
Required
str

Cosmos DB database account name. Required.

service_name
Required
str

Cosmos DB service name. Required.

Returns

Type Description

ServiceResource or the result of cls(response)

Exceptions

Type Description

list

Gets the status of service.

list(resource_group_name: str, account_name: str, **kwargs: Any) -> AsyncIterable[ServiceResource]

Parameters

Name Description
resource_group_name
Required
str

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

account_name
Required
str

Cosmos DB database account name. Required.

Returns

Type Description

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

Exceptions

Type Description

Attributes

models

models = <module 'azure.mgmt.cosmosdb.models' from 'C:\\hostedtoolcache\\windows\\Python\\3.11.9\\x64\\Lib\\site-packages\\azure\\mgmt\\cosmosdb\\models\\__init__.py'>