Package: azure-mgmt-reservations
Microsoft Azure SDK for PythonThis is the Microsoft Azure Reservations Client Library.
This package has been tested with Python 3.7+.
For a more complete view of Azure libraries, see theazure sdk python release.DisclaimerAzure SDK Python packages support for Python 2.7 has ended 01 January 2022. For more information and questions, please refer tohttps://github.com/Azure/azure-sdk-for-python/issues/20691Getting startedPrerequisitesPython 3.7+ is required to use this package.Azure subscriptionInstall the packagepipinstallazure-mgmt-reservations
pipinstallazure-identityAuthenticationBy default,Azure Active Directorytoken authentication depends on correct configure of following environment variables.AZURE_CLIENT_IDfor Azure client ID.AZURE_TENANT_IDfor Azure tenant ID.AZURE_CLIENT_SECRETfor Azure client secret.In addition, Azure subscription ID can be configured via environment variableAZURE_SUBSCRIPTION_ID.With above configuration, client can be authenticated by following code:fromazure.identityimportDefaultAzureCredentialfromazure.mgmt.reservationsimportAzureReservationAPIimportossub_id=os.getenv("AZURE_SUBSCRIPTION_ID")client=AzureReservationAPI(credential=DefaultAzureCredential(),subscription_id=sub_id)ExamplesCode samples for this package can be found atReservationson docs.microsoft.com andSamples RepoTroubleshootingNext stepsProvide FeedbackIf you encounter any bugs or have suggestions, please file an issue in theIssuessection of the project.Release History2.3.0 (2023-03-20)Features AddedModel CatalogMsrp has a new parameter p3_yModel CatalogMsrp has a new parameter p5_y2.2.0 (2023-02-15)Features AddedModel CalculateExchangeRequestProperties has a new parameter savings_plans_to_purchaseModel CalculateExchangeResponseProperties has a new parameter savings_plans_to_purchaseModel ExchangeResponseProperties has a new parameter savings_plans_to_purchaseModel Patch has a new parameter applied_scope_propertiesModel Patch has a new parameter review_date_timeModel PurchaseRequest has a new parameter applied_scope_propertiesModel PurchaseRequest has a new parameter review_date_timeModel ReservationOrderResponse has a new parameter expiry_date_timeModel ReservationOrderResponse has a new parameter review_date_timeModel ReservationSummary has a new parameter no_benefit_countModel ReservationSummary has a new parameter warning_countModel ReservationsProperties has a new parameter applied_scope_propertiesModel ReservationsProperties has a new parameter expiry_date_timeModel ReservationsProperties has a new parameter purchase_date_timeModel ReservationsProperties has a new parameter review_date_timeModel ReservationsProperties has a new parameter swap_propertiesOperation AzureReservationAPIOperationsMixin.get_catalog has a new optional parameter filterOperation AzureReservationAPIOperationsMixin.get_catalog has a new optional parameter skipOperation AzureReservationAPIOperationsMixin.get_catalog has a new optional parameter takeBreaking ChangesRenamed operation ReturnOperations.post to ReturnOperations.begin_post2.2.0b1 (2022-12-27)Features AddedModel ReservationsProperties has a new parameter applied_scope_propertiesModel ReservationsProperties has a new parameter swap_properties2.1.0 (2022-09-19)Features AddedAdded operation ReservationOperations.archiveAdded operation ReservationOperations.unarchiveAdded operation group CalculateRefundOperationsAdded operation group ReturnOperations2.0.0 (2022-04-20)FeaturesAdded operation ReservationOperations.list_allAdded operation ReservationOrderOperations.change_directoryModel CalculatePriceResponseProperties has a new parameter grand_totalModel CalculatePriceResponseProperties has a new parameter is_tax_includedModel CalculatePriceResponseProperties has a new parameter net_totalModel CalculatePriceResponseProperties has a new parameter tax_totalModel Catalog has a new parameter capabilitiesModel Catalog has a new parameter msrpModel Catalog has a new parameter sizeModel Catalog has a new parameter tierModel CurrentQuotaLimit has a new parameter idModel CurrentQuotaLimit has a new parameter nameModel CurrentQuotaLimit has a new parameter typeModel CurrentQuotaLimitBase has a new parameter idModel CurrentQuotaLimitBase has a new parameter nameModel CurrentQuotaLimitBase has a new parameter typeModel OperationResponse has a new parameter is_data_actionModel OperationResponse has a new parameter propertiesModel QuotaRequestOneResourceSubmitResponse has a new parameter id_properties_idModel QuotaRequestOneResourceSubmitResponse has a new parameter name_properties_nameModel QuotaRequestOneResourceSubmitResponse has a new parameter type_properties_typeModel ReservationOrderResponse has a new parameter benefit_start_timeModel ReservationOrderResponse has a new parameter system_dataModel ReservationResponse has a new parameter kindModel ReservationResponse has a new parameter system_dataBreaking changesOperation AzureReservationAPIOperationsMixin.get_catalog has a new parameter offer_idOperation AzureReservationAPIOperationsMixin.get_catalog has a new parameter plan_idOperation AzureReservationAPIOperationsMixin.get_catalog has a new parameter publisher_id1.0.0 (2021-05-20)FeaturesModel ReservationToPurchaseExchange has a new parameter reservation_idModel ReservationToPurchaseExchange has a new parameter propertiesModel ReservationToPurchaseCalculateExchange has a new parameter propertiesBreaking changesRemoved operation ReservationOrderOperations.change_directoryRemoved operation group AutoQuotaIncreaseOperations1.0.0b1 (2020-12-09)This is beta preview version.This version uses a next-generation code generator that introduces important breaking changes, but also important new features (like unified authentication and async programming).General breaking changesCredential system has been completly revamped:azure.common.credentialsormsrestazure.azure_active_directoryinstances are no longer supported, use theazure-identityclasses instead:https://pypi.org/project/azure-identity/credentialsparameter has been renamedcredentialTheconfigattribute no longer exists on a client, configuration should be passed as kwarg. Example:MyClient(credential, subscription_id, enable_logging=True). For a complete set of
supported options, see theparameters accept in init documentation of azure-coreYou can't import aversionmodule anymore, use__version__insteadOperations that used to return amsrest.polling.LROPollernow returns aazure.core.polling.LROPollerand are prefixed withbegin_.Exceptions tree have been simplified and most exceptions are nowazure.core.exceptions.HttpResponseError(CloudErrorhas been removed).Most of the operation kwarg have changed. Some of the most noticeable:rawhas been removed. Equivalent feature can be found usingcls, a callback that will give access to internal HTTP response for advanced userFor a complete set of
supported options, see theparameters accept in Request documentation of azure-coreGeneral new featuresType annotations support usingtyping. SDKs are mypy ready.This client has now stable and official support for async. Check theaionamespace of your package to find the async client.This client now support natively tracing library like OpenCensus or OpenTelemetry. See thistracing quickstartfor an overview.0.8.0 (2020-07-15)FeaturesAdded operation QuotaOperations.getAdded operation QuotaOperations.create_or_updateAdded operation QuotaOperations.listAdded operation QuotaOperations.updateAdded operation group QuotaRequestStatusOperationsAdded reservedResourceTypeBreaking changesModel SupportRequestAction no longer has parameter auto_quota_increase_stateModel QuotaRequestOneResourceSubmitResponse no longer has parameter resource_typeModel QuotaRequestOneResourceSubmitResponse no longer has parameter limitModel QuotaRequestOneResourceSubmitResponse no longer has parameter unitModel QuotaRequestOneResourceSubmitResponse no longer has parameter name1Model QuotaRequestOneResourceSubmitResponse no longer has parameter current_valueModel QuotaRequestOneResourceSubmitResponse no longer has parameter quota_periodModel EmailActions has a new signatureModel CurrentQuotaLimit has a new signatureModel CurrentQuotaLimitBase has a new signatureRemoved operation QuotaOperations.list_statusRemoved operation group QuotasOperationsRemoved operation group QuotaRequestOperationsRemoved operation group QuotaRequestsOperations0.7.0 (2020-01-29)FeaturesAdded operation group QuotaRequestsOperationsAdded operation group QuotaOperationsAdded operation group QuotaRequestOperationsAdded operation group AutoQuotaIncreaseOperationsAdded operation group QuotasOperations0.6.0 (2019-10-24)BugfixFixed Catalog model structure not matching actual APIBreaking changesRemoved CatalogBillingPlansItem that could be considered a breaking
change0.5.0 (2019-10-04)FeaturesModel ReservationProperties has a new parameter billing_planModel CalculatePriceResponseProperties has a new parameter
payment_scheduleModel ReservationOrderResponse has a new parameter plan_informationModel ReservationOrderResponse has a new parameter billing_planModel Catalog has a new parameter billing_plansModel PurchaseRequest has a new parameter billing_planBreaking changesOperation ReservationOrderOperations.get has a new signature0.4.0 (2019-09-09)FeaturesModel ReservationProperties has a new parameter termModel ReservationProperties has a new parameter renew_propertiesModel ReservationProperties has a new parameter renew_sourceModel ReservationProperties has a new parameter billing_scope_idModel ReservationProperties has a new parameter renewModel ReservationProperties has a new parameter renew_destinationModel Patch has a new parameter renew_propertiesModel Patch has a new parameter renewModel PurchaseRequest has a new parameter renewAdded operation ReservationOperations.available_scopesAdded operation group AzureReservationAPIOperationsMixinBreaking changesOperation ReservationOperations.get has a new signatureGeneral breaking changesThis version uses a next-generation code generator thatmightintroduce breaking changes if from some import. In summary, some modules
were incorrectly visible/importable and have been renamed. This fixed
several issues caused by usage of classes that were not supposed to be
used in the first place.AzureReservationAPI cannot be imported fromazure.mgmt.reservations.azure_reservation_apianymore (import
fromazure.mgmt.reservationsworks like before)AzureReservationAPIConfiguration import has been moved fromazure.mgmt.reservations.azure_reservation_apitoazure.mgmt.reservationsA modelMyClassfrom a "models" sub-module cannot be imported
anymore usingazure.mgmt.reservations.models.my_class(import
fromazure.mgmt.reservations.modelsworks like before)An operation classMyClassOperationsfrom anoperationssub-module cannot be imported anymore usingazure.mgmt.reservations.operations.my_class_operations(import
fromazure.mgmt.reservations.operationsworks like before)Last but not least, HTTP connection pooling is now enabled by default.
You should always use a client as a context manager, or call close(), or
use no more than one client per process.0.3.2 (2019-04-18)FeaturesAdded operation ReservationOrderOperations.purchaseAdded operation ReservationOrderOperations.calculate0.3.1 (2018-11-05)FeaturesAdd redhat support0.3.0 (2018-08-22)FeaturesModel Patch has a new parameter 'name'Enum ReservedResourceType has a new value 'cosmos_db'0.2.1 (2018-06-14)Provide enum definitions when applicable0.2.0 (2018-06-12)NotesChanged Update Reservation APIAdded optional InstanceFlexibility parameterSupport for InstanceFlexibilitySupport for ReservedResourceType (VirtualMachines, SqlDatabases,
SuseLinux)Upgrade to rest api version 2018-06-01Breaking changeUpdated Get Catalog APIAdded required parameter 'reserved_resource_type'Added optional parameter 'location'Updated Catalog modelRenamed property 'capabilities' to 'sku_properties'Removed properties 'size' and 'tier'Updated ReservationProperties modelRemoved property 'kind'0.1.0 (2017-11-03)Initial Release