From 9a0faa5ff6322d3d27f0adca53aabc9a21605f4b Mon Sep 17 00:00:00 2001 From: andrewsy-opal Date: Thu, 30 May 2024 16:24:41 -0400 Subject: [PATCH] Update speakeasy --- .speakeasy/gen.lock | 10 +++++----- .speakeasy/workflow.lock | 11 +++++------ README.md | 2 +- docs/index.md | 2 +- examples/provider/provider.tf | 2 +- gen.yaml | 2 +- go.mod | 2 +- internal/provider/apps_data_source_sdk.go | 1 + .../configurationtemplatelist_data_source_sdk.go | 1 + internal/provider/events_data_source_sdk.go | 2 ++ internal/provider/group_data_source_sdk.go | 3 +++ internal/provider/group_list_data_source_sdk.go | 3 +++ internal/provider/group_resource_sdk.go | 5 +++++ .../provider/groupresourcelist_data_source_sdk.go | 1 + internal/provider/groupresourcelist_resource_sdk.go | 1 + .../groupreviewersstageslist_data_source_sdk.go | 1 + internal/provider/grouptags_data_source_sdk.go | 1 + internal/provider/groupusers_data_source_sdk.go | 1 + .../provider/messagechannellist_data_source_sdk.go | 1 + .../provider/oncallschedule_list_data_source_sdk.go | 1 + internal/provider/owners_data_source_sdk.go | 1 + internal/provider/requests_data_source_sdk.go | 3 +++ internal/provider/resource_data_source_sdk.go | 2 ++ internal/provider/resource_resource_sdk.go | 4 ++++ .../resourcemessagechannellist_data_source_sdk.go | 1 + internal/provider/resources_list_data_source_sdk.go | 3 +++ .../provider/resourcesusers_list_data_source_sdk.go | 1 + internal/provider/resourcetags_data_source_sdk.go | 1 + internal/provider/sessions_data_source_sdk.go | 1 + internal/provider/tags_list_data_source_sdk.go | 1 + internal/provider/uar_data_source_sdk.go | 1 + internal/provider/uars_list_data_source_sdk.go | 2 ++ internal/provider/users_data_source_sdk.go | 1 + internal/provider/usertags_data_source_sdk.go | 1 + internal/sdk/opalapi.go | 4 ++-- 35 files changed, 62 insertions(+), 18 deletions(-) diff --git a/.speakeasy/gen.lock b/.speakeasy/gen.lock index eb085b8a..de382417 100755 --- a/.speakeasy/gen.lock +++ b/.speakeasy/gen.lock @@ -3,10 +3,10 @@ id: b5c8bf75-06e1-47c8-b9ae-ce49ba56069d management: docChecksum: e3cb6b93e32e12628dfa380bb884b5bb docVersion: "1.0" - speakeasyVersion: 1.295.2 - generationVersion: 2.335.5 - releaseVersion: 0.20.3 - configChecksum: d97df565a07f4d28a63e894c68a76bc0 + speakeasyVersion: 1.299.3 + generationVersion: 2.338.7 + releaseVersion: 0.20.4 + configChecksum: dc89fa21ba32dd1e7400e48db61f033a repoURL: https://github.com/opalsecurity/terraform-provider-opal.git repoSubDirectory: . published: true @@ -15,7 +15,7 @@ features: additionalDependencies: 0.1.0 additionalProperties: 0.1.2 constsAndDefaults: 0.1.4 - core: 3.21.0 + core: 3.21.1 deprecations: 2.81.1 globalSecurity: 2.81.6 globalServerURLs: 2.82.1 diff --git a/.speakeasy/workflow.lock b/.speakeasy/workflow.lock index dc524c15..060e01c7 100644 --- a/.speakeasy/workflow.lock +++ b/.speakeasy/workflow.lock @@ -1,18 +1,17 @@ -speakeasyVersion: 1.295.2 +speakeasyVersion: 1.299.3 sources: opal-terraform-provider: sourceNamespace: opal-terraform-provider - sourceRevisionDigest: sha256:4607aac498872df8ebaeafe6a96cd40a30fbb6fa4ca216953db3f9eec7309867 - sourceBlobDigest: sha256:1d6d2919b0f91c1722050a4f6ea1cc45f356a51fec3ac8b6167fa963d59e6080 + sourceRevisionDigest: sha256:797f36bf99bd287ba390531ea15490eabd31f8f0b5a894e51e401e60b13bdff3 + sourceBlobDigest: sha256:b5a9fb0beae696e9ed9f3db5c45055b056b59d080c2a6697588de18398f06904 tags: - latest - - main targets: terraform: source: opal-terraform-provider sourceNamespace: opal-terraform-provider - sourceRevisionDigest: sha256:4607aac498872df8ebaeafe6a96cd40a30fbb6fa4ca216953db3f9eec7309867 - sourceBlobDigest: sha256:1d6d2919b0f91c1722050a4f6ea1cc45f356a51fec3ac8b6167fa963d59e6080 + sourceRevisionDigest: sha256:797f36bf99bd287ba390531ea15490eabd31f8f0b5a894e51e401e60b13bdff3 + sourceBlobDigest: sha256:b5a9fb0beae696e9ed9f3db5c45055b056b59d080c2a6697588de18398f06904 outLocation: . workflow: workflowVersion: 1.0.0 diff --git a/README.md b/README.md index 9056408d..92adb927 100644 --- a/README.md +++ b/README.md @@ -13,7 +13,7 @@ terraform { required_providers { opal = { source = "opalsecurity/opal" - version = "0.20.3" + version = "0.20.4" } } } diff --git a/docs/index.md b/docs/index.md index 911d0542..ab4c9570 100644 --- a/docs/index.md +++ b/docs/index.md @@ -17,7 +17,7 @@ terraform { required_providers { opal = { source = "opalsecurity/opal" - version = "0.20.3" + version = "0.20.4" } } } diff --git a/examples/provider/provider.tf b/examples/provider/provider.tf index e541bd7a..9d6b7234 100644 --- a/examples/provider/provider.tf +++ b/examples/provider/provider.tf @@ -2,7 +2,7 @@ terraform { required_providers { opal = { source = "opalsecurity/opal" - version = "0.20.3" + version = "0.20.4" } } } diff --git a/gen.yaml b/gen.yaml index ea830627..f473f97b 100644 --- a/gen.yaml +++ b/gen.yaml @@ -12,7 +12,7 @@ generation: baseServerURL: "" flattenGlobalSecurity: true terraform: - version: 0.20.3 + version: 0.20.4 additionalDataSources: [] additionalDependencies: {} additionalResources: [] diff --git a/go.mod b/go.mod index 94198c56..c8c54ba3 100644 --- a/go.mod +++ b/go.mod @@ -2,7 +2,7 @@ module github.com/opalsecurity/terraform-provider-opal go 1.21 -toolchain go1.21.10 +toolchain go1.21.1 require ( github.com/cenkalti/backoff/v4 v4.2.0 diff --git a/internal/provider/apps_data_source_sdk.go b/internal/provider/apps_data_source_sdk.go index 8175b831..b0a906e6 100644 --- a/internal/provider/apps_data_source_sdk.go +++ b/internal/provider/apps_data_source_sdk.go @@ -10,6 +10,7 @@ import ( func (r *AppsDataSourceModel) RefreshFromSharedAppsList(resp *shared.AppsList) { if resp != nil { + r.Apps = []tfTypes.App{} if len(r.Apps) > len(resp.Apps) { r.Apps = r.Apps[:len(resp.Apps)] } diff --git a/internal/provider/configurationtemplatelist_data_source_sdk.go b/internal/provider/configurationtemplatelist_data_source_sdk.go index 376b4376..817ef5fe 100644 --- a/internal/provider/configurationtemplatelist_data_source_sdk.go +++ b/internal/provider/configurationtemplatelist_data_source_sdk.go @@ -10,6 +10,7 @@ import ( func (r *ConfigurationTemplateListDataSourceModel) RefreshFromSharedPaginatedConfigurationTemplateList(resp *shared.PaginatedConfigurationTemplateList) { if resp != nil { + r.Results = []tfTypes.ConfigurationTemplate{} if len(r.Results) > len(resp.Results) { r.Results = r.Results[:len(resp.Results)] } diff --git a/internal/provider/events_data_source_sdk.go b/internal/provider/events_data_source_sdk.go index e8a8cb47..8ea3a60e 100644 --- a/internal/provider/events_data_source_sdk.go +++ b/internal/provider/events_data_source_sdk.go @@ -14,6 +14,7 @@ func (r *EventsDataSourceModel) RefreshFromSharedPaginatedEventList(resp *shared if resp != nil { r.Next = types.StringPointerValue(resp.Next) r.Previous = types.StringPointerValue(resp.Previous) + r.Results = []tfTypes.Event{} if len(r.Results) > len(resp.Results) { r.Results = r.Results[:len(resp.Results)] } @@ -29,6 +30,7 @@ func (r *EventsDataSourceModel) RefreshFromSharedPaginatedEventList(resp *shared results1.CreatedAt = types.StringValue(resultsItem.CreatedAt.Format(time.RFC3339Nano)) results1.EventID = types.StringValue(resultsItem.EventID) results1.EventType = types.StringValue(resultsItem.EventType) + results1.SubEvents = []tfTypes.SubEvent{} for subEventsCount, subEventsItem := range resultsItem.SubEvents { var subEvents1 tfTypes.SubEvent if subEventsItem.AdditionalProperties == nil { diff --git a/internal/provider/group_data_source_sdk.go b/internal/provider/group_data_source_sdk.go index 3dd8bdc4..9599fa19 100644 --- a/internal/provider/group_data_source_sdk.go +++ b/internal/provider/group_data_source_sdk.go @@ -86,6 +86,7 @@ func (r *GroupDataSourceModel) RefreshFromSharedGroup(resp *shared.Group) { } } r.RemoteName = types.StringPointerValue(resp.RemoteName) + r.RequestConfigurations = []tfTypes.RequestConfiguration{} if len(r.RequestConfigurations) > len(resp.RequestConfigurations) { r.RequestConfigurations = r.RequestConfigurations[:len(resp.RequestConfigurations)] } @@ -112,6 +113,7 @@ func (r *GroupDataSourceModel) RefreshFromSharedGroup(resp *shared.Group) { requestConfigurations1.RequestTemplateID = types.StringPointerValue(requestConfigurationsItem.RequestTemplateID) requestConfigurations1.RequireMfaToRequest = types.BoolValue(requestConfigurationsItem.RequireMfaToRequest) requestConfigurations1.RequireSupportTicket = types.BoolValue(requestConfigurationsItem.RequireSupportTicket) + requestConfigurations1.ReviewerStages = []tfTypes.ReviewerStage{} for reviewerStagesCount, reviewerStagesItem := range requestConfigurationsItem.ReviewerStages { var reviewerStages1 tfTypes.ReviewerStage if reviewerStagesItem.Operator != nil { @@ -155,6 +157,7 @@ func (r *GroupDataSourceModel) RefreshFromSharedGroup(resp *shared.Group) { func (r *GroupDataSourceModel) RefreshFromOperationsGetGroupMessageChannelsResponseBody(resp *operations.GetGroupMessageChannelsResponseBody) { if resp != nil { + r.MessageChannels.Channels = []tfTypes.MessageChannel{} if len(r.MessageChannels.Channels) > len(resp.Channels) { r.MessageChannels.Channels = r.MessageChannels.Channels[:len(resp.Channels)] } diff --git a/internal/provider/group_list_data_source_sdk.go b/internal/provider/group_list_data_source_sdk.go index e813f508..d434c45f 100644 --- a/internal/provider/group_list_data_source_sdk.go +++ b/internal/provider/group_list_data_source_sdk.go @@ -10,6 +10,7 @@ import ( func (r *GroupListDataSourceModel) RefreshFromSharedPaginatedGroupsList(resp *shared.PaginatedGroupsList) { if resp != nil { + r.Results = []tfTypes.Group{} if len(r.Results) > len(resp.Results) { r.Results = r.Results[:len(resp.Results)] } @@ -90,6 +91,7 @@ func (r *GroupListDataSourceModel) RefreshFromSharedPaginatedGroupsList(resp *sh } } results1.RemoteName = types.StringPointerValue(resultsItem.RemoteName) + results1.RequestConfigurations = []tfTypes.RequestConfiguration{} for requestConfigurationsCount, requestConfigurationsItem := range resultsItem.RequestConfigurations { var requestConfigurations1 tfTypes.RequestConfiguration requestConfigurations1.AllowRequests = types.BoolValue(requestConfigurationsItem.AllowRequests) @@ -113,6 +115,7 @@ func (r *GroupListDataSourceModel) RefreshFromSharedPaginatedGroupsList(resp *sh requestConfigurations1.RequestTemplateID = types.StringPointerValue(requestConfigurationsItem.RequestTemplateID) requestConfigurations1.RequireMfaToRequest = types.BoolValue(requestConfigurationsItem.RequireMfaToRequest) requestConfigurations1.RequireSupportTicket = types.BoolValue(requestConfigurationsItem.RequireSupportTicket) + requestConfigurations1.ReviewerStages = []tfTypes.ReviewerStage{} for reviewerStagesCount, reviewerStagesItem := range requestConfigurationsItem.ReviewerStages { var reviewerStages1 tfTypes.ReviewerStage if reviewerStagesItem.Operator != nil { diff --git a/internal/provider/group_resource_sdk.go b/internal/provider/group_resource_sdk.go index 6f3e6e9b..698f410e 100644 --- a/internal/provider/group_resource_sdk.go +++ b/internal/provider/group_resource_sdk.go @@ -183,6 +183,7 @@ func (r *GroupResourceModel) RefreshFromSharedGroup(resp *shared.Group) { } } r.RemoteName = types.StringPointerValue(resp.RemoteName) + r.RequestConfigurations = []tfTypes.RequestConfiguration{} if len(r.RequestConfigurations) > len(resp.RequestConfigurations) { r.RequestConfigurations = r.RequestConfigurations[:len(resp.RequestConfigurations)] } @@ -209,6 +210,7 @@ func (r *GroupResourceModel) RefreshFromSharedGroup(resp *shared.Group) { requestConfigurations1.RequestTemplateID = types.StringPointerValue(requestConfigurationsItem.RequestTemplateID) requestConfigurations1.RequireMfaToRequest = types.BoolValue(requestConfigurationsItem.RequireMfaToRequest) requestConfigurations1.RequireSupportTicket = types.BoolValue(requestConfigurationsItem.RequireSupportTicket) + requestConfigurations1.ReviewerStages = []tfTypes.ReviewerStage{} for reviewerStagesCount, reviewerStagesItem := range requestConfigurationsItem.ReviewerStages { var reviewerStages1 tfTypes.ReviewerStage if reviewerStagesItem.Operator != nil { @@ -385,6 +387,7 @@ func (r *GroupResourceModel) RefreshFromSharedUpdateGroupInfo(resp shared.Update } r.ID = types.StringPointerValue(resp.ID) r.Name = types.StringPointerValue(resp.Name) + r.RequestConfigurations = []tfTypes.RequestConfiguration{} if len(r.RequestConfigurations) > len(resp.RequestConfigurations) { r.RequestConfigurations = r.RequestConfigurations[:len(resp.RequestConfigurations)] } @@ -411,6 +414,7 @@ func (r *GroupResourceModel) RefreshFromSharedUpdateGroupInfo(resp shared.Update requestConfigurations1.RequestTemplateID = types.StringPointerValue(requestConfigurationsItem.RequestTemplateID) requestConfigurations1.RequireMfaToRequest = types.BoolValue(requestConfigurationsItem.RequireMfaToRequest) requestConfigurations1.RequireSupportTicket = types.BoolValue(requestConfigurationsItem.RequireSupportTicket) + requestConfigurations1.ReviewerStages = []tfTypes.ReviewerStage{} for reviewerStagesCount, reviewerStagesItem := range requestConfigurationsItem.ReviewerStages { var reviewerStages1 tfTypes.ReviewerStage if reviewerStagesItem.Operator != nil { @@ -477,6 +481,7 @@ func (r *GroupResourceModel) ToSharedVisibilityInfo() *shared.VisibilityInfo { func (r *GroupResourceModel) RefreshFromOperationsGetGroupMessageChannelsResponseBody(resp *operations.GetGroupMessageChannelsResponseBody) { if resp != nil { + r.MessageChannels.Channels = []tfTypes.MessageChannel{} if len(r.MessageChannels.Channels) > len(resp.Channels) { r.MessageChannels.Channels = r.MessageChannels.Channels[:len(resp.Channels)] } diff --git a/internal/provider/groupresourcelist_data_source_sdk.go b/internal/provider/groupresourcelist_data_source_sdk.go index 4a0080f2..73d7273e 100644 --- a/internal/provider/groupresourcelist_data_source_sdk.go +++ b/internal/provider/groupresourcelist_data_source_sdk.go @@ -10,6 +10,7 @@ import ( func (r *GroupResourceListDataSourceModel) RefreshFromSharedGroupResourceList(resp *shared.GroupResourceList) { if resp != nil { + r.GroupResources = []tfTypes.GroupResource1{} if len(r.GroupResources) > len(resp.GroupResources) { r.GroupResources = r.GroupResources[:len(resp.GroupResources)] } diff --git a/internal/provider/groupresourcelist_resource_sdk.go b/internal/provider/groupresourcelist_resource_sdk.go index 7abe09ec..6a5201d0 100644 --- a/internal/provider/groupresourcelist_resource_sdk.go +++ b/internal/provider/groupresourcelist_resource_sdk.go @@ -31,6 +31,7 @@ func (r *GroupResourceListResourceModel) ToSharedUpdateGroupResourcesInfo() *sha func (r *GroupResourceListResourceModel) RefreshFromSharedGroupResourceList(resp *shared.GroupResourceList) { if resp != nil { + r.GroupResources = []tfTypes.GroupResource1{} if len(r.GroupResources) > len(resp.GroupResources) { r.GroupResources = r.GroupResources[:len(resp.GroupResources)] } diff --git a/internal/provider/groupreviewersstageslist_data_source_sdk.go b/internal/provider/groupreviewersstageslist_data_source_sdk.go index 5e94ed6c..83d13798 100644 --- a/internal/provider/groupreviewersstageslist_data_source_sdk.go +++ b/internal/provider/groupreviewersstageslist_data_source_sdk.go @@ -9,6 +9,7 @@ import ( ) func (r *GroupReviewersStagesListDataSourceModel) RefreshFromSharedReviewerStage(resp []shared.ReviewerStage) { + r.Data = []tfTypes.ReviewerStage{} if len(r.Data) > len(resp) { r.Data = r.Data[:len(resp)] } diff --git a/internal/provider/grouptags_data_source_sdk.go b/internal/provider/grouptags_data_source_sdk.go index 34c998a2..3eed6abc 100644 --- a/internal/provider/grouptags_data_source_sdk.go +++ b/internal/provider/grouptags_data_source_sdk.go @@ -11,6 +11,7 @@ import ( func (r *GroupTagsDataSourceModel) RefreshFromSharedTagsList(resp *shared.TagsList) { if resp != nil { + r.Tags = []tfTypes.Tag{} if len(r.Tags) > len(resp.Tags) { r.Tags = r.Tags[:len(resp.Tags)] } diff --git a/internal/provider/groupusers_data_source_sdk.go b/internal/provider/groupusers_data_source_sdk.go index 84494764..70de7f80 100644 --- a/internal/provider/groupusers_data_source_sdk.go +++ b/internal/provider/groupusers_data_source_sdk.go @@ -11,6 +11,7 @@ import ( func (r *GroupUsersDataSourceModel) RefreshFromSharedGroupUserList(resp *shared.GroupUserList) { if resp != nil { + r.Results = []tfTypes.GroupUser{} if len(r.Results) > len(resp.Results) { r.Results = r.Results[:len(resp.Results)] } diff --git a/internal/provider/messagechannellist_data_source_sdk.go b/internal/provider/messagechannellist_data_source_sdk.go index d6165179..a5112919 100644 --- a/internal/provider/messagechannellist_data_source_sdk.go +++ b/internal/provider/messagechannellist_data_source_sdk.go @@ -10,6 +10,7 @@ import ( func (r *MessageChannelListDataSourceModel) RefreshFromSharedMessageChannelList(resp *shared.MessageChannelList) { if resp != nil { + r.Channels = []tfTypes.MessageChannel{} if len(r.Channels) > len(resp.Channels) { r.Channels = r.Channels[:len(resp.Channels)] } diff --git a/internal/provider/oncallschedule_list_data_source_sdk.go b/internal/provider/oncallschedule_list_data_source_sdk.go index d2c02332..b599d956 100644 --- a/internal/provider/oncallschedule_list_data_source_sdk.go +++ b/internal/provider/oncallschedule_list_data_source_sdk.go @@ -10,6 +10,7 @@ import ( func (r *OnCallScheduleListDataSourceModel) RefreshFromSharedOnCallScheduleList(resp *shared.OnCallScheduleList) { if resp != nil { + r.OnCallSchedules = []tfTypes.GetGroupOnCallSchedulesResponseBody{} if len(r.OnCallSchedules) > len(resp.OnCallSchedules) { r.OnCallSchedules = r.OnCallSchedules[:len(resp.OnCallSchedules)] } diff --git a/internal/provider/owners_data_source_sdk.go b/internal/provider/owners_data_source_sdk.go index bef477a0..7af1e803 100644 --- a/internal/provider/owners_data_source_sdk.go +++ b/internal/provider/owners_data_source_sdk.go @@ -12,6 +12,7 @@ func (r *OwnersDataSourceModel) RefreshFromSharedPaginatedOwnersList(resp *share if resp != nil { r.Next = types.StringPointerValue(resp.Next) r.Previous = types.StringPointerValue(resp.Previous) + r.Results = []tfTypes.Owner{} if len(r.Results) > len(resp.Results) { r.Results = r.Results[:len(resp.Results)] } diff --git a/internal/provider/requests_data_source_sdk.go b/internal/provider/requests_data_source_sdk.go index 103bb343..bb6d7e80 100644 --- a/internal/provider/requests_data_source_sdk.go +++ b/internal/provider/requests_data_source_sdk.go @@ -12,12 +12,14 @@ import ( func (r *RequestsDataSourceModel) RefreshFromSharedRequestList(resp *shared.RequestList) { if resp != nil { r.Cursor = types.StringPointerValue(resp.Cursor) + r.Requests = []tfTypes.Request{} if len(r.Requests) > len(resp.Requests) { r.Requests = r.Requests[:len(resp.Requests)] } for requestsCount, requestsItem := range resp.Requests { var requests1 tfTypes.Request requests1.CreatedAt = types.StringValue(requestsItem.CreatedAt.Format(time.RFC3339Nano)) + requests1.CustomFieldsResponses = []tfTypes.RequestCustomFieldResponse{} for customFieldsResponsesCount, customFieldsResponsesItem := range requestsItem.CustomFieldsResponses { var customFieldsResponses1 tfTypes.RequestCustomFieldResponse customFieldsResponses1.FieldName = types.StringValue(customFieldsResponsesItem.FieldName) @@ -39,6 +41,7 @@ func (r *RequestsDataSourceModel) RefreshFromSharedRequestList(resp *shared.Requ requests1.DurationMinutes = types.Int64PointerValue(requestsItem.DurationMinutes) requests1.ID = types.StringValue(requestsItem.ID) requests1.Reason = types.StringValue(requestsItem.Reason) + requests1.RequestedItemsList = []tfTypes.RequestedItem{} for requestedItemsListCount, requestedItemsListItem := range requestsItem.RequestedItemsList { var requestedItemsList1 tfTypes.RequestedItem requestedItemsList1.AccessLevelName = types.StringPointerValue(requestedItemsListItem.AccessLevelName) diff --git a/internal/provider/resource_data_source_sdk.go b/internal/provider/resource_data_source_sdk.go index 6721e873..d1c4b50d 100644 --- a/internal/provider/resource_data_source_sdk.go +++ b/internal/provider/resource_data_source_sdk.go @@ -186,6 +186,7 @@ func (r *ResourceDataSourceModel) RefreshFromSharedResource(resp *shared.Resourc r.RemoteInfo.TeleportRole.RoleName = types.StringValue(resp.RemoteInfo.TeleportRole.RoleName) } } + r.RequestConfigurations = []tfTypes.RequestConfiguration{} if len(r.RequestConfigurations) > len(resp.RequestConfigurations) { r.RequestConfigurations = r.RequestConfigurations[:len(resp.RequestConfigurations)] } @@ -212,6 +213,7 @@ func (r *ResourceDataSourceModel) RefreshFromSharedResource(resp *shared.Resourc requestConfigurations1.RequestTemplateID = types.StringPointerValue(requestConfigurationsItem.RequestTemplateID) requestConfigurations1.RequireMfaToRequest = types.BoolValue(requestConfigurationsItem.RequireMfaToRequest) requestConfigurations1.RequireSupportTicket = types.BoolValue(requestConfigurationsItem.RequireSupportTicket) + requestConfigurations1.ReviewerStages = []tfTypes.ReviewerStage{} for reviewerStagesCount, reviewerStagesItem := range requestConfigurationsItem.ReviewerStages { var reviewerStages1 tfTypes.ReviewerStage if reviewerStagesItem.Operator != nil { diff --git a/internal/provider/resource_resource_sdk.go b/internal/provider/resource_resource_sdk.go index eac2eec9..7746e783 100644 --- a/internal/provider/resource_resource_sdk.go +++ b/internal/provider/resource_resource_sdk.go @@ -461,6 +461,7 @@ func (r *ResourceResourceModel) RefreshFromSharedResource(resp *shared.Resource) r.RemoteInfo.TeleportRole.RoleName = types.StringValue(resp.RemoteInfo.TeleportRole.RoleName) } } + r.RequestConfigurations = []tfTypes.RequestConfiguration{} if len(r.RequestConfigurations) > len(resp.RequestConfigurations) { r.RequestConfigurations = r.RequestConfigurations[:len(resp.RequestConfigurations)] } @@ -487,6 +488,7 @@ func (r *ResourceResourceModel) RefreshFromSharedResource(resp *shared.Resource) requestConfigurations1.RequestTemplateID = types.StringPointerValue(requestConfigurationsItem.RequestTemplateID) requestConfigurations1.RequireMfaToRequest = types.BoolValue(requestConfigurationsItem.RequireMfaToRequest) requestConfigurations1.RequireSupportTicket = types.BoolValue(requestConfigurationsItem.RequireSupportTicket) + requestConfigurations1.ReviewerStages = []tfTypes.ReviewerStage{} for reviewerStagesCount, reviewerStagesItem := range requestConfigurationsItem.ReviewerStages { var reviewerStages1 tfTypes.ReviewerStage if reviewerStagesItem.Operator != nil { @@ -667,6 +669,7 @@ func (r *ResourceResourceModel) RefreshFromSharedUpdateResourceInfo(resp shared. r.Description = types.StringPointerValue(resp.Description) r.ID = types.StringPointerValue(resp.ID) r.Name = types.StringPointerValue(resp.Name) + r.RequestConfigurations = []tfTypes.RequestConfiguration{} if len(r.RequestConfigurations) > len(resp.RequestConfigurations) { r.RequestConfigurations = r.RequestConfigurations[:len(resp.RequestConfigurations)] } @@ -693,6 +696,7 @@ func (r *ResourceResourceModel) RefreshFromSharedUpdateResourceInfo(resp shared. requestConfigurations1.RequestTemplateID = types.StringPointerValue(requestConfigurationsItem.RequestTemplateID) requestConfigurations1.RequireMfaToRequest = types.BoolValue(requestConfigurationsItem.RequireMfaToRequest) requestConfigurations1.RequireSupportTicket = types.BoolValue(requestConfigurationsItem.RequireSupportTicket) + requestConfigurations1.ReviewerStages = []tfTypes.ReviewerStage{} for reviewerStagesCount, reviewerStagesItem := range requestConfigurationsItem.ReviewerStages { var reviewerStages1 tfTypes.ReviewerStage if reviewerStagesItem.Operator != nil { diff --git a/internal/provider/resourcemessagechannellist_data_source_sdk.go b/internal/provider/resourcemessagechannellist_data_source_sdk.go index d0e6f9b7..87c74732 100644 --- a/internal/provider/resourcemessagechannellist_data_source_sdk.go +++ b/internal/provider/resourcemessagechannellist_data_source_sdk.go @@ -10,6 +10,7 @@ import ( func (r *ResourceMessageChannelListDataSourceModel) RefreshFromSharedMessageChannelList(resp *shared.MessageChannelList) { if resp != nil { + r.Channels = []tfTypes.MessageChannel{} if len(r.Channels) > len(resp.Channels) { r.Channels = r.Channels[:len(resp.Channels)] } diff --git a/internal/provider/resources_list_data_source_sdk.go b/internal/provider/resources_list_data_source_sdk.go index 23de7f4f..453dcde5 100644 --- a/internal/provider/resources_list_data_source_sdk.go +++ b/internal/provider/resources_list_data_source_sdk.go @@ -12,6 +12,7 @@ func (r *ResourcesListDataSourceModel) RefreshFromSharedPaginatedResourcesList(r if resp != nil { r.Next = types.StringPointerValue(resp.Next) r.Previous = types.StringPointerValue(resp.Previous) + r.Results = []tfTypes.Resource{} if len(r.Results) > len(resp.Results) { r.Results = r.Results[:len(resp.Results)] } @@ -193,6 +194,7 @@ func (r *ResourcesListDataSourceModel) RefreshFromSharedPaginatedResourcesList(r results1.RemoteInfo.TeleportRole.RoleName = types.StringValue(resultsItem.RemoteInfo.TeleportRole.RoleName) } } + results1.RequestConfigurations = []tfTypes.RequestConfiguration{} for requestConfigurationsCount, requestConfigurationsItem := range resultsItem.RequestConfigurations { var requestConfigurations1 tfTypes.RequestConfiguration requestConfigurations1.AllowRequests = types.BoolValue(requestConfigurationsItem.AllowRequests) @@ -216,6 +218,7 @@ func (r *ResourcesListDataSourceModel) RefreshFromSharedPaginatedResourcesList(r requestConfigurations1.RequestTemplateID = types.StringPointerValue(requestConfigurationsItem.RequestTemplateID) requestConfigurations1.RequireMfaToRequest = types.BoolValue(requestConfigurationsItem.RequireMfaToRequest) requestConfigurations1.RequireSupportTicket = types.BoolValue(requestConfigurationsItem.RequireSupportTicket) + requestConfigurations1.ReviewerStages = []tfTypes.ReviewerStage{} for reviewerStagesCount, reviewerStagesItem := range requestConfigurationsItem.ReviewerStages { var reviewerStages1 tfTypes.ReviewerStage if reviewerStagesItem.Operator != nil { diff --git a/internal/provider/resourcesusers_list_data_source_sdk.go b/internal/provider/resourcesusers_list_data_source_sdk.go index 86deccb4..03526972 100644 --- a/internal/provider/resourcesusers_list_data_source_sdk.go +++ b/internal/provider/resourcesusers_list_data_source_sdk.go @@ -11,6 +11,7 @@ import ( func (r *ResourcesUsersListDataSourceModel) RefreshFromSharedResourceAccessUserList(resp *shared.ResourceAccessUserList) { if resp != nil { + r.Results = []tfTypes.ResourceAccessUser{} if len(r.Results) > len(resp.Results) { r.Results = r.Results[:len(resp.Results)] } diff --git a/internal/provider/resourcetags_data_source_sdk.go b/internal/provider/resourcetags_data_source_sdk.go index 9a6bd8d5..858c3bc2 100644 --- a/internal/provider/resourcetags_data_source_sdk.go +++ b/internal/provider/resourcetags_data_source_sdk.go @@ -11,6 +11,7 @@ import ( func (r *ResourceTagsDataSourceModel) RefreshFromSharedTagsList(resp *shared.TagsList) { if resp != nil { + r.Tags = []tfTypes.Tag{} if len(r.Tags) > len(resp.Tags) { r.Tags = r.Tags[:len(resp.Tags)] } diff --git a/internal/provider/sessions_data_source_sdk.go b/internal/provider/sessions_data_source_sdk.go index cffb7f05..84213a45 100644 --- a/internal/provider/sessions_data_source_sdk.go +++ b/internal/provider/sessions_data_source_sdk.go @@ -13,6 +13,7 @@ func (r *SessionsDataSourceModel) RefreshFromSharedSessionsList(resp *shared.Ses if resp != nil { r.Next = types.StringPointerValue(resp.Next) r.Previous = types.StringPointerValue(resp.Previous) + r.Results = []tfTypes.Session{} if len(r.Results) > len(resp.Results) { r.Results = r.Results[:len(resp.Results)] } diff --git a/internal/provider/tags_list_data_source_sdk.go b/internal/provider/tags_list_data_source_sdk.go index 25ca3204..9b988903 100644 --- a/internal/provider/tags_list_data_source_sdk.go +++ b/internal/provider/tags_list_data_source_sdk.go @@ -13,6 +13,7 @@ func (r *TagsListDataSourceModel) RefreshFromSharedPaginatedTagsList(resp *share if resp != nil { r.Next = types.StringPointerValue(resp.Next) r.Previous = types.StringPointerValue(resp.Previous) + r.Results = []tfTypes.Tag{} if len(r.Results) > len(resp.Results) { r.Results = r.Results[:len(resp.Results)] } diff --git a/internal/provider/uar_data_source_sdk.go b/internal/provider/uar_data_source_sdk.go index fc3ecd06..86f5e8b8 100644 --- a/internal/provider/uar_data_source_sdk.go +++ b/internal/provider/uar_data_source_sdk.go @@ -56,6 +56,7 @@ func (r *UarDataSourceModel) RefreshFromSharedUar(resp *shared.Uar) { for _, v := range resp.UarScope.ResourceTypes { r.UarScope.ResourceTypes = append(r.UarScope.ResourceTypes, types.StringValue(string(v))) } + r.UarScope.Tags = []tfTypes.TagFilter{} if len(r.UarScope.Tags) > len(resp.UarScope.Tags) { r.UarScope.Tags = r.UarScope.Tags[:len(resp.UarScope.Tags)] } diff --git a/internal/provider/uars_list_data_source_sdk.go b/internal/provider/uars_list_data_source_sdk.go index b9640a59..048c644a 100644 --- a/internal/provider/uars_list_data_source_sdk.go +++ b/internal/provider/uars_list_data_source_sdk.go @@ -13,6 +13,7 @@ func (r *UARSListDataSourceModel) RefreshFromSharedPaginatedUARsList(resp *share if resp != nil { r.Next = types.StringPointerValue(resp.Next) r.Previous = types.StringPointerValue(resp.Previous) + r.Results = []tfTypes.Uar{} if len(r.Results) > len(resp.Results) { r.Results = r.Results[:len(resp.Results)] } @@ -64,6 +65,7 @@ func (r *UARSListDataSourceModel) RefreshFromSharedPaginatedUARsList(resp *share for _, v := range resultsItem.UarScope.ResourceTypes { results1.UarScope.ResourceTypes = append(results1.UarScope.ResourceTypes, types.StringValue(string(v))) } + results1.UarScope.Tags = []tfTypes.TagFilter{} for tagsCount, tagsItem := range resultsItem.UarScope.Tags { var tags1 tfTypes.TagFilter tags1.Key = types.StringValue(tagsItem.Key) diff --git a/internal/provider/users_data_source_sdk.go b/internal/provider/users_data_source_sdk.go index c1edeae4..10124a15 100644 --- a/internal/provider/users_data_source_sdk.go +++ b/internal/provider/users_data_source_sdk.go @@ -12,6 +12,7 @@ func (r *UsersDataSourceModel) RefreshFromSharedPaginatedUsersList(resp *shared. if resp != nil { r.Next = types.StringPointerValue(resp.Next) r.Previous = types.StringPointerValue(resp.Previous) + r.Results = []tfTypes.User{} if len(r.Results) > len(resp.Results) { r.Results = r.Results[:len(resp.Results)] } diff --git a/internal/provider/usertags_data_source_sdk.go b/internal/provider/usertags_data_source_sdk.go index 1812fcb0..d70b63d6 100644 --- a/internal/provider/usertags_data_source_sdk.go +++ b/internal/provider/usertags_data_source_sdk.go @@ -11,6 +11,7 @@ import ( func (r *UserTagsDataSourceModel) RefreshFromSharedTagsList(resp *shared.TagsList) { if resp != nil { + r.Tags = []tfTypes.Tag{} if len(r.Tags) > len(resp.Tags) { r.Tags = r.Tags[:len(resp.Tags)] } diff --git a/internal/sdk/opalapi.go b/internal/sdk/opalapi.go index b6af43ad..fd316d03 100644 --- a/internal/sdk/opalapi.go +++ b/internal/sdk/opalapi.go @@ -172,8 +172,8 @@ func New(opts ...SDKOption) *OpalAPI { Language: "go", OpenAPIDocVersion: "1.0", SDKVersion: "0.0.1", - GenVersion: "2.335.5", - UserAgent: "speakeasy-sdk/go 0.0.1 2.335.5 1.0 github.com/opalsecurity/terraform-provider-opal/internal/sdk", + GenVersion: "2.338.7", + UserAgent: "speakeasy-sdk/go 0.0.1 2.338.7 1.0 github.com/opalsecurity/terraform-provider-opal/internal/sdk", Hooks: hooks.New(), }, }