Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 11 additions & 19 deletions sdk/costmanagement/azure-mgmt-costmanagement/README.md
Original file line number Diff line number Diff line change
@@ -1,29 +1,21 @@
## Microsoft Azure SDK for Python
# Microsoft Azure SDK for Python

This is the Microsoft Azure Cost Management Client Library.
This package has been tested with Python 2.7, 3.5, 3.6, 3.7 and 3.8.
For a more complete view of Azure libraries, see the [Github repo](https://github.com/Azure/azure-sdk-for-python/)

Azure Resource Manager (ARM) is the next generation of management APIs
that replace the old Azure Service Management (ASM).

This package has been tested with Python 2.7, 3.4, 3.5, 3.6 and 3.7.
# Usage

For the older Azure Service Management (ASM) libraries, see
[azure-servicemanagement-legacy](https://pypi.python.org/pypi/azure-servicemanagement-legacy)
library.
For code examples, see [Cost Management](https://docs.microsoft.com/python/api/overview/azure/)
on docs.microsoft.com.

For a more complete set of Azure libraries, see the
[azure](https://pypi.python.org/pypi/azure) bundle package.

## Usage
# Provide Feedback

For code examples, see [Cost
Management](https://docs.microsoft.com/python/api/overview/azure/) on
docs.microsoft.com.

## Provide Feedback

If you encounter any bugs or have suggestions, please file an issue in
the [Issues](https://github.com/Azure/azure-sdk-for-python/issues)
If you encounter any bugs or have suggestions, please file an issue in the
[Issues](https://github.com/Azure/azure-sdk-for-python/issues)
section of the project.

![image](https://azure-sdk-impressions.azurewebsites.net/api/impressions/azure-sdk-for-python%2Fazure-mgmt-costmanagement%2FREADME.png)

![Impressions](https://azure-sdk-impressions.azurewebsites.net/api/impressions/azure-sdk-for-python%2Fazure-mgmt-costmanagement%2FREADME.png)
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@
from msrest import Serializer, Deserializer

from ._configuration import CostManagementClientConfiguration
from .operations import ViewsOperations
from .operations import AlertsOperations
from .operations import ForecastOperations
from .operations import DimensionsOperations
from .operations import QueryOperations
from .operations import ExportsOperations
Expand All @@ -26,6 +29,12 @@ class CostManagementClient(SDKClient):
:ivar config: Configuration for client.
:vartype config: CostManagementClientConfiguration

:ivar views: Views operations
:vartype views: azure.mgmt.costmanagement.operations.ViewsOperations
:ivar alerts: Alerts operations
:vartype alerts: azure.mgmt.costmanagement.operations.AlertsOperations
:ivar forecast: Forecast operations
:vartype forecast: azure.mgmt.costmanagement.operations.ForecastOperations
:ivar dimensions: Dimensions operations
:vartype dimensions: azure.mgmt.costmanagement.operations.DimensionsOperations
:ivar query: Query operations
Expand Down Expand Up @@ -54,6 +63,12 @@ def __init__(
self._serialize = Serializer(client_models)
self._deserialize = Deserializer(client_models)

self.views = ViewsOperations(
self._client, self.config, self._serialize, self._deserialize)
self.alerts = AlertsOperations(
self._client, self.config, self._serialize, self._deserialize)
self.forecast = ForecastOperations(
self._client, self.config, self._serialize, self._deserialize)
self.dimensions = DimensionsOperations(
self._client, self.config, self._serialize, self._deserialize)
self.query = QueryOperations(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@
# --------------------------------------------------------------------------

try:
from ._models_py3 import Alert
from ._models_py3 import AlertPropertiesDefinition
from ._models_py3 import AlertPropertiesDetails
from ._models_py3 import AlertsResult
from ._models_py3 import CommonExportProperties
from ._models_py3 import Dimension
from ._models_py3 import ErrorDetails
Expand All @@ -22,8 +26,12 @@
from ._models_py3 import ExportListResult
from ._models_py3 import ExportRecurrencePeriod
from ._models_py3 import ExportSchedule
from ._models_py3 import ForecastDefinition
from ._models_py3 import KpiProperties
from ._models_py3 import Operation
from ._models_py3 import OperationDisplay
from ._models_py3 import PivotProperties
from ._models_py3 import ProxyResource
from ._models_py3 import QueryAggregation
from ._models_py3 import QueryColumn
from ._models_py3 import QueryComparisonExpression
Expand All @@ -34,8 +42,21 @@
from ._models_py3 import QueryGrouping
from ._models_py3 import QueryResult
from ._models_py3 import QueryTimePeriod
from ._models_py3 import ReportConfigAggregation
from ._models_py3 import ReportConfigComparisonExpression
from ._models_py3 import ReportConfigDataset
from ._models_py3 import ReportConfigDatasetConfiguration
from ._models_py3 import ReportConfigFilter
from ._models_py3 import ReportConfigGrouping
from ._models_py3 import ReportConfigSorting
from ._models_py3 import ReportConfigTimePeriod
from ._models_py3 import Resource
from ._models_py3 import View
except (SyntaxError, ImportError):
from ._models import Alert
from ._models import AlertPropertiesDefinition
from ._models import AlertPropertiesDetails
from ._models import AlertsResult
from ._models import CommonExportProperties
from ._models import Dimension
from ._models import ErrorDetails
Expand All @@ -48,8 +69,12 @@
from ._models import ExportListResult
from ._models import ExportRecurrencePeriod
from ._models import ExportSchedule
from ._models import ForecastDefinition
from ._models import KpiProperties
from ._models import Operation
from ._models import OperationDisplay
from ._models import PivotProperties
from ._models import ProxyResource
from ._models import QueryAggregation
from ._models import QueryColumn
from ._models import QueryComparisonExpression
Expand All @@ -60,22 +85,48 @@
from ._models import QueryGrouping
from ._models import QueryResult
from ._models import QueryTimePeriod
from ._models import ReportConfigAggregation
from ._models import ReportConfigComparisonExpression
from ._models import ReportConfigDataset
from ._models import ReportConfigDatasetConfiguration
from ._models import ReportConfigFilter
from ._models import ReportConfigGrouping
from ._models import ReportConfigSorting
from ._models import ReportConfigTimePeriod
from ._models import Resource
from ._models import View
from ._paged_models import DimensionPaged
from ._paged_models import OperationPaged
from ._paged_models import ViewPaged
from ._cost_management_client_enums import (
ExportType,
TimeframeType,
ReportTimeframeType,
ReportGranularityType,
ReportConfigColumnType,
OperatorType,
ChartType,
AccumulatedType,
MetricType,
KpiTypeType,
PivotTypeType,
ForecastType,
ForecastTimeframeType,
GranularityType,
QueryColumnType,
ExportType,
TimeframeType,
StatusType,
RecurrenceType,
FormatType,
ExecutionType,
ExecutionStatus,
ExternalCloudProviderType,
)

__all__ = [
'Alert',
'AlertPropertiesDefinition',
'AlertPropertiesDetails',
'AlertsResult',
'CommonExportProperties',
'Dimension',
'ErrorDetails',
Expand All @@ -88,8 +139,12 @@
'ExportListResult',
'ExportRecurrencePeriod',
'ExportSchedule',
'ForecastDefinition',
'KpiProperties',
'Operation',
'OperationDisplay',
'PivotProperties',
'ProxyResource',
'QueryAggregation',
'QueryColumn',
'QueryComparisonExpression',
Expand All @@ -100,16 +155,38 @@
'QueryGrouping',
'QueryResult',
'QueryTimePeriod',
'ReportConfigAggregation',
'ReportConfigComparisonExpression',
'ReportConfigDataset',
'ReportConfigDatasetConfiguration',
'ReportConfigFilter',
'ReportConfigGrouping',
'ReportConfigSorting',
'ReportConfigTimePeriod',
'Resource',
'View',
'ViewPaged',
'DimensionPaged',
'OperationPaged',
'ExportType',
'TimeframeType',
'ReportTimeframeType',
'ReportGranularityType',
'ReportConfigColumnType',
'OperatorType',
'ChartType',
'AccumulatedType',
'MetricType',
'KpiTypeType',
'PivotTypeType',
'ForecastType',
'ForecastTimeframeType',
'GranularityType',
'QueryColumnType',
'ExportType',
'TimeframeType',
'StatusType',
'RecurrenceType',
'FormatType',
'ExecutionType',
'ExecutionStatus',
'ExternalCloudProviderType',
]
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,74 @@
from enum import Enum


class ExportType(str, Enum):
class ReportTimeframeType(str, Enum):

week_to_date = "WeekToDate"
month_to_date = "MonthToDate"
year_to_date = "YearToDate"
custom = "Custom"


class ReportGranularityType(str, Enum):

daily = "Daily"
monthly = "Monthly"


class ReportConfigColumnType(str, Enum):

tag = "Tag"
dimension = "Dimension"


class OperatorType(str, Enum):

in_enum = "In"
contains = "Contains"


class ChartType(str, Enum):

area = "Area"
line = "Line"
stacked_column = "StackedColumn"
grouped_column = "GroupedColumn"
table = "Table"


class AccumulatedType(str, Enum):

true = "true"
false = "false"


class MetricType(str, Enum):

actual_cost = "ActualCost"
amortized_cost = "AmortizedCost"
ahub = "AHUB"


class KpiTypeType(str, Enum):

forecast = "Forecast"
budget = "Budget"


class PivotTypeType(str, Enum):

dimension = "Dimension"
tag_key = "TagKey"


class ForecastType(str, Enum):

usage = "Usage"
actual_cost = "ActualCost"
amortized_cost = "AmortizedCost"


class TimeframeType(str, Enum):
class ForecastTimeframeType(str, Enum):

month_to_date = "MonthToDate"
billing_month_to_date = "BillingMonthToDate"
Expand All @@ -40,6 +100,23 @@ class QueryColumnType(str, Enum):
dimension = "Dimension"


class ExportType(str, Enum):

usage = "Usage"
actual_cost = "ActualCost"
amortized_cost = "AmortizedCost"


class TimeframeType(str, Enum):

month_to_date = "MonthToDate"
billing_month_to_date = "BillingMonthToDate"
the_last_month = "TheLastMonth"
the_last_billing_month = "TheLastBillingMonth"
week_to_date = "WeekToDate"
custom = "Custom"


class StatusType(str, Enum):

active = "Active"
Expand Down Expand Up @@ -74,3 +151,9 @@ class ExecutionStatus(str, Enum):
timeout = "Timeout"
new_data_not_available = "NewDataNotAvailable"
data_not_available = "DataNotAvailable"


class ExternalCloudProviderType(str, Enum):

external_subscriptions = "externalSubscriptions"
external_billing_accounts = "externalBillingAccounts"
Loading