forecasts
Creates, updates, deletes, gets or lists a forecasts
resource.
Overview
Name | forecasts |
Type | Resource |
Id | azure.cost_management.forecasts |
Fields
The following fields are returned by SELECT
queries:
SELECT
not supported for this resource, use SHOW METHODS
to view available operations for the resource.
Methods
The following methods are available for this resource:
Name | Accessible by | Required Params | Optional Params | Description |
---|---|---|---|---|
usage | exec | scope , type , timeframe , dataset | $filter | Lists the forecast charges for scope defined. |
external_cloud_provider_usage | exec | externalCloudProviderType , externalCloudProviderId , type , timeframe , dataset | $filter | Lists the forecast charges for external cloud provider type defined. |
Parameters
Parameters can be passed in the WHERE
clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
Name | Datatype | Description |
---|---|---|
externalCloudProviderId | string | This can be '{externalSubscriptionId}' for linked account or '{externalBillingAccountId}' for consolidated account used with dimension/query operations. |
externalCloudProviderType | string | The external cloud provider type associated with dimension/query operations. This includes 'externalSubscriptions' for linked account and 'externalBillingAccounts' for consolidated account. |
scope | string | The scope associated with forecast operations. This includes '/subscriptions/{subscriptionId}/' for subscription scope, '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' for resourceGroup scope, '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}' for Billing Account scope and '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/departments/{departmentId}' for Department scope, '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/enrollmentAccounts/{enrollmentAccountId}' for EnrollmentAccount scope, '/providers/Microsoft.Management/managementGroups/{managementGroupId} for Management Group scope, '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/billingProfiles/{billingProfileId}' for billingProfile scope, '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/billingProfiles/{billingProfileId}/invoiceSections/{invoiceSectionId}' for invoiceSection scope, and '/providers/Microsoft.Billing/billingAccounts/{billingAccountId}/customers/{customerId}' specific for partners. |
$filter | string | May be used to filter forecasts by properties/usageDate (Utc time), properties/chargeType or properties/grain. The filter supports 'eq', 'lt', 'gt', 'le', 'ge', and 'and'. It does not currently support 'ne', 'or', or 'not'. |
Lifecycle Methods
- usage
- external_cloud_provider_usage
Lists the forecast charges for scope defined.
EXEC azure.cost_management.forecasts.usage
@scope='{{ scope }}' --required,
@$filter='{{ $filter }}'
@@json=
'{
"type": "{{ type }}",
"timeframe": "{{ timeframe }}",
"timePeriod": "{{ timePeriod }}",
"dataset": "{{ dataset }}",
"includeActualCost": {{ includeActualCost }},
"includeFreshPartialCost": {{ includeFreshPartialCost }}
}'
;
Lists the forecast charges for external cloud provider type defined.
EXEC azure.cost_management.forecasts.external_cloud_provider_usage
@externalCloudProviderType='{{ externalCloudProviderType }}' --required,
@externalCloudProviderId='{{ externalCloudProviderId }}' --required,
@$filter='{{ $filter }}'
@@json=
'{
"type": "{{ type }}",
"timeframe": "{{ timeframe }}",
"timePeriod": "{{ timePeriod }}",
"dataset": "{{ dataset }}",
"includeActualCost": {{ includeActualCost }},
"includeFreshPartialCost": {{ includeFreshPartialCost }}
}'
;