azure.mgmt.subscription.operations module

class azure.mgmt.subscription.operations.AliasOperations(*args, **kwargs)[source]

Bases: object

Warning

DO NOT instantiate this class directly.

Instead, you should access the following operations through SubscriptionClient’s alias attribute.

begin_create(alias_name: str, body: _models.PutAliasRequest, *, content_type: str = "'application/json'", **kwargs: Any)LROPoller[_models.SubscriptionAliasResponse][source]
begin_create(alias_name: str, body: IO, *, content_type: str = "'application/json'", **kwargs: Any)LROPoller[_models.SubscriptionAliasResponse]

Create Alias Subscription.

Parameters
  • alias_name (str) – AliasName is the name for the subscription creation request. Note that this is not the same as subscription name and this doesn’t have any other lifecycle need beyond the request for subscription creation. Required.

  • body (PutAliasRequest or IO) – Is either a model type or a IO type. Required.

Keyword Arguments
  • content_type (str) – Body Parameter content-type. Known values are: ‘application/json’. Default value is None.

  • 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 PollingMethod) – By default, your polling method will be ARMPolling. 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 LROPoller that returns either SubscriptionAliasResponse or the result of cls(response)

Return type

LROPoller[SubscriptionAliasResponse]

Raises

HttpResponseError

delete(alias_name: str, **kwargs: Any)None[source]

Delete Alias.

Parameters

alias_name (str) – AliasName is the name for the subscription creation request. Note that this is not the same as subscription name and this doesn’t have any other lifecycle need beyond the request for subscription creation. Required.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

None or the result of cls(response)

Return type

None

Raises

HttpResponseError

get(alias_name: str, **kwargs: Any)azure.mgmt.subscription.models._models_py3.SubscriptionAliasResponse[source]

Get Alias Subscription.

Parameters

alias_name (str) – AliasName is the name for the subscription creation request. Note that this is not the same as subscription name and this doesn’t have any other lifecycle need beyond the request for subscription creation. Required.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

SubscriptionAliasResponse or the result of cls(response)

Return type

SubscriptionAliasResponse

Raises

HttpResponseError

list(**kwargs: Any)azure.mgmt.subscription.models._models_py3.SubscriptionAliasListResult[source]

List Alias Subscription.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

SubscriptionAliasListResult or the result of cls(response)

Return type

SubscriptionAliasListResult

Raises

HttpResponseError

models = <module 'azure.mgmt.subscription.models' from '/mnt/vss/_work/1/s/sdk/subscription/azure-mgmt-subscription/.tox/sphinx/lib/python3.9/site-packages/azure/mgmt/subscription/models/__init__.py'>
class azure.mgmt.subscription.operations.BillingAccountOperations(*args, **kwargs)[source]

Bases: object

Warning

DO NOT instantiate this class directly.

Instead, you should access the following operations through SubscriptionClient’s billing_account attribute.

get_policy(billing_account_id: str, **kwargs: Any)azure.mgmt.subscription.models._models_py3.BillingAccountPoliciesResponse[source]

Get Billing Account Policy.

Parameters

billing_account_id (str) – Billing Account Id. Required.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

BillingAccountPoliciesResponse or the result of cls(response)

Return type

BillingAccountPoliciesResponse

Raises

HttpResponseError

models = <module 'azure.mgmt.subscription.models' from '/mnt/vss/_work/1/s/sdk/subscription/azure-mgmt-subscription/.tox/sphinx/lib/python3.9/site-packages/azure/mgmt/subscription/models/__init__.py'>
class azure.mgmt.subscription.operations.Operations(*args, **kwargs)[source]

Bases: object

Warning

DO NOT instantiate this class directly.

Instead, you should access the following operations through SubscriptionClient’s operations attribute.

list(**kwargs: Any)Iterable[azure.mgmt.subscription.models._models_py3.Operation][source]

Lists all of the available Microsoft.Subscription API operations.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

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

