From c5744a78956f5b69bf87d248ea3b6d32ee39f773 Mon Sep 17 00:00:00 2001 From: Sebastian Heid <8442432+s4heid@users.noreply.github.com> Date: Mon, 14 Oct 2024 17:29:36 +0000 Subject: [PATCH 1/5] Update costmanagement API to 2023-08-01 This change updates the costmanagement API to version 2023-08-01, ensuring compatibility with both the public Azure Cloud and AzureChinaCloud. It's important to note that AzureChinaCloud has specific API version requirements, and version 2023-08-01 meets these. In addition, the `azurerm_cost_anomaly_alert` resource now includes a new optional parameter, `email_address_sender`, introduced in this API version. Should this parameter be omitted, the the TF provider will default to using the first email address listed in `email_addresses`, aligning with the default behavior observed in the Azure Portal. The ScheduledActionsClient_v2022_10_01, which previously existed alongside the ScheduledActionsClient, has been discontinued. This is because the API version 2023-08-01 seems to be compatible with all uses. --- .../costmanagement/anomaly_alert_resource.go | 38 +++++++++++++++---- .../anomaly_alert_resource_test.go | 30 ++++++++++++++- .../services/costmanagement/client/client.go | 27 +++++-------- .../export_billing_account_resource_test.go | 2 +- .../costmanagement/export_resource_base.go | 2 +- .../export_resource_group_resource_test.go | 2 +- .../export_subscription_resource_test.go | 2 +- .../scheduled_action_resource.go | 12 +++--- .../scheduled_action_resource_test.go | 4 +- .../costmanagement/view_resource_base.go | 2 +- .../view_resource_group_resource_test.go | 2 +- .../view_subscription_resource_test.go | 2 +- 12 files changed, 84 insertions(+), 41 deletions(-) diff --git a/internal/services/costmanagement/anomaly_alert_resource.go b/internal/services/costmanagement/anomaly_alert_resource.go index 3fb65b2e76b8..90513150b0ab 100644 --- a/internal/services/costmanagement/anomaly_alert_resource.go +++ b/internal/services/costmanagement/anomaly_alert_resource.go @@ -11,8 +11,8 @@ import ( "github.com/hashicorp/go-azure-helpers/lang/pointer" "github.com/hashicorp/go-azure-helpers/lang/response" "github.com/hashicorp/go-azure-helpers/resourcemanager/commonids" - "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions" - "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views" + "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions" + "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views" "github.com/hashicorp/terraform-provider-azurerm/internal/sdk" "github.com/hashicorp/terraform-provider-azurerm/internal/services/costmanagement/validate" "github.com/hashicorp/terraform-provider-azurerm/internal/tf/pluginsdk" @@ -48,6 +48,13 @@ func (AnomalyAlertResource) Arguments() map[string]*pluginsdk.Schema { ValidateFunc: commonids.ValidateSubscriptionID, }, + "email_address_sender": { + Type: pluginsdk.TypeString, + Optional: true, + Computed: true, + ValidateFunc: validation.StringIsNotEmpty, + }, + "email_subject": { Type: pluginsdk.TypeString, Required: true, @@ -117,6 +124,13 @@ func (r AnomalyAlertResource) Create() sdk.ResourceFunc { schedule.SetEndDateAsTime(time.Now().AddDate(1, 0, 0)) schedule.SetStartDateAsTime(time.Now()) + var senderEmail string + if v, ok := metadata.ResourceData.GetOk("email_address_sender"); ok { + senderEmail = v.(string) + } else { + senderEmail = (*emailAddresses)[0] + } + param := scheduledactions.ScheduledAction{ Kind: pointer.To(scheduledactions.ScheduledActionKindInsightAlert), Properties: &scheduledactions.ScheduledActionProperties{ @@ -126,6 +140,7 @@ func (r AnomalyAlertResource) Create() sdk.ResourceFunc { FileDestination: &scheduledactions.FileDestination{ FileFormats: &[]scheduledactions.FileFormat{}, }, + NotificationEmail: &senderEmail, Notification: scheduledactions.NotificationProperties{ Subject: metadata.ResourceData.Get("email_subject").(string), Message: utils.String(metadata.ResourceData.Get("message").(string)), @@ -134,7 +149,7 @@ func (r AnomalyAlertResource) Create() sdk.ResourceFunc { Schedule: schedule, }, } - if _, err := client.CreateOrUpdateByScope(ctx, id, param); err != nil { + if _, err := client.CreateOrUpdateByScope(ctx, id, param, scheduledactions.CreateOrUpdateByScopeOperationOptions{}); err != nil { return fmt.Errorf("creating %s: %+v", id, err) } @@ -183,13 +198,21 @@ func (r AnomalyAlertResource) Update() sdk.ResourceFunc { schedule.SetEndDateAsTime(time.Now().AddDate(1, 0, 0)) schedule.SetStartDateAsTime(time.Now()) + var senderEmail string + if v, ok := metadata.ResourceData.GetOk("email_address_sender"); ok { + senderEmail = v.(string) + } else { + senderEmail = (*emailAddresses)[0] + } + param := scheduledactions.ScheduledAction{ Kind: pointer.To(scheduledactions.ScheduledActionKindInsightAlert), ETag: resp.Model.ETag, Properties: &scheduledactions.ScheduledActionProperties{ - DisplayName: metadata.ResourceData.Get("display_name").(string), - Status: scheduledactions.ScheduledActionStatusEnabled, - ViewId: viewId.ID(), + DisplayName: metadata.ResourceData.Get("display_name").(string), + Status: scheduledactions.ScheduledActionStatusEnabled, + ViewId: viewId.ID(), + NotificationEmail: &senderEmail, Notification: scheduledactions.NotificationProperties{ Subject: metadata.ResourceData.Get("email_subject").(string), Message: utils.String(metadata.ResourceData.Get("message").(string)), @@ -198,7 +221,7 @@ func (r AnomalyAlertResource) Update() sdk.ResourceFunc { Schedule: schedule, }, } - if _, err := client.CreateOrUpdateByScope(ctx, *id, param); err != nil { + if _, err := client.CreateOrUpdateByScope(ctx, *id, param, scheduledactions.CreateOrUpdateByScopeOperationOptions{}); err != nil { return fmt.Errorf("creating %s: %+v", id, err) } @@ -234,6 +257,7 @@ func (AnomalyAlertResource) Read() sdk.ResourceFunc { metadata.ResourceData.Set("display_name", props.DisplayName) metadata.ResourceData.Set("subscription_id", fmt.Sprint("/", *props.Scope)) metadata.ResourceData.Set("email_subject", props.Notification.Subject) + metadata.ResourceData.Set("email_address_sender", props.NotificationEmail) metadata.ResourceData.Set("email_addresses", props.Notification.To) metadata.ResourceData.Set("message", props.Notification.Message) } diff --git a/internal/services/costmanagement/anomaly_alert_resource_test.go b/internal/services/costmanagement/anomaly_alert_resource_test.go index a33a92db6153..974ed96ba32a 100644 --- a/internal/services/costmanagement/anomaly_alert_resource_test.go +++ b/internal/services/costmanagement/anomaly_alert_resource_test.go @@ -8,7 +8,7 @@ import ( "fmt" "testing" - "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions" + "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions" "github.com/hashicorp/terraform-provider-azurerm/internal/acceptance" "github.com/hashicorp/terraform-provider-azurerm/internal/clients" "github.com/hashicorp/terraform-provider-azurerm/internal/tf/pluginsdk" @@ -50,6 +50,17 @@ func TestAccResourceAnomalyAlert_requiresImport(t *testing.T) { }) } +func TestAccResourceAnomalyAlert_emailAddressSender(t *testing.T) { + data := acceptance.BuildTestData(t, "azurerm_cost_anomaly_alert", "test") + testResource := AnomalyAlertResource{} + data.ResourceTest(t, testResource, []acceptance.TestStep{ + data.ApplyStep(testResource.emailAddressSenderConfig, testResource), + data.ImportStep(), + data.ApplyStep(testResource.updateConfig, testResource), + data.ImportStep(), + }) +} + func (AnomalyAlertResource) Exists(ctx context.Context, client *clients.Client, state *pluginsdk.InstanceState) (*bool, error) { id, err := scheduledactions.ParseScopedScheduledActionID(state.ID) if err != nil { @@ -129,3 +140,20 @@ resource "azurerm_cost_anomaly_alert" "test" { } `, data.RandomInteger, data.RandomInteger) } + +func (AnomalyAlertResource) emailAddressSenderConfig(data acceptance.TestData) string { + return fmt.Sprintf(` +provider "azurerm" { + features {} +} + +resource "azurerm_cost_anomaly_alert" "test" { + name = "-acctest-%d" + display_name = "acctest %d" + email_subject = "Hi" + email_addresses = ["test@test.com", "test@hashicorp.developer"] + email_address_sender = "othertest@hashicorp.developer" + message = "Custom sender email configured" +} +`, data.RandomInteger, data.RandomInteger) +} diff --git a/internal/services/costmanagement/client/client.go b/internal/services/costmanagement/client/client.go index bc38632c4a24..ef06e10770f7 100644 --- a/internal/services/costmanagement/client/client.go +++ b/internal/services/costmanagement/client/client.go @@ -6,18 +6,16 @@ package client import ( "fmt" - "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports" - "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions" - scheduledactions_v2022_10_01 "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions" - "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views" + "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports" + "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions" + "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views" "github.com/hashicorp/terraform-provider-azurerm/internal/common" ) type Client struct { - ExportClient *exports.ExportsClient - ScheduledActionsClient *scheduledactions.ScheduledActionsClient - ScheduledActionsClient_v2022_10_01 *scheduledactions_v2022_10_01.ScheduledActionsClient - ViewsClient *views.ViewsClient + ExportClient *exports.ExportsClient + ScheduledActionsClient *scheduledactions.ScheduledActionsClient + ViewsClient *views.ViewsClient } func NewClient(o *common.ClientOptions) (*Client, error) { @@ -33,12 +31,6 @@ func NewClient(o *common.ClientOptions) (*Client, error) { } o.Configure(scheduledActionsClient.Client, o.Authorizers.ResourceManager) - scheduledActionsClient_v2022_10_01, err := scheduledactions_v2022_10_01.NewScheduledActionsClientWithBaseURI(o.Environment.ResourceManager) - if err != nil { - return nil, fmt.Errorf("building ScheduledActions client: %+v", err) - } - o.Configure(scheduledActionsClient_v2022_10_01.Client, o.Authorizers.ResourceManager) - viewsClient, err := views.NewViewsClientWithBaseURI(o.Environment.ResourceManager) if err != nil { return nil, fmt.Errorf("building Views client: %+v", err) @@ -46,9 +38,8 @@ func NewClient(o *common.ClientOptions) (*Client, error) { o.Configure(viewsClient.Client, o.Authorizers.ResourceManager) return &Client{ - ExportClient: exportClient, - ScheduledActionsClient: scheduledActionsClient, - ScheduledActionsClient_v2022_10_01: scheduledActionsClient_v2022_10_01, - ViewsClient: viewsClient, + ExportClient: exportClient, + ScheduledActionsClient: scheduledActionsClient, + ViewsClient: viewsClient, }, nil } diff --git a/internal/services/costmanagement/export_billing_account_resource_test.go b/internal/services/costmanagement/export_billing_account_resource_test.go index c52efd369772..fb011bc0b6c3 100644 --- a/internal/services/costmanagement/export_billing_account_resource_test.go +++ b/internal/services/costmanagement/export_billing_account_resource_test.go @@ -10,7 +10,7 @@ import ( "testing" "time" - "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports" + "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports" "github.com/hashicorp/terraform-provider-azurerm/internal/acceptance" "github.com/hashicorp/terraform-provider-azurerm/internal/acceptance/check" "github.com/hashicorp/terraform-provider-azurerm/internal/clients" diff --git a/internal/services/costmanagement/export_resource_base.go b/internal/services/costmanagement/export_resource_base.go index 577625cd4381..c948a81f2bda 100644 --- a/internal/services/costmanagement/export_resource_base.go +++ b/internal/services/costmanagement/export_resource_base.go @@ -11,7 +11,7 @@ import ( "github.com/hashicorp/go-azure-helpers/lang/pointer" "github.com/hashicorp/go-azure-helpers/lang/response" "github.com/hashicorp/go-azure-helpers/resourcemanager/commonids" - "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports" + "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports" "github.com/hashicorp/terraform-provider-azurerm/helpers/tf" "github.com/hashicorp/terraform-provider-azurerm/internal/sdk" "github.com/hashicorp/terraform-provider-azurerm/internal/tf/pluginsdk" diff --git a/internal/services/costmanagement/export_resource_group_resource_test.go b/internal/services/costmanagement/export_resource_group_resource_test.go index b279cc278990..68327141106b 100644 --- a/internal/services/costmanagement/export_resource_group_resource_test.go +++ b/internal/services/costmanagement/export_resource_group_resource_test.go @@ -9,7 +9,7 @@ import ( "testing" "time" - "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports" + "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports" "github.com/hashicorp/terraform-provider-azurerm/internal/acceptance" "github.com/hashicorp/terraform-provider-azurerm/internal/acceptance/check" "github.com/hashicorp/terraform-provider-azurerm/internal/clients" diff --git a/internal/services/costmanagement/export_subscription_resource_test.go b/internal/services/costmanagement/export_subscription_resource_test.go index 8d467100f38a..f992e069ff32 100644 --- a/internal/services/costmanagement/export_subscription_resource_test.go +++ b/internal/services/costmanagement/export_subscription_resource_test.go @@ -9,7 +9,7 @@ import ( "testing" "time" - "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports" + "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports" "github.com/hashicorp/terraform-provider-azurerm/internal/acceptance" "github.com/hashicorp/terraform-provider-azurerm/internal/acceptance/check" "github.com/hashicorp/terraform-provider-azurerm/internal/clients" diff --git a/internal/services/costmanagement/scheduled_action_resource.go b/internal/services/costmanagement/scheduled_action_resource.go index 9c66404c9491..bd09e2a92b5a 100644 --- a/internal/services/costmanagement/scheduled_action_resource.go +++ b/internal/services/costmanagement/scheduled_action_resource.go @@ -10,8 +10,8 @@ import ( "github.com/hashicorp/go-azure-helpers/lang/pointer" "github.com/hashicorp/go-azure-helpers/lang/response" - "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions" - "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views" + "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions" + "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views" "github.com/hashicorp/terraform-provider-azurerm/helpers/tf" "github.com/hashicorp/terraform-provider-azurerm/internal/sdk" "github.com/hashicorp/terraform-provider-azurerm/internal/tf/pluginsdk" @@ -146,7 +146,7 @@ func (r CostManagementScheduledActionResource) Create() sdk.ResourceFunc { return sdk.ResourceFunc{ Timeout: 30 * time.Minute, Func: func(ctx context.Context, metadata sdk.ResourceMetaData) error { - client := metadata.Client.CostManagement.ScheduledActionsClient_v2022_10_01 + client := metadata.Client.CostManagement.ScheduledActionsClient viewId, err := views.ParseScopedViewID(metadata.ResourceData.Get("view_id").(string)) if err != nil { @@ -223,7 +223,7 @@ func (r CostManagementScheduledActionResource) Read() sdk.ResourceFunc { return sdk.ResourceFunc{ Timeout: 5 * time.Minute, Func: func(ctx context.Context, metadata sdk.ResourceMetaData) error { - client := metadata.Client.CostManagement.ScheduledActionsClient_v2022_10_01 + client := metadata.Client.CostManagement.ScheduledActionsClient id, err := scheduledactions.ParseScopedScheduledActionID(metadata.ResourceData.Id()) if err != nil { @@ -273,7 +273,7 @@ func (r CostManagementScheduledActionResource) Delete() sdk.ResourceFunc { return sdk.ResourceFunc{ Timeout: 30 * time.Minute, Func: func(ctx context.Context, metadata sdk.ResourceMetaData) error { - client := metadata.Client.CostManagement.ScheduledActionsClient_v2022_10_01 + client := metadata.Client.CostManagement.ScheduledActionsClient id, err := scheduledactions.ParseScopedScheduledActionID(metadata.ResourceData.Id()) if err != nil { @@ -293,7 +293,7 @@ func (r CostManagementScheduledActionResource) Update() sdk.ResourceFunc { return sdk.ResourceFunc{ Timeout: 30 * time.Minute, Func: func(ctx context.Context, metadata sdk.ResourceMetaData) error { - client := metadata.Client.CostManagement.ScheduledActionsClient_v2022_10_01 + client := metadata.Client.CostManagement.ScheduledActionsClient id, err := scheduledactions.ParseScopedScheduledActionID(metadata.ResourceData.Id()) if err != nil { diff --git a/internal/services/costmanagement/scheduled_action_resource_test.go b/internal/services/costmanagement/scheduled_action_resource_test.go index cb825873abd8..b148bd78598f 100644 --- a/internal/services/costmanagement/scheduled_action_resource_test.go +++ b/internal/services/costmanagement/scheduled_action_resource_test.go @@ -9,7 +9,7 @@ import ( "testing" "time" - "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions" + "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions" "github.com/hashicorp/terraform-provider-azurerm/internal/acceptance" "github.com/hashicorp/terraform-provider-azurerm/internal/acceptance/check" "github.com/hashicorp/terraform-provider-azurerm/internal/clients" @@ -116,7 +116,7 @@ func (t CostManagementScheduledAction) Exists(ctx context.Context, clients *clie return nil, err } - resp, err := clients.CostManagement.ScheduledActionsClient_v2022_10_01.GetByScope(ctx, *id) + resp, err := clients.CostManagement.ScheduledActionsClient.GetByScope(ctx, *id) if err != nil { return nil, fmt.Errorf("retrieving (%s): %+v", *id, err) } diff --git a/internal/services/costmanagement/view_resource_base.go b/internal/services/costmanagement/view_resource_base.go index 9bbdcb28f6ac..cfd14e1f3f8b 100644 --- a/internal/services/costmanagement/view_resource_base.go +++ b/internal/services/costmanagement/view_resource_base.go @@ -10,7 +10,7 @@ import ( "github.com/hashicorp/go-azure-helpers/lang/pointer" "github.com/hashicorp/go-azure-helpers/lang/response" - "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views" + "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views" "github.com/hashicorp/terraform-provider-azurerm/helpers/tf" "github.com/hashicorp/terraform-provider-azurerm/internal/sdk" "github.com/hashicorp/terraform-provider-azurerm/internal/tf/pluginsdk" diff --git a/internal/services/costmanagement/view_resource_group_resource_test.go b/internal/services/costmanagement/view_resource_group_resource_test.go index 3c7e73394448..0b455db4a3f6 100644 --- a/internal/services/costmanagement/view_resource_group_resource_test.go +++ b/internal/services/costmanagement/view_resource_group_resource_test.go @@ -8,7 +8,7 @@ import ( "fmt" "testing" - "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views" + "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views" "github.com/hashicorp/terraform-provider-azurerm/internal/acceptance" "github.com/hashicorp/terraform-provider-azurerm/internal/acceptance/check" "github.com/hashicorp/terraform-provider-azurerm/internal/clients" diff --git a/internal/services/costmanagement/view_subscription_resource_test.go b/internal/services/costmanagement/view_subscription_resource_test.go index 550debc6cab5..c23482fceaff 100644 --- a/internal/services/costmanagement/view_subscription_resource_test.go +++ b/internal/services/costmanagement/view_subscription_resource_test.go @@ -8,7 +8,7 @@ import ( "fmt" "testing" - "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views" + "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views" "github.com/hashicorp/terraform-provider-azurerm/internal/acceptance" "github.com/hashicorp/terraform-provider-azurerm/internal/acceptance/check" "github.com/hashicorp/terraform-provider-azurerm/internal/clients" From 51c23b2f159890e3827cc06cc262b20dac761d12 Mon Sep 17 00:00:00 2001 From: Sebastian Heid <8442432+s4heid@users.noreply.github.com> Date: Thu, 17 Oct 2024 15:42:44 +0200 Subject: [PATCH 2/5] Update vendored go dependencies --- .../2021-10-01/exports/model_export.go | 12 - .../exports/model_exportexecution.go | 12 - .../scheduledactions/README.md | 234 ------------- .../scheduledactions/constants.go | 321 ------------------ .../scheduledactions/method_createorupdate.go | 58 ---- .../method_createorupdatebyscope.go | 58 ---- .../scheduledactions/method_execute.go | 47 --- .../scheduledactions/method_executebyscope.go | 47 --- .../model_notificationproperties.go | 10 - .../model_scheduledactionproperties.go | 14 - .../scheduledactions/version.go | 10 - .../2022-10-01/scheduledactions/client.go | 26 -- .../scheduledactions/id_scheduledaction.go | 112 ------ .../id_scopedscheduledaction.go | 120 ------- .../method_checknameavailability.go | 57 ---- .../method_checknameavailabilitybyscope.go | 59 ---- .../scheduledactions/method_delete.go | 47 --- .../scheduledactions/method_deletebyscope.go | 47 --- .../2022-10-01/scheduledactions/method_get.go | 53 --- .../scheduledactions/method_getbyscope.go | 53 --- .../scheduledactions/method_list.go | 134 -------- .../scheduledactions/method_listbyscope.go | 135 -------- .../model_checknameavailabilityrequest.go | 9 - .../model_checknameavailabilityresponse.go | 10 - .../scheduledactions/model_filedestination.go | 8 - .../scheduledactions/model_scheduledaction.go | 18 - .../model_scheduleproperties.go | 38 --- .../2022-10-01/scheduledactions/predicates.go | 32 -- .../exports/README.md | 6 +- .../exports/client.go | 0 .../exports/constants.go | 0 .../exports/id_scopedexport.go | 0 .../exports/method_createorupdate.go | 0 .../exports/method_delete.go | 0 .../exports/method_execute.go | 0 .../exports/method_get.go | 0 .../exports/method_getexecutionhistory.go | 0 .../exports/method_list.go | 0 .../exports/model_commonexportproperties.go | 0 .../exports/model_errordetails.go | 0 .../2023-08-01/exports/model_export.go | 18 + .../exports/model_exportdataset.go | 0 .../model_exportdatasetconfiguration.go | 0 .../exports/model_exportdefinition.go | 0 .../model_exportdeliverydestination.go | 0 .../exports/model_exportdeliveryinfo.go | 0 .../model_exportexecutionlistresult.go | 2 +- .../exports/model_exportlistresult.go | 0 .../exports/model_exportproperties.go | 0 .../exports/model_exportrecurrenceperiod.go | 0 .../2023-08-01/exports/model_exportrun.go | 12 + .../exports/model_exportrunproperties.go} | 14 +- .../exports/model_exportschedule.go | 0 .../exports/model_exporttimeperiod.go | 0 .../exports/version.go | 4 +- .../scheduledactions/README.md | 6 +- .../scheduledactions/client.go | 0 .../scheduledactions/constants.go | 0 .../scheduledactions/id_scheduledaction.go | 0 .../id_scopedscheduledaction.go | 0 .../method_checknameavailability.go | 0 .../method_checknameavailabilitybyscope.go | 0 .../scheduledactions/method_createorupdate.go | 0 .../method_createorupdatebyscope.go | 0 .../scheduledactions/method_delete.go | 0 .../scheduledactions/method_deletebyscope.go | 0 .../scheduledactions/method_get.go | 0 .../scheduledactions/method_getbyscope.go | 0 .../scheduledactions/method_list.go | 0 .../scheduledactions/method_listbyscope.go | 0 .../scheduledactions/method_run.go | 0 .../scheduledactions/method_runbyscope.go | 0 .../model_checknameavailabilityrequest.go | 0 .../model_checknameavailabilityresponse.go | 0 .../scheduledactions/model_filedestination.go | 0 .../model_notificationproperties.go | 0 .../scheduledactions/model_scheduledaction.go | 0 .../model_scheduledactionproperties.go | 0 .../model_scheduleproperties.go | 0 .../scheduledactions/predicates.go | 0 .../scheduledactions/version.go | 4 +- .../views/README.md | 6 +- .../views/client.go | 0 .../views/constants.go | 0 .../views/id_scopedview.go | 0 .../views/id_view.go | 0 .../views/method_createorupdate.go | 0 .../views/method_createorupdatebyscope.go | 0 .../views/method_delete.go | 0 .../views/method_deletebyscope.go | 0 .../views/method_get.go | 0 .../views/method_getbyscope.go | 0 .../views/method_list.go | 0 .../views/method_listbyscope.go | 0 .../views/model_kpiproperties.go | 0 .../views/model_pivotproperties.go | 0 .../views/model_reportconfigaggregation.go | 0 .../model_reportconfigcomparisonexpression.go | 0 .../views/model_reportconfigdataset.go | 0 .../model_reportconfigdatasetconfiguration.go | 0 .../views/model_reportconfigdefinition.go | 0 .../views/model_reportconfigfilter.go | 0 .../views/model_reportconfiggrouping.go | 0 .../views/model_reportconfigsorting.go | 0 .../views/model_reportconfigtimeperiod.go | 0 .../views/model_view.go | 0 .../views/model_viewproperties.go | 0 .../views/predicates.go | 0 .../views/version.go | 4 +- vendor/modules.txt | 7 +- 110 files changed, 56 insertions(+), 1808 deletions(-) delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_export.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportexecution.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/README.md delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/constants.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_createorupdate.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_createorupdatebyscope.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_execute.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_executebyscope.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/model_notificationproperties.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/model_scheduledactionproperties.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/version.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/client.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/id_scheduledaction.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/id_scopedscheduledaction.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_checknameavailability.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_checknameavailabilitybyscope.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_delete.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_deletebyscope.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_get.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_getbyscope.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_list.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_listbyscope.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/model_checknameavailabilityrequest.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/model_checknameavailabilityresponse.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/model_filedestination.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/model_scheduledaction.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/model_scheduleproperties.go delete mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/predicates.go rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01 => 2023-08-01}/exports/README.md (96%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01 => 2023-08-01}/exports/client.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01 => 2023-08-01}/exports/constants.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01 => 2023-08-01}/exports/id_scopedexport.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01 => 2023-08-01}/exports/method_createorupdate.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01 => 2023-08-01}/exports/method_delete.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01 => 2023-08-01}/exports/method_execute.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01 => 2023-08-01}/exports/method_get.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01 => 2023-08-01}/exports/method_getexecutionhistory.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01 => 2023-08-01}/exports/method_list.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01 => 2023-08-01}/exports/model_commonexportproperties.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01 => 2023-08-01}/exports/model_errordetails.go (100%) create mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_export.go rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01 => 2023-08-01}/exports/model_exportdataset.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01 => 2023-08-01}/exports/model_exportdatasetconfiguration.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01 => 2023-08-01}/exports/model_exportdefinition.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01 => 2023-08-01}/exports/model_exportdeliverydestination.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01 => 2023-08-01}/exports/model_exportdeliveryinfo.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01 => 2023-08-01}/exports/model_exportexecutionlistresult.go (80%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01 => 2023-08-01}/exports/model_exportlistresult.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01 => 2023-08-01}/exports/model_exportproperties.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01 => 2023-08-01}/exports/model_exportrecurrenceperiod.go (100%) create mode 100644 vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportrun.go rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01/exports/model_exportexecutionproperties.go => 2023-08-01/exports/model_exportrunproperties.go} (76%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01 => 2023-08-01}/exports/model_exportschedule.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01 => 2023-08-01}/exports/model_exporttimeperiod.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2021-10-01 => 2023-08-01}/exports/version.go (69%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/scheduledactions/README.md (97%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-06-01-preview => 2023-08-01}/scheduledactions/client.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/scheduledactions/constants.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-06-01-preview => 2023-08-01}/scheduledactions/id_scheduledaction.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-06-01-preview => 2023-08-01}/scheduledactions/id_scopedscheduledaction.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-06-01-preview => 2023-08-01}/scheduledactions/method_checknameavailability.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-06-01-preview => 2023-08-01}/scheduledactions/method_checknameavailabilitybyscope.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/scheduledactions/method_createorupdate.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/scheduledactions/method_createorupdatebyscope.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-06-01-preview => 2023-08-01}/scheduledactions/method_delete.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-06-01-preview => 2023-08-01}/scheduledactions/method_deletebyscope.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-06-01-preview => 2023-08-01}/scheduledactions/method_get.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-06-01-preview => 2023-08-01}/scheduledactions/method_getbyscope.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-06-01-preview => 2023-08-01}/scheduledactions/method_list.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-06-01-preview => 2023-08-01}/scheduledactions/method_listbyscope.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/scheduledactions/method_run.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/scheduledactions/method_runbyscope.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-06-01-preview => 2023-08-01}/scheduledactions/model_checknameavailabilityrequest.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-06-01-preview => 2023-08-01}/scheduledactions/model_checknameavailabilityresponse.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-06-01-preview => 2023-08-01}/scheduledactions/model_filedestination.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/scheduledactions/model_notificationproperties.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-06-01-preview => 2023-08-01}/scheduledactions/model_scheduledaction.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/scheduledactions/model_scheduledactionproperties.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-06-01-preview => 2023-08-01}/scheduledactions/model_scheduleproperties.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-06-01-preview => 2023-08-01}/scheduledactions/predicates.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/scheduledactions/version.go (67%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/README.md (96%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/client.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/constants.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/id_scopedview.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/id_view.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/method_createorupdate.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/method_createorupdatebyscope.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/method_delete.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/method_deletebyscope.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/method_get.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/method_getbyscope.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/method_list.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/method_listbyscope.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/model_kpiproperties.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/model_pivotproperties.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/model_reportconfigaggregation.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/model_reportconfigcomparisonexpression.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/model_reportconfigdataset.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/model_reportconfigdatasetconfiguration.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/model_reportconfigdefinition.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/model_reportconfigfilter.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/model_reportconfiggrouping.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/model_reportconfigsorting.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/model_reportconfigtimeperiod.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/model_view.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/model_viewproperties.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/predicates.go (100%) rename vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/{2022-10-01 => 2023-08-01}/views/version.go (69%) diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_export.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_export.go deleted file mode 100644 index ea296361983c..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_export.go +++ /dev/null @@ -1,12 +0,0 @@ -package exports - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type Export struct { - ETag *string `json:"eTag,omitempty"` - Id *string `json:"id,omitempty"` - Name *string `json:"name,omitempty"` - Properties *ExportProperties `json:"properties,omitempty"` - Type *string `json:"type,omitempty"` -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportexecution.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportexecution.go deleted file mode 100644 index 5cddc2df1e6b..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportexecution.go +++ /dev/null @@ -1,12 +0,0 @@ -package exports - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type ExportExecution struct { - ETag *string `json:"eTag,omitempty"` - Id *string `json:"id,omitempty"` - Name *string `json:"name,omitempty"` - Properties *ExportExecutionProperties `json:"properties,omitempty"` - Type *string `json:"type,omitempty"` -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/README.md b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/README.md deleted file mode 100644 index 6570b9d31c90..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/README.md +++ /dev/null @@ -1,234 +0,0 @@ - -## `github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions` Documentation - -The `scheduledactions` SDK allows for interaction with Azure Resource Manager `costmanagement` (API Version `2022-06-01-preview`). - -This readme covers example usages, but further information on [using this SDK can be found in the project root](https://github.com/hashicorp/go-azure-sdk/tree/main/docs). - -### Import Path - -```go -import "github.com/hashicorp/go-azure-helpers/resourcemanager/commonids" -import "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions" -``` - - -### Client Initialization - -```go -client := scheduledactions.NewScheduledActionsClientWithBaseURI("https://management.azure.com") -client.Client.Authorizer = authorizer -``` - - -### Example Usage: `ScheduledActionsClient.CheckNameAvailability` - -```go -ctx := context.TODO() - -payload := scheduledactions.CheckNameAvailabilityRequest{ - // ... -} - - -read, err := client.CheckNameAvailability(ctx, payload) -if err != nil { - // handle the error -} -if model := read.Model; model != nil { - // do something with the model/response object -} -``` - - -### Example Usage: `ScheduledActionsClient.CheckNameAvailabilityByScope` - -```go -ctx := context.TODO() -id := commonids.NewScopeID("/subscriptions/12345678-1234-9876-4563-123456789012/resourceGroups/some-resource-group") - -payload := scheduledactions.CheckNameAvailabilityRequest{ - // ... -} - - -read, err := client.CheckNameAvailabilityByScope(ctx, id, payload) -if err != nil { - // handle the error -} -if model := read.Model; model != nil { - // do something with the model/response object -} -``` - - -### Example Usage: `ScheduledActionsClient.CreateOrUpdate` - -```go -ctx := context.TODO() -id := scheduledactions.NewScheduledActionID("scheduledActionName") - -payload := scheduledactions.ScheduledAction{ - // ... -} - - -read, err := client.CreateOrUpdate(ctx, id, payload) -if err != nil { - // handle the error -} -if model := read.Model; model != nil { - // do something with the model/response object -} -``` - - -### Example Usage: `ScheduledActionsClient.CreateOrUpdateByScope` - -```go -ctx := context.TODO() -id := scheduledactions.NewScopedScheduledActionID("/subscriptions/12345678-1234-9876-4563-123456789012/resourceGroups/some-resource-group", "scheduledActionName") - -payload := scheduledactions.ScheduledAction{ - // ... -} - - -read, err := client.CreateOrUpdateByScope(ctx, id, payload) -if err != nil { - // handle the error -} -if model := read.Model; model != nil { - // do something with the model/response object -} -``` - - -### Example Usage: `ScheduledActionsClient.Delete` - -```go -ctx := context.TODO() -id := scheduledactions.NewScheduledActionID("scheduledActionName") - -read, err := client.Delete(ctx, id) -if err != nil { - // handle the error -} -if model := read.Model; model != nil { - // do something with the model/response object -} -``` - - -### Example Usage: `ScheduledActionsClient.DeleteByScope` - -```go -ctx := context.TODO() -id := scheduledactions.NewScopedScheduledActionID("/subscriptions/12345678-1234-9876-4563-123456789012/resourceGroups/some-resource-group", "scheduledActionName") - -read, err := client.DeleteByScope(ctx, id) -if err != nil { - // handle the error -} -if model := read.Model; model != nil { - // do something with the model/response object -} -``` - - -### Example Usage: `ScheduledActionsClient.Execute` - -```go -ctx := context.TODO() -id := scheduledactions.NewScheduledActionID("scheduledActionName") - -read, err := client.Execute(ctx, id) -if err != nil { - // handle the error -} -if model := read.Model; model != nil { - // do something with the model/response object -} -``` - - -### Example Usage: `ScheduledActionsClient.ExecuteByScope` - -```go -ctx := context.TODO() -id := scheduledactions.NewScopedScheduledActionID("/subscriptions/12345678-1234-9876-4563-123456789012/resourceGroups/some-resource-group", "scheduledActionName") - -read, err := client.ExecuteByScope(ctx, id) -if err != nil { - // handle the error -} -if model := read.Model; model != nil { - // do something with the model/response object -} -``` - - -### Example Usage: `ScheduledActionsClient.Get` - -```go -ctx := context.TODO() -id := scheduledactions.NewScheduledActionID("scheduledActionName") - -read, err := client.Get(ctx, id) -if err != nil { - // handle the error -} -if model := read.Model; model != nil { - // do something with the model/response object -} -``` - - -### Example Usage: `ScheduledActionsClient.GetByScope` - -```go -ctx := context.TODO() -id := scheduledactions.NewScopedScheduledActionID("/subscriptions/12345678-1234-9876-4563-123456789012/resourceGroups/some-resource-group", "scheduledActionName") - -read, err := client.GetByScope(ctx, id) -if err != nil { - // handle the error -} -if model := read.Model; model != nil { - // do something with the model/response object -} -``` - - -### Example Usage: `ScheduledActionsClient.List` - -```go -ctx := context.TODO() - - -// alternatively `client.List(ctx, scheduledactions.DefaultListOperationOptions())` can be used to do batched pagination -items, err := client.ListComplete(ctx, scheduledactions.DefaultListOperationOptions()) -if err != nil { - // handle the error -} -for _, item := range items { - // do something -} -``` - - -### Example Usage: `ScheduledActionsClient.ListByScope` - -```go -ctx := context.TODO() -id := commonids.NewScopeID("/subscriptions/12345678-1234-9876-4563-123456789012/resourceGroups/some-resource-group") - -// alternatively `client.ListByScope(ctx, id, scheduledactions.DefaultListByScopeOperationOptions())` can be used to do batched pagination -items, err := client.ListByScopeComplete(ctx, id, scheduledactions.DefaultListByScopeOperationOptions()) -if err != nil { - // handle the error -} -for _, item := range items { - // do something -} -``` diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/constants.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/constants.go deleted file mode 100644 index 6b9608d79a5c..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/constants.go +++ /dev/null @@ -1,321 +0,0 @@ -package scheduledactions - -import ( - "encoding/json" - "fmt" - "strings" -) - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type CheckNameAvailabilityReason string - -const ( - CheckNameAvailabilityReasonAlreadyExists CheckNameAvailabilityReason = "AlreadyExists" - CheckNameAvailabilityReasonInvalid CheckNameAvailabilityReason = "Invalid" -) - -func PossibleValuesForCheckNameAvailabilityReason() []string { - return []string{ - string(CheckNameAvailabilityReasonAlreadyExists), - string(CheckNameAvailabilityReasonInvalid), - } -} - -func (s *CheckNameAvailabilityReason) UnmarshalJSON(bytes []byte) error { - var decoded string - if err := json.Unmarshal(bytes, &decoded); err != nil { - return fmt.Errorf("unmarshaling: %+v", err) - } - out, err := parseCheckNameAvailabilityReason(decoded) - if err != nil { - return fmt.Errorf("parsing %q: %+v", decoded, err) - } - *s = *out - return nil -} - -func parseCheckNameAvailabilityReason(input string) (*CheckNameAvailabilityReason, error) { - vals := map[string]CheckNameAvailabilityReason{ - "alreadyexists": CheckNameAvailabilityReasonAlreadyExists, - "invalid": CheckNameAvailabilityReasonInvalid, - } - if v, ok := vals[strings.ToLower(input)]; ok { - return &v, nil - } - - // otherwise presume it's an undefined value and best-effort it - out := CheckNameAvailabilityReason(input) - return &out, nil -} - -type DaysOfWeek string - -const ( - DaysOfWeekFriday DaysOfWeek = "Friday" - DaysOfWeekMonday DaysOfWeek = "Monday" - DaysOfWeekSaturday DaysOfWeek = "Saturday" - DaysOfWeekSunday DaysOfWeek = "Sunday" - DaysOfWeekThursday DaysOfWeek = "Thursday" - DaysOfWeekTuesday DaysOfWeek = "Tuesday" - DaysOfWeekWednesday DaysOfWeek = "Wednesday" -) - -func PossibleValuesForDaysOfWeek() []string { - return []string{ - string(DaysOfWeekFriday), - string(DaysOfWeekMonday), - string(DaysOfWeekSaturday), - string(DaysOfWeekSunday), - string(DaysOfWeekThursday), - string(DaysOfWeekTuesday), - string(DaysOfWeekWednesday), - } -} - -func (s *DaysOfWeek) UnmarshalJSON(bytes []byte) error { - var decoded string - if err := json.Unmarshal(bytes, &decoded); err != nil { - return fmt.Errorf("unmarshaling: %+v", err) - } - out, err := parseDaysOfWeek(decoded) - if err != nil { - return fmt.Errorf("parsing %q: %+v", decoded, err) - } - *s = *out - return nil -} - -func parseDaysOfWeek(input string) (*DaysOfWeek, error) { - vals := map[string]DaysOfWeek{ - "friday": DaysOfWeekFriday, - "monday": DaysOfWeekMonday, - "saturday": DaysOfWeekSaturday, - "sunday": DaysOfWeekSunday, - "thursday": DaysOfWeekThursday, - "tuesday": DaysOfWeekTuesday, - "wednesday": DaysOfWeekWednesday, - } - if v, ok := vals[strings.ToLower(input)]; ok { - return &v, nil - } - - // otherwise presume it's an undefined value and best-effort it - out := DaysOfWeek(input) - return &out, nil -} - -type FileFormat string - -const ( - FileFormatCsv FileFormat = "Csv" -) - -func PossibleValuesForFileFormat() []string { - return []string{ - string(FileFormatCsv), - } -} - -func (s *FileFormat) UnmarshalJSON(bytes []byte) error { - var decoded string - if err := json.Unmarshal(bytes, &decoded); err != nil { - return fmt.Errorf("unmarshaling: %+v", err) - } - out, err := parseFileFormat(decoded) - if err != nil { - return fmt.Errorf("parsing %q: %+v", decoded, err) - } - *s = *out - return nil -} - -func parseFileFormat(input string) (*FileFormat, error) { - vals := map[string]FileFormat{ - "csv": FileFormatCsv, - } - if v, ok := vals[strings.ToLower(input)]; ok { - return &v, nil - } - - // otherwise presume it's an undefined value and best-effort it - out := FileFormat(input) - return &out, nil -} - -type ScheduleFrequency string - -const ( - ScheduleFrequencyDaily ScheduleFrequency = "Daily" - ScheduleFrequencyMonthly ScheduleFrequency = "Monthly" - ScheduleFrequencyWeekly ScheduleFrequency = "Weekly" -) - -func PossibleValuesForScheduleFrequency() []string { - return []string{ - string(ScheduleFrequencyDaily), - string(ScheduleFrequencyMonthly), - string(ScheduleFrequencyWeekly), - } -} - -func (s *ScheduleFrequency) UnmarshalJSON(bytes []byte) error { - var decoded string - if err := json.Unmarshal(bytes, &decoded); err != nil { - return fmt.Errorf("unmarshaling: %+v", err) - } - out, err := parseScheduleFrequency(decoded) - if err != nil { - return fmt.Errorf("parsing %q: %+v", decoded, err) - } - *s = *out - return nil -} - -func parseScheduleFrequency(input string) (*ScheduleFrequency, error) { - vals := map[string]ScheduleFrequency{ - "daily": ScheduleFrequencyDaily, - "monthly": ScheduleFrequencyMonthly, - "weekly": ScheduleFrequencyWeekly, - } - if v, ok := vals[strings.ToLower(input)]; ok { - return &v, nil - } - - // otherwise presume it's an undefined value and best-effort it - out := ScheduleFrequency(input) - return &out, nil -} - -type ScheduledActionKind string - -const ( - ScheduledActionKindEmail ScheduledActionKind = "Email" - ScheduledActionKindInsightAlert ScheduledActionKind = "InsightAlert" -) - -func PossibleValuesForScheduledActionKind() []string { - return []string{ - string(ScheduledActionKindEmail), - string(ScheduledActionKindInsightAlert), - } -} - -func (s *ScheduledActionKind) UnmarshalJSON(bytes []byte) error { - var decoded string - if err := json.Unmarshal(bytes, &decoded); err != nil { - return fmt.Errorf("unmarshaling: %+v", err) - } - out, err := parseScheduledActionKind(decoded) - if err != nil { - return fmt.Errorf("parsing %q: %+v", decoded, err) - } - *s = *out - return nil -} - -func parseScheduledActionKind(input string) (*ScheduledActionKind, error) { - vals := map[string]ScheduledActionKind{ - "email": ScheduledActionKindEmail, - "insightalert": ScheduledActionKindInsightAlert, - } - if v, ok := vals[strings.ToLower(input)]; ok { - return &v, nil - } - - // otherwise presume it's an undefined value and best-effort it - out := ScheduledActionKind(input) - return &out, nil -} - -type ScheduledActionStatus string - -const ( - ScheduledActionStatusDisabled ScheduledActionStatus = "Disabled" - ScheduledActionStatusEnabled ScheduledActionStatus = "Enabled" -) - -func PossibleValuesForScheduledActionStatus() []string { - return []string{ - string(ScheduledActionStatusDisabled), - string(ScheduledActionStatusEnabled), - } -} - -func (s *ScheduledActionStatus) UnmarshalJSON(bytes []byte) error { - var decoded string - if err := json.Unmarshal(bytes, &decoded); err != nil { - return fmt.Errorf("unmarshaling: %+v", err) - } - out, err := parseScheduledActionStatus(decoded) - if err != nil { - return fmt.Errorf("parsing %q: %+v", decoded, err) - } - *s = *out - return nil -} - -func parseScheduledActionStatus(input string) (*ScheduledActionStatus, error) { - vals := map[string]ScheduledActionStatus{ - "disabled": ScheduledActionStatusDisabled, - "enabled": ScheduledActionStatusEnabled, - } - if v, ok := vals[strings.ToLower(input)]; ok { - return &v, nil - } - - // otherwise presume it's an undefined value and best-effort it - out := ScheduledActionStatus(input) - return &out, nil -} - -type WeeksOfMonth string - -const ( - WeeksOfMonthFirst WeeksOfMonth = "First" - WeeksOfMonthFourth WeeksOfMonth = "Fourth" - WeeksOfMonthLast WeeksOfMonth = "Last" - WeeksOfMonthSecond WeeksOfMonth = "Second" - WeeksOfMonthThird WeeksOfMonth = "Third" -) - -func PossibleValuesForWeeksOfMonth() []string { - return []string{ - string(WeeksOfMonthFirst), - string(WeeksOfMonthFourth), - string(WeeksOfMonthLast), - string(WeeksOfMonthSecond), - string(WeeksOfMonthThird), - } -} - -func (s *WeeksOfMonth) UnmarshalJSON(bytes []byte) error { - var decoded string - if err := json.Unmarshal(bytes, &decoded); err != nil { - return fmt.Errorf("unmarshaling: %+v", err) - } - out, err := parseWeeksOfMonth(decoded) - if err != nil { - return fmt.Errorf("parsing %q: %+v", decoded, err) - } - *s = *out - return nil -} - -func parseWeeksOfMonth(input string) (*WeeksOfMonth, error) { - vals := map[string]WeeksOfMonth{ - "first": WeeksOfMonthFirst, - "fourth": WeeksOfMonthFourth, - "last": WeeksOfMonthLast, - "second": WeeksOfMonthSecond, - "third": WeeksOfMonthThird, - } - if v, ok := vals[strings.ToLower(input)]; ok { - return &v, nil - } - - // otherwise presume it's an undefined value and best-effort it - out := WeeksOfMonth(input) - return &out, nil -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_createorupdate.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_createorupdate.go deleted file mode 100644 index bada485b8fe6..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_createorupdate.go +++ /dev/null @@ -1,58 +0,0 @@ -package scheduledactions - -import ( - "context" - "net/http" - - "github.com/hashicorp/go-azure-sdk/sdk/client" - "github.com/hashicorp/go-azure-sdk/sdk/odata" -) - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type CreateOrUpdateOperationResponse struct { - HttpResponse *http.Response - OData *odata.OData - Model *ScheduledAction -} - -// CreateOrUpdate ... -func (c ScheduledActionsClient) CreateOrUpdate(ctx context.Context, id ScheduledActionId, input ScheduledAction) (result CreateOrUpdateOperationResponse, err error) { - opts := client.RequestOptions{ - ContentType: "application/json; charset=utf-8", - ExpectedStatusCodes: []int{ - http.StatusCreated, - http.StatusOK, - }, - HttpMethod: http.MethodPut, - Path: id.ID(), - } - - req, err := c.Client.NewRequest(ctx, opts) - if err != nil { - return - } - - if err = req.Marshal(input); err != nil { - return - } - - var resp *client.Response - resp, err = req.Execute(ctx) - if resp != nil { - result.OData = resp.OData - result.HttpResponse = resp.Response - } - if err != nil { - return - } - - var model ScheduledAction - result.Model = &model - if err = resp.Unmarshal(result.Model); err != nil { - return - } - - return -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_createorupdatebyscope.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_createorupdatebyscope.go deleted file mode 100644 index 636c9075980f..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_createorupdatebyscope.go +++ /dev/null @@ -1,58 +0,0 @@ -package scheduledactions - -import ( - "context" - "net/http" - - "github.com/hashicorp/go-azure-sdk/sdk/client" - "github.com/hashicorp/go-azure-sdk/sdk/odata" -) - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type CreateOrUpdateByScopeOperationResponse struct { - HttpResponse *http.Response - OData *odata.OData - Model *ScheduledAction -} - -// CreateOrUpdateByScope ... -func (c ScheduledActionsClient) CreateOrUpdateByScope(ctx context.Context, id ScopedScheduledActionId, input ScheduledAction) (result CreateOrUpdateByScopeOperationResponse, err error) { - opts := client.RequestOptions{ - ContentType: "application/json; charset=utf-8", - ExpectedStatusCodes: []int{ - http.StatusCreated, - http.StatusOK, - }, - HttpMethod: http.MethodPut, - Path: id.ID(), - } - - req, err := c.Client.NewRequest(ctx, opts) - if err != nil { - return - } - - if err = req.Marshal(input); err != nil { - return - } - - var resp *client.Response - resp, err = req.Execute(ctx) - if resp != nil { - result.OData = resp.OData - result.HttpResponse = resp.Response - } - if err != nil { - return - } - - var model ScheduledAction - result.Model = &model - if err = resp.Unmarshal(result.Model); err != nil { - return - } - - return -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_execute.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_execute.go deleted file mode 100644 index 67540ef8ed77..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_execute.go +++ /dev/null @@ -1,47 +0,0 @@ -package scheduledactions - -import ( - "context" - "fmt" - "net/http" - - "github.com/hashicorp/go-azure-sdk/sdk/client" - "github.com/hashicorp/go-azure-sdk/sdk/odata" -) - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type ExecuteOperationResponse struct { - HttpResponse *http.Response - OData *odata.OData -} - -// Execute ... -func (c ScheduledActionsClient) Execute(ctx context.Context, id ScheduledActionId) (result ExecuteOperationResponse, err error) { - opts := client.RequestOptions{ - ContentType: "application/json; charset=utf-8", - ExpectedStatusCodes: []int{ - http.StatusOK, - }, - HttpMethod: http.MethodPost, - Path: fmt.Sprintf("%s/execute", id.ID()), - } - - req, err := c.Client.NewRequest(ctx, opts) - if err != nil { - return - } - - var resp *client.Response - resp, err = req.Execute(ctx) - if resp != nil { - result.OData = resp.OData - result.HttpResponse = resp.Response - } - if err != nil { - return - } - - return -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_executebyscope.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_executebyscope.go deleted file mode 100644 index 2ff61cc3e7bf..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_executebyscope.go +++ /dev/null @@ -1,47 +0,0 @@ -package scheduledactions - -import ( - "context" - "fmt" - "net/http" - - "github.com/hashicorp/go-azure-sdk/sdk/client" - "github.com/hashicorp/go-azure-sdk/sdk/odata" -) - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type ExecuteByScopeOperationResponse struct { - HttpResponse *http.Response - OData *odata.OData -} - -// ExecuteByScope ... -func (c ScheduledActionsClient) ExecuteByScope(ctx context.Context, id ScopedScheduledActionId) (result ExecuteByScopeOperationResponse, err error) { - opts := client.RequestOptions{ - ContentType: "application/json; charset=utf-8", - ExpectedStatusCodes: []int{ - http.StatusOK, - }, - HttpMethod: http.MethodPost, - Path: fmt.Sprintf("%s/execute", id.ID()), - } - - req, err := c.Client.NewRequest(ctx, opts) - if err != nil { - return - } - - var resp *client.Response - resp, err = req.Execute(ctx) - if resp != nil { - result.OData = resp.OData - result.HttpResponse = resp.Response - } - if err != nil { - return - } - - return -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/model_notificationproperties.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/model_notificationproperties.go deleted file mode 100644 index a579ae878522..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/model_notificationproperties.go +++ /dev/null @@ -1,10 +0,0 @@ -package scheduledactions - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type NotificationProperties struct { - Message *string `json:"message,omitempty"` - Subject string `json:"subject"` - To []string `json:"to"` -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/model_scheduledactionproperties.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/model_scheduledactionproperties.go deleted file mode 100644 index 2610efa9651f..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/model_scheduledactionproperties.go +++ /dev/null @@ -1,14 +0,0 @@ -package scheduledactions - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type ScheduledActionProperties struct { - DisplayName string `json:"displayName"` - FileDestination *FileDestination `json:"fileDestination,omitempty"` - Notification NotificationProperties `json:"notification"` - Schedule ScheduleProperties `json:"schedule"` - Scope *string `json:"scope,omitempty"` - Status ScheduledActionStatus `json:"status"` - ViewId string `json:"viewId"` -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/version.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/version.go deleted file mode 100644 index ff08bd057298..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/version.go +++ /dev/null @@ -1,10 +0,0 @@ -package scheduledactions - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -const defaultApiVersion = "2022-06-01-preview" - -func userAgent() string { - return "hashicorp/go-azure-sdk/scheduledactions/2022-06-01-preview" -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/client.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/client.go deleted file mode 100644 index 2ad38dee43c8..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/client.go +++ /dev/null @@ -1,26 +0,0 @@ -package scheduledactions - -import ( - "fmt" - - "github.com/hashicorp/go-azure-sdk/sdk/client/resourcemanager" - sdkEnv "github.com/hashicorp/go-azure-sdk/sdk/environments" -) - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type ScheduledActionsClient struct { - Client *resourcemanager.Client -} - -func NewScheduledActionsClientWithBaseURI(sdkApi sdkEnv.Api) (*ScheduledActionsClient, error) { - client, err := resourcemanager.NewClient(sdkApi, "scheduledactions", defaultApiVersion) - if err != nil { - return nil, fmt.Errorf("instantiating ScheduledActionsClient: %+v", err) - } - - return &ScheduledActionsClient{ - Client: client, - }, nil -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/id_scheduledaction.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/id_scheduledaction.go deleted file mode 100644 index 458a9d731249..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/id_scheduledaction.go +++ /dev/null @@ -1,112 +0,0 @@ -package scheduledactions - -import ( - "fmt" - "strings" - - "github.com/hashicorp/go-azure-helpers/resourcemanager/recaser" - "github.com/hashicorp/go-azure-helpers/resourcemanager/resourceids" -) - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -func init() { - recaser.RegisterResourceId(&ScheduledActionId{}) -} - -var _ resourceids.ResourceId = &ScheduledActionId{} - -// ScheduledActionId is a struct representing the Resource ID for a Scheduled Action -type ScheduledActionId struct { - ScheduledActionName string -} - -// NewScheduledActionID returns a new ScheduledActionId struct -func NewScheduledActionID(scheduledActionName string) ScheduledActionId { - return ScheduledActionId{ - ScheduledActionName: scheduledActionName, - } -} - -// ParseScheduledActionID parses 'input' into a ScheduledActionId -func ParseScheduledActionID(input string) (*ScheduledActionId, error) { - parser := resourceids.NewParserFromResourceIdType(&ScheduledActionId{}) - parsed, err := parser.Parse(input, false) - if err != nil { - return nil, fmt.Errorf("parsing %q: %+v", input, err) - } - - id := ScheduledActionId{} - if err = id.FromParseResult(*parsed); err != nil { - return nil, err - } - - return &id, nil -} - -// ParseScheduledActionIDInsensitively parses 'input' case-insensitively into a ScheduledActionId -// note: this method should only be used for API response data and not user input -func ParseScheduledActionIDInsensitively(input string) (*ScheduledActionId, error) { - parser := resourceids.NewParserFromResourceIdType(&ScheduledActionId{}) - parsed, err := parser.Parse(input, true) - if err != nil { - return nil, fmt.Errorf("parsing %q: %+v", input, err) - } - - id := ScheduledActionId{} - if err = id.FromParseResult(*parsed); err != nil { - return nil, err - } - - return &id, nil -} - -func (id *ScheduledActionId) FromParseResult(input resourceids.ParseResult) error { - var ok bool - - if id.ScheduledActionName, ok = input.Parsed["scheduledActionName"]; !ok { - return resourceids.NewSegmentNotSpecifiedError(id, "scheduledActionName", input) - } - - return nil -} - -// ValidateScheduledActionID checks that 'input' can be parsed as a Scheduled Action ID -func ValidateScheduledActionID(input interface{}, key string) (warnings []string, errors []error) { - v, ok := input.(string) - if !ok { - errors = append(errors, fmt.Errorf("expected %q to be a string", key)) - return - } - - if _, err := ParseScheduledActionID(v); err != nil { - errors = append(errors, err) - } - - return -} - -// ID returns the formatted Scheduled Action ID -func (id ScheduledActionId) ID() string { - fmtString := "/providers/Microsoft.CostManagement/scheduledActions/%s" - return fmt.Sprintf(fmtString, id.ScheduledActionName) -} - -// Segments returns a slice of Resource ID Segments which comprise this Scheduled Action ID -func (id ScheduledActionId) Segments() []resourceids.Segment { - return []resourceids.Segment{ - resourceids.StaticSegment("staticProviders", "providers", "providers"), - resourceids.ResourceProviderSegment("staticMicrosoftCostManagement", "Microsoft.CostManagement", "Microsoft.CostManagement"), - resourceids.StaticSegment("staticScheduledActions", "scheduledActions", "scheduledActions"), - resourceids.UserSpecifiedSegment("scheduledActionName", "scheduledActionName"), - } -} - -// String returns a human-readable description of this Scheduled Action ID -func (id ScheduledActionId) String() string { - components := []string{ - fmt.Sprintf("Scheduled Action Name: %q", id.ScheduledActionName), - } - return fmt.Sprintf("Scheduled Action (%s)", strings.Join(components, "\n")) -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/id_scopedscheduledaction.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/id_scopedscheduledaction.go deleted file mode 100644 index 1b37877a4c8b..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/id_scopedscheduledaction.go +++ /dev/null @@ -1,120 +0,0 @@ -package scheduledactions - -import ( - "fmt" - "strings" - - "github.com/hashicorp/go-azure-helpers/resourcemanager/recaser" - "github.com/hashicorp/go-azure-helpers/resourcemanager/resourceids" -) - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -func init() { - recaser.RegisterResourceId(&ScopedScheduledActionId{}) -} - -var _ resourceids.ResourceId = &ScopedScheduledActionId{} - -// ScopedScheduledActionId is a struct representing the Resource ID for a Scoped Scheduled Action -type ScopedScheduledActionId struct { - Scope string - ScheduledActionName string -} - -// NewScopedScheduledActionID returns a new ScopedScheduledActionId struct -func NewScopedScheduledActionID(scope string, scheduledActionName string) ScopedScheduledActionId { - return ScopedScheduledActionId{ - Scope: scope, - ScheduledActionName: scheduledActionName, - } -} - -// ParseScopedScheduledActionID parses 'input' into a ScopedScheduledActionId -func ParseScopedScheduledActionID(input string) (*ScopedScheduledActionId, error) { - parser := resourceids.NewParserFromResourceIdType(&ScopedScheduledActionId{}) - parsed, err := parser.Parse(input, false) - if err != nil { - return nil, fmt.Errorf("parsing %q: %+v", input, err) - } - - id := ScopedScheduledActionId{} - if err = id.FromParseResult(*parsed); err != nil { - return nil, err - } - - return &id, nil -} - -// ParseScopedScheduledActionIDInsensitively parses 'input' case-insensitively into a ScopedScheduledActionId -// note: this method should only be used for API response data and not user input -func ParseScopedScheduledActionIDInsensitively(input string) (*ScopedScheduledActionId, error) { - parser := resourceids.NewParserFromResourceIdType(&ScopedScheduledActionId{}) - parsed, err := parser.Parse(input, true) - if err != nil { - return nil, fmt.Errorf("parsing %q: %+v", input, err) - } - - id := ScopedScheduledActionId{} - if err = id.FromParseResult(*parsed); err != nil { - return nil, err - } - - return &id, nil -} - -func (id *ScopedScheduledActionId) FromParseResult(input resourceids.ParseResult) error { - var ok bool - - if id.Scope, ok = input.Parsed["scope"]; !ok { - return resourceids.NewSegmentNotSpecifiedError(id, "scope", input) - } - - if id.ScheduledActionName, ok = input.Parsed["scheduledActionName"]; !ok { - return resourceids.NewSegmentNotSpecifiedError(id, "scheduledActionName", input) - } - - return nil -} - -// ValidateScopedScheduledActionID checks that 'input' can be parsed as a Scoped Scheduled Action ID -func ValidateScopedScheduledActionID(input interface{}, key string) (warnings []string, errors []error) { - v, ok := input.(string) - if !ok { - errors = append(errors, fmt.Errorf("expected %q to be a string", key)) - return - } - - if _, err := ParseScopedScheduledActionID(v); err != nil { - errors = append(errors, err) - } - - return -} - -// ID returns the formatted Scoped Scheduled Action ID -func (id ScopedScheduledActionId) ID() string { - fmtString := "/%s/providers/Microsoft.CostManagement/scheduledActions/%s" - return fmt.Sprintf(fmtString, strings.TrimPrefix(id.Scope, "/"), id.ScheduledActionName) -} - -// Segments returns a slice of Resource ID Segments which comprise this Scoped Scheduled Action ID -func (id ScopedScheduledActionId) Segments() []resourceids.Segment { - return []resourceids.Segment{ - resourceids.ScopeSegment("scope", "/subscriptions/12345678-1234-9876-4563-123456789012/resourceGroups/some-resource-group"), - resourceids.StaticSegment("staticProviders", "providers", "providers"), - resourceids.ResourceProviderSegment("staticMicrosoftCostManagement", "Microsoft.CostManagement", "Microsoft.CostManagement"), - resourceids.StaticSegment("staticScheduledActions", "scheduledActions", "scheduledActions"), - resourceids.UserSpecifiedSegment("scheduledActionName", "scheduledActionName"), - } -} - -// String returns a human-readable description of this Scoped Scheduled Action ID -func (id ScopedScheduledActionId) String() string { - components := []string{ - fmt.Sprintf("Scope: %q", id.Scope), - fmt.Sprintf("Scheduled Action Name: %q", id.ScheduledActionName), - } - return fmt.Sprintf("Scoped Scheduled Action (%s)", strings.Join(components, "\n")) -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_checknameavailability.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_checknameavailability.go deleted file mode 100644 index 3e3c05e72bc3..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_checknameavailability.go +++ /dev/null @@ -1,57 +0,0 @@ -package scheduledactions - -import ( - "context" - "net/http" - - "github.com/hashicorp/go-azure-sdk/sdk/client" - "github.com/hashicorp/go-azure-sdk/sdk/odata" -) - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type CheckNameAvailabilityOperationResponse struct { - HttpResponse *http.Response - OData *odata.OData - Model *CheckNameAvailabilityResponse -} - -// CheckNameAvailability ... -func (c ScheduledActionsClient) CheckNameAvailability(ctx context.Context, input CheckNameAvailabilityRequest) (result CheckNameAvailabilityOperationResponse, err error) { - opts := client.RequestOptions{ - ContentType: "application/json; charset=utf-8", - ExpectedStatusCodes: []int{ - http.StatusOK, - }, - HttpMethod: http.MethodPost, - Path: "/providers/Microsoft.CostManagement/checkNameAvailability", - } - - req, err := c.Client.NewRequest(ctx, opts) - if err != nil { - return - } - - if err = req.Marshal(input); err != nil { - return - } - - var resp *client.Response - resp, err = req.Execute(ctx) - if resp != nil { - result.OData = resp.OData - result.HttpResponse = resp.Response - } - if err != nil { - return - } - - var model CheckNameAvailabilityResponse - result.Model = &model - if err = resp.Unmarshal(result.Model); err != nil { - return - } - - return -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_checknameavailabilitybyscope.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_checknameavailabilitybyscope.go deleted file mode 100644 index dcc90e23d360..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_checknameavailabilitybyscope.go +++ /dev/null @@ -1,59 +0,0 @@ -package scheduledactions - -import ( - "context" - "fmt" - "net/http" - - "github.com/hashicorp/go-azure-helpers/resourcemanager/commonids" - "github.com/hashicorp/go-azure-sdk/sdk/client" - "github.com/hashicorp/go-azure-sdk/sdk/odata" -) - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type CheckNameAvailabilityByScopeOperationResponse struct { - HttpResponse *http.Response - OData *odata.OData - Model *CheckNameAvailabilityResponse -} - -// CheckNameAvailabilityByScope ... -func (c ScheduledActionsClient) CheckNameAvailabilityByScope(ctx context.Context, id commonids.ScopeId, input CheckNameAvailabilityRequest) (result CheckNameAvailabilityByScopeOperationResponse, err error) { - opts := client.RequestOptions{ - ContentType: "application/json; charset=utf-8", - ExpectedStatusCodes: []int{ - http.StatusOK, - }, - HttpMethod: http.MethodPost, - Path: fmt.Sprintf("%s/providers/Microsoft.CostManagement/checkNameAvailability", id.ID()), - } - - req, err := c.Client.NewRequest(ctx, opts) - if err != nil { - return - } - - if err = req.Marshal(input); err != nil { - return - } - - var resp *client.Response - resp, err = req.Execute(ctx) - if resp != nil { - result.OData = resp.OData - result.HttpResponse = resp.Response - } - if err != nil { - return - } - - var model CheckNameAvailabilityResponse - result.Model = &model - if err = resp.Unmarshal(result.Model); err != nil { - return - } - - return -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_delete.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_delete.go deleted file mode 100644 index d5373537bd47..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_delete.go +++ /dev/null @@ -1,47 +0,0 @@ -package scheduledactions - -import ( - "context" - "net/http" - - "github.com/hashicorp/go-azure-sdk/sdk/client" - "github.com/hashicorp/go-azure-sdk/sdk/odata" -) - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type DeleteOperationResponse struct { - HttpResponse *http.Response - OData *odata.OData -} - -// Delete ... -func (c ScheduledActionsClient) Delete(ctx context.Context, id ScheduledActionId) (result DeleteOperationResponse, err error) { - opts := client.RequestOptions{ - ContentType: "application/json; charset=utf-8", - ExpectedStatusCodes: []int{ - http.StatusNoContent, - http.StatusOK, - }, - HttpMethod: http.MethodDelete, - Path: id.ID(), - } - - req, err := c.Client.NewRequest(ctx, opts) - if err != nil { - return - } - - var resp *client.Response - resp, err = req.Execute(ctx) - if resp != nil { - result.OData = resp.OData - result.HttpResponse = resp.Response - } - if err != nil { - return - } - - return -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_deletebyscope.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_deletebyscope.go deleted file mode 100644 index 62ddbed8c028..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_deletebyscope.go +++ /dev/null @@ -1,47 +0,0 @@ -package scheduledactions - -import ( - "context" - "net/http" - - "github.com/hashicorp/go-azure-sdk/sdk/client" - "github.com/hashicorp/go-azure-sdk/sdk/odata" -) - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type DeleteByScopeOperationResponse struct { - HttpResponse *http.Response - OData *odata.OData -} - -// DeleteByScope ... -func (c ScheduledActionsClient) DeleteByScope(ctx context.Context, id ScopedScheduledActionId) (result DeleteByScopeOperationResponse, err error) { - opts := client.RequestOptions{ - ContentType: "application/json; charset=utf-8", - ExpectedStatusCodes: []int{ - http.StatusNoContent, - http.StatusOK, - }, - HttpMethod: http.MethodDelete, - Path: id.ID(), - } - - req, err := c.Client.NewRequest(ctx, opts) - if err != nil { - return - } - - var resp *client.Response - resp, err = req.Execute(ctx) - if resp != nil { - result.OData = resp.OData - result.HttpResponse = resp.Response - } - if err != nil { - return - } - - return -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_get.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_get.go deleted file mode 100644 index 7d8f87f99ca7..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_get.go +++ /dev/null @@ -1,53 +0,0 @@ -package scheduledactions - -import ( - "context" - "net/http" - - "github.com/hashicorp/go-azure-sdk/sdk/client" - "github.com/hashicorp/go-azure-sdk/sdk/odata" -) - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type GetOperationResponse struct { - HttpResponse *http.Response - OData *odata.OData - Model *ScheduledAction -} - -// Get ... -func (c ScheduledActionsClient) Get(ctx context.Context, id ScheduledActionId) (result GetOperationResponse, err error) { - opts := client.RequestOptions{ - ContentType: "application/json; charset=utf-8", - ExpectedStatusCodes: []int{ - http.StatusOK, - }, - HttpMethod: http.MethodGet, - Path: id.ID(), - } - - req, err := c.Client.NewRequest(ctx, opts) - if err != nil { - return - } - - var resp *client.Response - resp, err = req.Execute(ctx) - if resp != nil { - result.OData = resp.OData - result.HttpResponse = resp.Response - } - if err != nil { - return - } - - var model ScheduledAction - result.Model = &model - if err = resp.Unmarshal(result.Model); err != nil { - return - } - - return -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_getbyscope.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_getbyscope.go deleted file mode 100644 index ddf1f0b66f2b..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_getbyscope.go +++ /dev/null @@ -1,53 +0,0 @@ -package scheduledactions - -import ( - "context" - "net/http" - - "github.com/hashicorp/go-azure-sdk/sdk/client" - "github.com/hashicorp/go-azure-sdk/sdk/odata" -) - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type GetByScopeOperationResponse struct { - HttpResponse *http.Response - OData *odata.OData - Model *ScheduledAction -} - -// GetByScope ... -func (c ScheduledActionsClient) GetByScope(ctx context.Context, id ScopedScheduledActionId) (result GetByScopeOperationResponse, err error) { - opts := client.RequestOptions{ - ContentType: "application/json; charset=utf-8", - ExpectedStatusCodes: []int{ - http.StatusOK, - }, - HttpMethod: http.MethodGet, - Path: id.ID(), - } - - req, err := c.Client.NewRequest(ctx, opts) - if err != nil { - return - } - - var resp *client.Response - resp, err = req.Execute(ctx) - if resp != nil { - result.OData = resp.OData - result.HttpResponse = resp.Response - } - if err != nil { - return - } - - var model ScheduledAction - result.Model = &model - if err = resp.Unmarshal(result.Model); err != nil { - return - } - - return -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_list.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_list.go deleted file mode 100644 index 00803631088b..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_list.go +++ /dev/null @@ -1,134 +0,0 @@ -package scheduledactions - -import ( - "context" - "fmt" - "net/http" - - "github.com/hashicorp/go-azure-sdk/sdk/client" - "github.com/hashicorp/go-azure-sdk/sdk/odata" -) - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type ListOperationResponse struct { - HttpResponse *http.Response - OData *odata.OData - Model *[]ScheduledAction -} - -type ListCompleteResult struct { - LatestHttpResponse *http.Response - Items []ScheduledAction -} - -type ListOperationOptions struct { - Filter *string -} - -func DefaultListOperationOptions() ListOperationOptions { - return ListOperationOptions{} -} - -func (o ListOperationOptions) ToHeaders() *client.Headers { - out := client.Headers{} - - return &out -} - -func (o ListOperationOptions) ToOData() *odata.Query { - out := odata.Query{} - - return &out -} - -func (o ListOperationOptions) ToQuery() *client.QueryParams { - out := client.QueryParams{} - if o.Filter != nil { - out.Append("$filter", fmt.Sprintf("%v", *o.Filter)) - } - return &out -} - -type ListCustomPager struct { - NextLink *odata.Link `json:"nextLink"` -} - -func (p *ListCustomPager) NextPageLink() *odata.Link { - defer func() { - p.NextLink = nil - }() - - return p.NextLink -} - -// List ... -func (c ScheduledActionsClient) List(ctx context.Context, options ListOperationOptions) (result ListOperationResponse, err error) { - opts := client.RequestOptions{ - ContentType: "application/json; charset=utf-8", - ExpectedStatusCodes: []int{ - http.StatusOK, - }, - HttpMethod: http.MethodGet, - OptionsObject: options, - Pager: &ListCustomPager{}, - Path: "/providers/Microsoft.CostManagement/scheduledActions", - } - - req, err := c.Client.NewRequest(ctx, opts) - if err != nil { - return - } - - var resp *client.Response - resp, err = req.ExecutePaged(ctx) - if resp != nil { - result.OData = resp.OData - result.HttpResponse = resp.Response - } - if err != nil { - return - } - - var values struct { - Values *[]ScheduledAction `json:"value"` - } - if err = resp.Unmarshal(&values); err != nil { - return - } - - result.Model = values.Values - - return -} - -// ListComplete retrieves all the results into a single object -func (c ScheduledActionsClient) ListComplete(ctx context.Context, options ListOperationOptions) (ListCompleteResult, error) { - return c.ListCompleteMatchingPredicate(ctx, options, ScheduledActionOperationPredicate{}) -} - -// ListCompleteMatchingPredicate retrieves all the results and then applies the predicate -func (c ScheduledActionsClient) ListCompleteMatchingPredicate(ctx context.Context, options ListOperationOptions, predicate ScheduledActionOperationPredicate) (result ListCompleteResult, err error) { - items := make([]ScheduledAction, 0) - - resp, err := c.List(ctx, options) - if err != nil { - result.LatestHttpResponse = resp.HttpResponse - err = fmt.Errorf("loading results: %+v", err) - return - } - if resp.Model != nil { - for _, v := range *resp.Model { - if predicate.Matches(v) { - items = append(items, v) - } - } - } - - result = ListCompleteResult{ - LatestHttpResponse: resp.HttpResponse, - Items: items, - } - return -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_listbyscope.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_listbyscope.go deleted file mode 100644 index a2f826572708..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_listbyscope.go +++ /dev/null @@ -1,135 +0,0 @@ -package scheduledactions - -import ( - "context" - "fmt" - "net/http" - - "github.com/hashicorp/go-azure-helpers/resourcemanager/commonids" - "github.com/hashicorp/go-azure-sdk/sdk/client" - "github.com/hashicorp/go-azure-sdk/sdk/odata" -) - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type ListByScopeOperationResponse struct { - HttpResponse *http.Response - OData *odata.OData - Model *[]ScheduledAction -} - -type ListByScopeCompleteResult struct { - LatestHttpResponse *http.Response - Items []ScheduledAction -} - -type ListByScopeOperationOptions struct { - Filter *string -} - -func DefaultListByScopeOperationOptions() ListByScopeOperationOptions { - return ListByScopeOperationOptions{} -} - -func (o ListByScopeOperationOptions) ToHeaders() *client.Headers { - out := client.Headers{} - - return &out -} - -func (o ListByScopeOperationOptions) ToOData() *odata.Query { - out := odata.Query{} - - return &out -} - -func (o ListByScopeOperationOptions) ToQuery() *client.QueryParams { - out := client.QueryParams{} - if o.Filter != nil { - out.Append("$filter", fmt.Sprintf("%v", *o.Filter)) - } - return &out -} - -type ListByScopeCustomPager struct { - NextLink *odata.Link `json:"nextLink"` -} - -func (p *ListByScopeCustomPager) NextPageLink() *odata.Link { - defer func() { - p.NextLink = nil - }() - - return p.NextLink -} - -// ListByScope ... -func (c ScheduledActionsClient) ListByScope(ctx context.Context, id commonids.ScopeId, options ListByScopeOperationOptions) (result ListByScopeOperationResponse, err error) { - opts := client.RequestOptions{ - ContentType: "application/json; charset=utf-8", - ExpectedStatusCodes: []int{ - http.StatusOK, - }, - HttpMethod: http.MethodGet, - OptionsObject: options, - Pager: &ListByScopeCustomPager{}, - Path: fmt.Sprintf("%s/providers/Microsoft.CostManagement/scheduledActions", id.ID()), - } - - req, err := c.Client.NewRequest(ctx, opts) - if err != nil { - return - } - - var resp *client.Response - resp, err = req.ExecutePaged(ctx) - if resp != nil { - result.OData = resp.OData - result.HttpResponse = resp.Response - } - if err != nil { - return - } - - var values struct { - Values *[]ScheduledAction `json:"value"` - } - if err = resp.Unmarshal(&values); err != nil { - return - } - - result.Model = values.Values - - return -} - -// ListByScopeComplete retrieves all the results into a single object -func (c ScheduledActionsClient) ListByScopeComplete(ctx context.Context, id commonids.ScopeId, options ListByScopeOperationOptions) (ListByScopeCompleteResult, error) { - return c.ListByScopeCompleteMatchingPredicate(ctx, id, options, ScheduledActionOperationPredicate{}) -} - -// ListByScopeCompleteMatchingPredicate retrieves all the results and then applies the predicate -func (c ScheduledActionsClient) ListByScopeCompleteMatchingPredicate(ctx context.Context, id commonids.ScopeId, options ListByScopeOperationOptions, predicate ScheduledActionOperationPredicate) (result ListByScopeCompleteResult, err error) { - items := make([]ScheduledAction, 0) - - resp, err := c.ListByScope(ctx, id, options) - if err != nil { - result.LatestHttpResponse = resp.HttpResponse - err = fmt.Errorf("loading results: %+v", err) - return - } - if resp.Model != nil { - for _, v := range *resp.Model { - if predicate.Matches(v) { - items = append(items, v) - } - } - } - - result = ListByScopeCompleteResult{ - LatestHttpResponse: resp.HttpResponse, - Items: items, - } - return -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/model_checknameavailabilityrequest.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/model_checknameavailabilityrequest.go deleted file mode 100644 index 2c2eeed8fb06..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/model_checknameavailabilityrequest.go +++ /dev/null @@ -1,9 +0,0 @@ -package scheduledactions - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type CheckNameAvailabilityRequest struct { - Name *string `json:"name,omitempty"` - Type *string `json:"type,omitempty"` -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/model_checknameavailabilityresponse.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/model_checknameavailabilityresponse.go deleted file mode 100644 index 9cf3c0cf44af..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/model_checknameavailabilityresponse.go +++ /dev/null @@ -1,10 +0,0 @@ -package scheduledactions - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type CheckNameAvailabilityResponse struct { - Message *string `json:"message,omitempty"` - NameAvailable *bool `json:"nameAvailable,omitempty"` - Reason *CheckNameAvailabilityReason `json:"reason,omitempty"` -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/model_filedestination.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/model_filedestination.go deleted file mode 100644 index 8691cf8ce3e9..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/model_filedestination.go +++ /dev/null @@ -1,8 +0,0 @@ -package scheduledactions - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type FileDestination struct { - FileFormats *[]FileFormat `json:"fileFormats,omitempty"` -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/model_scheduledaction.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/model_scheduledaction.go deleted file mode 100644 index ecb01cdf187f..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/model_scheduledaction.go +++ /dev/null @@ -1,18 +0,0 @@ -package scheduledactions - -import ( - "github.com/hashicorp/go-azure-helpers/resourcemanager/systemdata" -) - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type ScheduledAction struct { - ETag *string `json:"eTag,omitempty"` - Id *string `json:"id,omitempty"` - Kind *ScheduledActionKind `json:"kind,omitempty"` - Name *string `json:"name,omitempty"` - Properties *ScheduledActionProperties `json:"properties,omitempty"` - SystemData *systemdata.SystemData `json:"systemData,omitempty"` - Type *string `json:"type,omitempty"` -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/model_scheduleproperties.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/model_scheduleproperties.go deleted file mode 100644 index 081153c4cede..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/model_scheduleproperties.go +++ /dev/null @@ -1,38 +0,0 @@ -package scheduledactions - -import ( - "time" - - "github.com/hashicorp/go-azure-helpers/lang/dates" -) - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type ScheduleProperties struct { - DayOfMonth *int64 `json:"dayOfMonth,omitempty"` - DaysOfWeek *[]DaysOfWeek `json:"daysOfWeek,omitempty"` - EndDate string `json:"endDate"` - Frequency ScheduleFrequency `json:"frequency"` - HourOfDay *int64 `json:"hourOfDay,omitempty"` - StartDate string `json:"startDate"` - WeeksOfMonth *[]WeeksOfMonth `json:"weeksOfMonth,omitempty"` -} - -func (o *ScheduleProperties) GetEndDateAsTime() (*time.Time, error) { - return dates.ParseAsFormat(&o.EndDate, "2006-01-02T15:04:05Z07:00") -} - -func (o *ScheduleProperties) SetEndDateAsTime(input time.Time) { - formatted := input.Format("2006-01-02T15:04:05Z07:00") - o.EndDate = formatted -} - -func (o *ScheduleProperties) GetStartDateAsTime() (*time.Time, error) { - return dates.ParseAsFormat(&o.StartDate, "2006-01-02T15:04:05Z07:00") -} - -func (o *ScheduleProperties) SetStartDateAsTime(input time.Time) { - formatted := input.Format("2006-01-02T15:04:05Z07:00") - o.StartDate = formatted -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/predicates.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/predicates.go deleted file mode 100644 index 52f4f396ca38..000000000000 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/predicates.go +++ /dev/null @@ -1,32 +0,0 @@ -package scheduledactions - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See NOTICE.txt in the project root for license information. - -type ScheduledActionOperationPredicate struct { - ETag *string - Id *string - Name *string - Type *string -} - -func (p ScheduledActionOperationPredicate) Matches(input ScheduledAction) bool { - - if p.ETag != nil && (input.ETag == nil || *p.ETag != *input.ETag) { - return false - } - - if p.Id != nil && (input.Id == nil || *p.Id != *input.Id) { - return false - } - - if p.Name != nil && (input.Name == nil || *p.Name != *input.Name) { - return false - } - - if p.Type != nil && (input.Type == nil || *p.Type != *input.Type) { - return false - } - - return true -} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/README.md b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/README.md similarity index 96% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/README.md rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/README.md index 43eddbb03bc5..16a0b7cf61cb 100644 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/README.md +++ b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/README.md @@ -1,7 +1,7 @@ -## `github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports` Documentation +## `github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports` Documentation -The `exports` SDK allows for interaction with Azure Resource Manager `costmanagement` (API Version `2021-10-01`). +The `exports` SDK allows for interaction with Azure Resource Manager `costmanagement` (API Version `2023-08-01`). This readme covers example usages, but further information on [using this SDK can be found in the project root](https://github.com/hashicorp/go-azure-sdk/tree/main/docs). @@ -9,7 +9,7 @@ This readme covers example usages, but further information on [using this SDK ca ```go import "github.com/hashicorp/go-azure-helpers/resourcemanager/commonids" -import "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports" +import "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports" ``` diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/client.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/client.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/client.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/client.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/constants.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/constants.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/constants.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/constants.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/id_scopedexport.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/id_scopedexport.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/id_scopedexport.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/id_scopedexport.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/method_createorupdate.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/method_createorupdate.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/method_createorupdate.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/method_createorupdate.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/method_delete.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/method_delete.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/method_delete.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/method_delete.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/method_execute.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/method_execute.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/method_execute.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/method_execute.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/method_get.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/method_get.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/method_get.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/method_get.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/method_getexecutionhistory.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/method_getexecutionhistory.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/method_getexecutionhistory.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/method_getexecutionhistory.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/method_list.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/method_list.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/method_list.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/method_list.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_commonexportproperties.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_commonexportproperties.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_commonexportproperties.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_commonexportproperties.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_errordetails.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_errordetails.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_errordetails.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_errordetails.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_export.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_export.go new file mode 100644 index 000000000000..0ee2528d8d78 --- /dev/null +++ b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_export.go @@ -0,0 +1,18 @@ +package exports + +import ( + "github.com/hashicorp/go-azure-helpers/resourcemanager/identity" +) + +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. See NOTICE.txt in the project root for license information. + +type Export struct { + ETag *string `json:"eTag,omitempty"` + Id *string `json:"id,omitempty"` + Identity *identity.SystemAssigned `json:"identity,omitempty"` + Location *string `json:"location,omitempty"` + Name *string `json:"name,omitempty"` + Properties *ExportProperties `json:"properties,omitempty"` + Type *string `json:"type,omitempty"` +} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportdataset.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportdataset.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportdataset.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportdataset.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportdatasetconfiguration.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportdatasetconfiguration.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportdatasetconfiguration.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportdatasetconfiguration.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportdefinition.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportdefinition.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportdefinition.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportdefinition.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportdeliverydestination.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportdeliverydestination.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportdeliverydestination.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportdeliverydestination.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportdeliveryinfo.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportdeliveryinfo.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportdeliveryinfo.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportdeliveryinfo.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportexecutionlistresult.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportexecutionlistresult.go similarity index 80% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportexecutionlistresult.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportexecutionlistresult.go index a07b784ea303..b8e5c8761976 100644 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportexecutionlistresult.go +++ b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportexecutionlistresult.go @@ -4,5 +4,5 @@ package exports // Licensed under the MIT License. See NOTICE.txt in the project root for license information. type ExportExecutionListResult struct { - Value *[]ExportExecution `json:"value,omitempty"` + Value *[]ExportRun `json:"value,omitempty"` } diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportlistresult.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportlistresult.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportlistresult.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportlistresult.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportproperties.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportproperties.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportproperties.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportproperties.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportrecurrenceperiod.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportrecurrenceperiod.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportrecurrenceperiod.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportrecurrenceperiod.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportrun.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportrun.go new file mode 100644 index 000000000000..24fffaa768e5 --- /dev/null +++ b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportrun.go @@ -0,0 +1,12 @@ +package exports + +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. See NOTICE.txt in the project root for license information. + +type ExportRun struct { + ETag *string `json:"eTag,omitempty"` + Id *string `json:"id,omitempty"` + Name *string `json:"name,omitempty"` + Properties *ExportRunProperties `json:"properties,omitempty"` + Type *string `json:"type,omitempty"` +} diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportexecutionproperties.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportrunproperties.go similarity index 76% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportexecutionproperties.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportrunproperties.go index c29e900fc3dc..17b2f0d9d782 100644 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportexecutionproperties.go +++ b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportrunproperties.go @@ -9,7 +9,7 @@ import ( // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. See NOTICE.txt in the project root for license information. -type ExportExecutionProperties struct { +type ExportRunProperties struct { Error *ErrorDetails `json:"error,omitempty"` ExecutionType *ExecutionType `json:"executionType,omitempty"` FileName *string `json:"fileName,omitempty"` @@ -21,38 +21,38 @@ type ExportExecutionProperties struct { SubmittedTime *string `json:"submittedTime,omitempty"` } -func (o *ExportExecutionProperties) GetProcessingEndTimeAsTime() (*time.Time, error) { +func (o *ExportRunProperties) GetProcessingEndTimeAsTime() (*time.Time, error) { if o.ProcessingEndTime == nil { return nil, nil } return dates.ParseAsFormat(o.ProcessingEndTime, "2006-01-02T15:04:05Z07:00") } -func (o *ExportExecutionProperties) SetProcessingEndTimeAsTime(input time.Time) { +func (o *ExportRunProperties) SetProcessingEndTimeAsTime(input time.Time) { formatted := input.Format("2006-01-02T15:04:05Z07:00") o.ProcessingEndTime = &formatted } -func (o *ExportExecutionProperties) GetProcessingStartTimeAsTime() (*time.Time, error) { +func (o *ExportRunProperties) GetProcessingStartTimeAsTime() (*time.Time, error) { if o.ProcessingStartTime == nil { return nil, nil } return dates.ParseAsFormat(o.ProcessingStartTime, "2006-01-02T15:04:05Z07:00") } -func (o *ExportExecutionProperties) SetProcessingStartTimeAsTime(input time.Time) { +func (o *ExportRunProperties) SetProcessingStartTimeAsTime(input time.Time) { formatted := input.Format("2006-01-02T15:04:05Z07:00") o.ProcessingStartTime = &formatted } -func (o *ExportExecutionProperties) GetSubmittedTimeAsTime() (*time.Time, error) { +func (o *ExportRunProperties) GetSubmittedTimeAsTime() (*time.Time, error) { if o.SubmittedTime == nil { return nil, nil } return dates.ParseAsFormat(o.SubmittedTime, "2006-01-02T15:04:05Z07:00") } -func (o *ExportExecutionProperties) SetSubmittedTimeAsTime(input time.Time) { +func (o *ExportRunProperties) SetSubmittedTimeAsTime(input time.Time) { formatted := input.Format("2006-01-02T15:04:05Z07:00") o.SubmittedTime = &formatted } diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportschedule.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportschedule.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exportschedule.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exportschedule.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exporttimeperiod.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exporttimeperiod.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/model_exporttimeperiod.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/model_exporttimeperiod.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/version.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/version.go similarity index 69% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/version.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/version.go index 5f1858d26b46..b0b4809e1a77 100644 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports/version.go +++ b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports/version.go @@ -3,8 +3,8 @@ package exports // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. See NOTICE.txt in the project root for license information. -const defaultApiVersion = "2021-10-01" +const defaultApiVersion = "2023-08-01" func userAgent() string { - return "hashicorp/go-azure-sdk/exports/2021-10-01" + return "hashicorp/go-azure-sdk/exports/2023-08-01" } diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/README.md b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/README.md similarity index 97% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/README.md rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/README.md index 24ff0eb98943..bb3b04370869 100644 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/README.md +++ b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/README.md @@ -1,7 +1,7 @@ -## `github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions` Documentation +## `github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions` Documentation -The `scheduledactions` SDK allows for interaction with Azure Resource Manager `costmanagement` (API Version `2022-10-01`). +The `scheduledactions` SDK allows for interaction with Azure Resource Manager `costmanagement` (API Version `2023-08-01`). This readme covers example usages, but further information on [using this SDK can be found in the project root](https://github.com/hashicorp/go-azure-sdk/tree/main/docs). @@ -9,7 +9,7 @@ This readme covers example usages, but further information on [using this SDK ca ```go import "github.com/hashicorp/go-azure-helpers/resourcemanager/commonids" -import "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions" +import "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions" ``` diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/client.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/client.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/client.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/client.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/constants.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/constants.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/constants.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/constants.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/id_scheduledaction.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/id_scheduledaction.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/id_scheduledaction.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/id_scheduledaction.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/id_scopedscheduledaction.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/id_scopedscheduledaction.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/id_scopedscheduledaction.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/id_scopedscheduledaction.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_checknameavailability.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/method_checknameavailability.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_checknameavailability.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/method_checknameavailability.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_checknameavailabilitybyscope.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/method_checknameavailabilitybyscope.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_checknameavailabilitybyscope.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/method_checknameavailabilitybyscope.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_createorupdate.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/method_createorupdate.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_createorupdate.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/method_createorupdate.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_createorupdatebyscope.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/method_createorupdatebyscope.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_createorupdatebyscope.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/method_createorupdatebyscope.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_delete.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/method_delete.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_delete.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/method_delete.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_deletebyscope.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/method_deletebyscope.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_deletebyscope.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/method_deletebyscope.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_get.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/method_get.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_get.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/method_get.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_getbyscope.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/method_getbyscope.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_getbyscope.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/method_getbyscope.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_list.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/method_list.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_list.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/method_list.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_listbyscope.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/method_listbyscope.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/method_listbyscope.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/method_listbyscope.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_run.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/method_run.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_run.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/method_run.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_runbyscope.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/method_runbyscope.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/method_runbyscope.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/method_runbyscope.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/model_checknameavailabilityrequest.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/model_checknameavailabilityrequest.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/model_checknameavailabilityrequest.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/model_checknameavailabilityrequest.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/model_checknameavailabilityresponse.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/model_checknameavailabilityresponse.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/model_checknameavailabilityresponse.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/model_checknameavailabilityresponse.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/model_filedestination.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/model_filedestination.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/model_filedestination.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/model_filedestination.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/model_notificationproperties.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/model_notificationproperties.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/model_notificationproperties.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/model_notificationproperties.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/model_scheduledaction.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/model_scheduledaction.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/model_scheduledaction.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/model_scheduledaction.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/model_scheduledactionproperties.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/model_scheduledactionproperties.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/model_scheduledactionproperties.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/model_scheduledactionproperties.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/model_scheduleproperties.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/model_scheduleproperties.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/model_scheduleproperties.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/model_scheduleproperties.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/predicates.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/predicates.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions/predicates.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/predicates.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/version.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/version.go similarity index 67% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/version.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/version.go index ff0bf6bd4389..07b4a28716ff 100644 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions/version.go +++ b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions/version.go @@ -3,8 +3,8 @@ package scheduledactions // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. See NOTICE.txt in the project root for license information. -const defaultApiVersion = "2022-10-01" +const defaultApiVersion = "2023-08-01" func userAgent() string { - return "hashicorp/go-azure-sdk/scheduledactions/2022-10-01" + return "hashicorp/go-azure-sdk/scheduledactions/2023-08-01" } diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/README.md b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/README.md similarity index 96% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/README.md rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/README.md index 383cc0bc60c4..2a9ae8a1eaa5 100644 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/README.md +++ b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/README.md @@ -1,7 +1,7 @@ -## `github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views` Documentation +## `github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views` Documentation -The `views` SDK allows for interaction with Azure Resource Manager `costmanagement` (API Version `2022-10-01`). +The `views` SDK allows for interaction with Azure Resource Manager `costmanagement` (API Version `2023-08-01`). This readme covers example usages, but further information on [using this SDK can be found in the project root](https://github.com/hashicorp/go-azure-sdk/tree/main/docs). @@ -9,7 +9,7 @@ This readme covers example usages, but further information on [using this SDK ca ```go import "github.com/hashicorp/go-azure-helpers/resourcemanager/commonids" -import "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views" +import "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views" ``` diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/client.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/client.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/client.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/client.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/constants.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/constants.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/constants.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/constants.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/id_scopedview.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/id_scopedview.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/id_scopedview.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/id_scopedview.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/id_view.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/id_view.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/id_view.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/id_view.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/method_createorupdate.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/method_createorupdate.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/method_createorupdate.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/method_createorupdate.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/method_createorupdatebyscope.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/method_createorupdatebyscope.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/method_createorupdatebyscope.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/method_createorupdatebyscope.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/method_delete.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/method_delete.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/method_delete.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/method_delete.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/method_deletebyscope.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/method_deletebyscope.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/method_deletebyscope.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/method_deletebyscope.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/method_get.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/method_get.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/method_get.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/method_get.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/method_getbyscope.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/method_getbyscope.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/method_getbyscope.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/method_getbyscope.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/method_list.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/method_list.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/method_list.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/method_list.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/method_listbyscope.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/method_listbyscope.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/method_listbyscope.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/method_listbyscope.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_kpiproperties.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_kpiproperties.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_kpiproperties.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_kpiproperties.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_pivotproperties.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_pivotproperties.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_pivotproperties.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_pivotproperties.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_reportconfigaggregation.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_reportconfigaggregation.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_reportconfigaggregation.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_reportconfigaggregation.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_reportconfigcomparisonexpression.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_reportconfigcomparisonexpression.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_reportconfigcomparisonexpression.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_reportconfigcomparisonexpression.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_reportconfigdataset.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_reportconfigdataset.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_reportconfigdataset.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_reportconfigdataset.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_reportconfigdatasetconfiguration.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_reportconfigdatasetconfiguration.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_reportconfigdatasetconfiguration.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_reportconfigdatasetconfiguration.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_reportconfigdefinition.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_reportconfigdefinition.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_reportconfigdefinition.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_reportconfigdefinition.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_reportconfigfilter.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_reportconfigfilter.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_reportconfigfilter.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_reportconfigfilter.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_reportconfiggrouping.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_reportconfiggrouping.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_reportconfiggrouping.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_reportconfiggrouping.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_reportconfigsorting.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_reportconfigsorting.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_reportconfigsorting.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_reportconfigsorting.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_reportconfigtimeperiod.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_reportconfigtimeperiod.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_reportconfigtimeperiod.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_reportconfigtimeperiod.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_view.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_view.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_view.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_view.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_viewproperties.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_viewproperties.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/model_viewproperties.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/model_viewproperties.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/predicates.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/predicates.go similarity index 100% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/predicates.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/predicates.go diff --git a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/version.go b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/version.go similarity index 69% rename from vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/version.go rename to vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/version.go index 40d34f474ed5..5f32c84e2628 100644 --- a/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views/version.go +++ b/vendor/github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views/version.go @@ -3,8 +3,8 @@ package views // Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. See NOTICE.txt in the project root for license information. -const defaultApiVersion = "2022-10-01" +const defaultApiVersion = "2023-08-01" func userAgent() string { - return "hashicorp/go-azure-sdk/views/2022-10-01" + return "hashicorp/go-azure-sdk/views/2023-08-01" } diff --git a/vendor/modules.txt b/vendor/modules.txt index efd7b013efda..f2fe86c55884 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -410,10 +410,9 @@ github.com/hashicorp/go-azure-sdk/resource-manager/cosmosdb/2022-05-15/sqldedica github.com/hashicorp/go-azure-sdk/resource-manager/cosmosdb/2022-11-15/mongorbacs github.com/hashicorp/go-azure-sdk/resource-manager/cosmosdb/2023-04-15/managedcassandras github.com/hashicorp/go-azure-sdk/resource-manager/cosmosdb/2024-05-15/cosmosdb -github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2021-10-01/exports -github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-06-01-preview/scheduledactions -github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/scheduledactions -github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2022-10-01/views +github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/exports +github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/scheduledactions +github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/views github.com/hashicorp/go-azure-sdk/resource-manager/customproviders/2018-09-01-preview/customresourceprovider github.com/hashicorp/go-azure-sdk/resource-manager/dashboard/2023-09-01/grafanaresource github.com/hashicorp/go-azure-sdk/resource-manager/databoxedge/2022-03-01/devices From aff8e0d7d583230bb923152973dbd0ed4c8a083e Mon Sep 17 00:00:00 2001 From: Sebastian Heid <8442432+s4heid@users.noreply.github.com> Date: Wed, 6 Nov 2024 18:28:42 +0100 Subject: [PATCH 3/5] Rename `email_address_sender` to `notification_email` --- .../services/costmanagement/anomaly_alert_resource.go | 8 ++++---- .../costmanagement/anomaly_alert_resource_test.go | 6 +++--- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/internal/services/costmanagement/anomaly_alert_resource.go b/internal/services/costmanagement/anomaly_alert_resource.go index 90513150b0ab..a5f651e9ff01 100644 --- a/internal/services/costmanagement/anomaly_alert_resource.go +++ b/internal/services/costmanagement/anomaly_alert_resource.go @@ -48,7 +48,7 @@ func (AnomalyAlertResource) Arguments() map[string]*pluginsdk.Schema { ValidateFunc: commonids.ValidateSubscriptionID, }, - "email_address_sender": { + "notification_email": { Type: pluginsdk.TypeString, Optional: true, Computed: true, @@ -125,7 +125,7 @@ func (r AnomalyAlertResource) Create() sdk.ResourceFunc { schedule.SetStartDateAsTime(time.Now()) var senderEmail string - if v, ok := metadata.ResourceData.GetOk("email_address_sender"); ok { + if v, ok := metadata.ResourceData.GetOk("notification_email"); ok { senderEmail = v.(string) } else { senderEmail = (*emailAddresses)[0] @@ -199,7 +199,7 @@ func (r AnomalyAlertResource) Update() sdk.ResourceFunc { schedule.SetStartDateAsTime(time.Now()) var senderEmail string - if v, ok := metadata.ResourceData.GetOk("email_address_sender"); ok { + if v, ok := metadata.ResourceData.GetOk("notification_email"); ok { senderEmail = v.(string) } else { senderEmail = (*emailAddresses)[0] @@ -257,7 +257,7 @@ func (AnomalyAlertResource) Read() sdk.ResourceFunc { metadata.ResourceData.Set("display_name", props.DisplayName) metadata.ResourceData.Set("subscription_id", fmt.Sprint("/", *props.Scope)) metadata.ResourceData.Set("email_subject", props.Notification.Subject) - metadata.ResourceData.Set("email_address_sender", props.NotificationEmail) + metadata.ResourceData.Set("notification_email", props.NotificationEmail) metadata.ResourceData.Set("email_addresses", props.Notification.To) metadata.ResourceData.Set("message", props.Notification.Message) } diff --git a/internal/services/costmanagement/anomaly_alert_resource_test.go b/internal/services/costmanagement/anomaly_alert_resource_test.go index 974ed96ba32a..fd294f6d5ea5 100644 --- a/internal/services/costmanagement/anomaly_alert_resource_test.go +++ b/internal/services/costmanagement/anomaly_alert_resource_test.go @@ -54,7 +54,7 @@ func TestAccResourceAnomalyAlert_emailAddressSender(t *testing.T) { data := acceptance.BuildTestData(t, "azurerm_cost_anomaly_alert", "test") testResource := AnomalyAlertResource{} data.ResourceTest(t, testResource, []acceptance.TestStep{ - data.ApplyStep(testResource.emailAddressSenderConfig, testResource), + data.ApplyStep(testResource.notificationEmailConfig, testResource), data.ImportStep(), data.ApplyStep(testResource.updateConfig, testResource), data.ImportStep(), @@ -141,7 +141,7 @@ resource "azurerm_cost_anomaly_alert" "test" { `, data.RandomInteger, data.RandomInteger) } -func (AnomalyAlertResource) emailAddressSenderConfig(data acceptance.TestData) string { +func (AnomalyAlertResource) notificationEmailConfig(data acceptance.TestData) string { return fmt.Sprintf(` provider "azurerm" { features {} @@ -152,7 +152,7 @@ resource "azurerm_cost_anomaly_alert" "test" { display_name = "acctest %d" email_subject = "Hi" email_addresses = ["test@test.com", "test@hashicorp.developer"] - email_address_sender = "othertest@hashicorp.developer" + notification_email = "othertest@hashicorp.developer" message = "Custom sender email configured" } `, data.RandomInteger, data.RandomInteger) From 74a1327af9aff35b07b86ec3af50c8aa2d0a1074 Mon Sep 17 00:00:00 2001 From: Sebastian Heid <8442432+s4heid@users.noreply.github.com> Date: Wed, 6 Nov 2024 18:44:17 +0100 Subject: [PATCH 4/5] Update the cost anomaly docs with new parameter --- website/docs/r/cost_anomaly_alert.html.markdown | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/website/docs/r/cost_anomaly_alert.html.markdown b/website/docs/r/cost_anomaly_alert.html.markdown index 2ae36b1f3d82..ae285d4d2cf1 100644 --- a/website/docs/r/cost_anomaly_alert.html.markdown +++ b/website/docs/r/cost_anomaly_alert.html.markdown @@ -38,7 +38,7 @@ The following arguments are supported: * `email_subject` - (Required) The email subject of the Cost Anomaly Alerts. Maximum length of the subject is 70. - +* `notification_email` - (Optional) The email address of the point of contact that should get the unsubscribe requests and notification emails. --- From 545b72040bebe87c531a70137e8f1e774606fb68 Mon Sep 17 00:00:00 2001 From: Sebastian Heid <8442432+s4heid@users.noreply.github.com> Date: Fri, 6 Dec 2024 08:42:00 +0100 Subject: [PATCH 5/5] Apply make terrafmt --- .../costmanagement/anomaly_alert_resource_test.go | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/internal/services/costmanagement/anomaly_alert_resource_test.go b/internal/services/costmanagement/anomaly_alert_resource_test.go index fd294f6d5ea5..fdc6a2f09ddd 100644 --- a/internal/services/costmanagement/anomaly_alert_resource_test.go +++ b/internal/services/costmanagement/anomaly_alert_resource_test.go @@ -148,12 +148,12 @@ provider "azurerm" { } resource "azurerm_cost_anomaly_alert" "test" { - name = "-acctest-%d" - display_name = "acctest %d" - email_subject = "Hi" - email_addresses = ["test@test.com", "test@hashicorp.developer"] - notification_email = "othertest@hashicorp.developer" - message = "Custom sender email configured" + name = "-acctest-%d" + display_name = "acctest %d" + email_subject = "Hi" + email_addresses = ["test@test.com", "test@hashicorp.developer"] + notification_email = "othertest@hashicorp.developer" + message = "Custom sender email configured" } `, data.RandomInteger, data.RandomInteger) }