Return type

ItemPaged[Operation]

Raises

HttpResponseError

models = <module 'azure.mgmt.subscription.models' from '/mnt/vss/_work/1/s/sdk/subscription/azure-mgmt-subscription/.tox/sphinx/lib/python3.9/site-packages/azure/mgmt/subscription/models/__init__.py'>
class azure.mgmt.subscription.operations.SubscriptionOperations(*args, **kwargs)[source]

Bases: object

Warning

DO NOT instantiate this class directly.

Instead, you should access the following operations through SubscriptionClient’s subscription attribute.

accept_ownership_status(subscription_id: str, **kwargs: Any)azure.mgmt.subscription.models._models_py3.AcceptOwnershipStatusResponse[source]

Accept subscription ownership status.

Parameters

subscription_id (str) – Subscription Id. Required.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

AcceptOwnershipStatusResponse or the result of cls(response)

Return type

AcceptOwnershipStatusResponse

Raises

HttpResponseError

begin_accept_ownership(subscription_id: str, body: _models.AcceptOwnershipRequest, *, content_type: str = "'application/json'", **kwargs: Any)LROPoller[None][source]
begin_accept_ownership(subscription_id: str, body: IO, *, content_type: str = "'application/json'", **kwargs: Any)LROPoller[None]

Accept subscription ownership.

Parameters
  • subscription_id (str) – Subscription Id. Required.

  • body (AcceptOwnershipRequest or IO) – Is either a model type or a IO type. Required.

Keyword Arguments
  • content_type (str) – Body Parameter content-type. Known values are: ‘application/json’. Default value is None.

  • 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 PollingMethod) – By default, your polling method will be ARMPolling. 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 LROPoller that returns either None or the result of cls(response)

Return type

LROPoller[None]

Raises

HttpResponseError

cancel(subscription_id: str, **kwargs: Any)azure.mgmt.subscription.models._models_py3.CanceledSubscriptionId[source]

The operation to cancel a subscription.

Parameters

subscription_id (str) – Subscription Id. Required.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

CanceledSubscriptionId or the result of cls(response)

Return type

CanceledSubscriptionId

Raises

HttpResponseError

enable(subscription_id: str, **kwargs: Any)azure.mgmt.subscription.models._models_py3.EnabledSubscriptionId[source]

The operation to enable a subscription.

Parameters

subscription_id (str) – Subscription Id. Required.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

EnabledSubscriptionId or the result of cls(response)

Return type

EnabledSubscriptionId

Raises

HttpResponseError

rename(subscription_id: str, body: _models.SubscriptionName, *, content_type: str = "'application/json'", **kwargs: Any)_models.RenamedSubscriptionId[source]
rename(subscription_id: str, body: IO, *, content_type: str = "'application/json'", **kwargs: Any)_models.RenamedSubscriptionId

The operation to rename a subscription.

Parameters
  • subscription_id (str) – Subscription Id. Required.

  • body (SubscriptionName or IO) – Subscription Name. Is either a model type or a IO type. Required.

Keyword Arguments
  • content_type (str) – Body Parameter content-type. Known values are: ‘application/json’. Default value is None.

  • cls (callable) – A custom type or function that will be passed the direct response

Returns

RenamedSubscriptionId or the result of cls(response)

Return type

RenamedSubscriptionId

Raises

HttpResponseError

models = <module 'azure.mgmt.subscription.models' from '/mnt/vss/_work/1/s/sdk/subscription/azure-mgmt-subscription/.tox/sphinx/lib/python3.9/site-packages/azure/mgmt/subscription/models/__init__.py'>
class azure.mgmt.subscription.operations.SubscriptionPolicyOperations(*args, **kwargs)[source]

Bases: object

Warning

DO NOT instantiate this class directly.

Instead, you should access the following operations through SubscriptionClient’s subscription_policy attribute.

add_update_policy_for_tenant(body: _models.PutTenantPolicyRequestProperties, *, content_type: str = "'application/json'", **kwargs: Any)_models.GetTenantPolicyResponse[source]
add_update_policy_for_tenant(body: IO, *, content_type: str = "'application/json'", **kwargs: Any)_models.GetTenantPolicyResponse

Create or Update Subscription tenant policy for user’s tenant.

Parameters

body (PutTenantPolicyRequestProperties or IO) – Is either a model type or a IO type. Required.

Keyword Arguments
  • content_type (str) – Body Parameter content-type. Known values are: ‘application/json’. Default value is None.

  • cls (callable) – A custom type or function that will be passed the direct response

Returns

GetTenantPolicyResponse or the result of cls(response)

Return type

GetTenantPolicyResponse

Raises

HttpResponseError

get_policy_for_tenant(**kwargs: Any)azure.mgmt.subscription.models._models_py3.GetTenantPolicyResponse[source]

Get the subscription tenant policy for the user’s tenant.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

GetTenantPolicyResponse or the result of cls(response)

Return type

GetTenantPolicyResponse

Raises

HttpResponseError

list_policy_for_tenant(**kwargs: Any)Iterable[azure.mgmt.subscription.models._models_py3.GetTenantPolicyResponse][source]

Get the subscription tenant policy for the user’s tenant.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

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

Return type

ItemPaged[GetTenantPolicyResponse]

Raises

HttpResponseError

models = <module 'azure.mgmt.subscription.models' from '/mnt/vss/_work/1/s/sdk/subscription/azure-mgmt-subscription/.tox/sphinx/lib/python3.9/site-packages/azure/mgmt/subscription/models/__init__.py'>
class azure.mgmt.subscription.operations.SubscriptionsOperations(*args, **kwargs)[source]

Bases: object

Warning

DO NOT instantiate this class directly.

Instead, you should access the following operations through SubscriptionClient’s subscriptions attribute.

get(subscription_id: str, **kwargs: Any)azure.mgmt.subscription.models._models_py3.Subscription[source]

Gets details about a specified subscription.

Parameters

subscription_id (str) – The ID of the target subscription. Required.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

Subscription or the result of cls(response)

Return type

Subscription

Raises

HttpResponseError

list(**kwargs: Any)Iterable[azure.mgmt.subscription.models._models_py3.Subscription][source]

Gets all subscriptions for a tenant.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

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

Return type

ItemPaged[Subscription]

Raises

HttpResponseError

list_locations(subscription_id: str, **kwargs: Any)Iterable[azure.mgmt.subscription.models._models_py3.Location][source]

Gets all available geo-locations.

This operation provides all the locations that are available for resource providers; however, each resource provider may support a subset of this list.

Parameters

subscription_id (str) – The ID of the target subscription. Required.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

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

Return type

ItemPaged[Location]

Raises

HttpResponseError

models = <module 'azure.mgmt.subscription.models' from '/mnt/vss/_work/1/s/sdk/subscription/azure-mgmt-subscription/.tox/sphinx/lib/python3.9/site-packages/azure/mgmt/subscription/models/__init__.py'>
class azure.mgmt.subscription.operations.TenantsOperations(*args, **kwargs)[source]

Bases: object

Warning

DO NOT instantiate this class directly.

Instead, you should access the following operations through SubscriptionClient’s tenants attribute.

list(**kwargs: Any)Iterable[azure.mgmt.subscription.models._models_py3.TenantIdDescription][source]

Gets the tenants for your account.

Keyword Arguments

cls (callable) – A custom type or function that will be passed the direct response

Returns

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

Return type

ItemPaged[TenantIdDescription]

Raises

HttpResponseError

models = <module 'azure.mgmt.subscription.models' from '/mnt/vss/_work/1/s/sdk/subscription/azure-mgmt-subscription/.tox/sphinx/lib/python3.9/site-packages/azure/mgmt/subscription/models/__init__.py'>