From 3d566dea420047ea526de4e07967f56becb7e05f Mon Sep 17 00:00:00 2001 From: Peng Jiahui <46921893+Alancere@users.noreply.github.com> Date: Tue, 30 Apr 2024 10:59:09 +0800 Subject: [PATCH] [Release] sdk/resourcemanager/eventgrid/armeventgrid/2.3.0-beta.2 (#22793) * [Release] sdk/resourcemanager/eventgrid/armeventgrid/2.3.0-beta.2 generation from spec commit: b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd * update assets --- .../eventgrid/armeventgrid/CHANGELOG.md | 31 ++ .../eventgrid/armeventgrid/README.md | 2 +- .../eventgrid/armeventgrid/assets.json | 2 +- .../eventgrid/armeventgrid/autorest.md | 8 +- .../armeventgrid/cacertificates_client.go | 20 +- .../cacertificates_client_example_test.go | 8 +- .../eventgrid/armeventgrid/channels_client.go | 26 +- .../channels_client_example_test.go | 12 +- .../eventgrid/armeventgrid/client_factory.go | 191 +++++++---- .../armeventgrid/clientgroups_client.go | 20 +- .../clientgroups_client_example_test.go | 8 +- .../eventgrid/armeventgrid/clients_client.go | 20 +- .../clients_client_example_test.go | 8 +- .../eventgrid/armeventgrid/constants.go | 60 +++- .../domaineventsubscriptions_client.go | 42 ++- ...neventsubscriptions_client_example_test.go | 14 +- .../eventgrid/armeventgrid/domains_client.go | 38 +-- .../domains_client_example_test.go | 16 +- .../domaintopiceventsubscriptions_client.go | 41 ++- ...ceventsubscriptions_client_example_test.go | 14 +- .../armeventgrid/domaintopics_client.go | 20 +- .../domaintopics_client_example_test.go | 8 +- .../armeventgrid/eventsubscriptions_client.go | 78 ++--- .../eventsubscriptions_client_example_test.go | 104 +++--- .../armeventgrid/extensiontopics_client.go | 4 +- .../extensiontopics_client_example_test.go | 2 +- .../armeventgrid/fake/namespaces_server.go | 80 ++++- ...namespacetopiceventsubscriptions_server.go | 47 +++ .../armeventgrid/fake/time_rfc3339.go | 42 ++- .../eventgrid/armeventgrid/models.go | 150 ++++++++- .../eventgrid/armeventgrid/models_serde.go | 317 +++++++++++++++++- .../armeventgrid/namespaces_client.go | 118 +++++-- .../namespaces_client_example_test.go | 64 +++- ...namespacetopiceventsubscriptions_client.go | 119 +++++-- ...ceventsubscriptions_client_example_test.go | 35 +- .../armeventgrid/namespacetopics_client.go | 36 +- .../namespacetopics_client_example_test.go | 14 +- ...ksecurityperimeterconfigurations_client.go | 14 +- ...meterconfigurations_client_example_test.go | 6 +- .../armeventgrid/operations_client.go | 4 +- .../operations_client_example_test.go | 2 +- .../eventgrid/armeventgrid/options.go | 13 + .../partnerconfigurations_client.go | 38 +-- ...rtnerconfigurations_client_example_test.go | 16 +- .../partnerdestinations_client.go | 34 +- ...partnerdestinations_client_example_test.go | 14 +- .../armeventgrid/partnernamespaces_client.go | 38 +-- .../partnernamespaces_client_example_test.go | 16 +- .../partnerregistrations_client.go | 30 +- ...artnerregistrations_client_example_test.go | 12 +- .../partnertopiceventsubscriptions_client.go | 51 ++- ...ceventsubscriptions_client_example_test.go | 14 +- .../armeventgrid/partnertopics_client.go | 34 +- .../partnertopics_client_example_test.go | 16 +- .../armeventgrid/permissionbindings_client.go | 20 +- .../permissionbindings_client_example_test.go | 8 +- .../armeventgrid/polymorphic_helpers.go | 28 +- .../privateendpointconnections_client.go | 20 +- ...endpointconnections_client_example_test.go | 8 +- .../privatelinkresources_client.go | 8 +- ...rivatelinkresources_client_example_test.go | 4 +- .../{response_types.go => responses.go} | 26 +- .../systemtopiceventsubscriptions_client.go | 51 ++- ...ceventsubscriptions_client_example_test.go | 14 +- .../armeventgrid/systemtopics_client.go | 30 +- .../systemtopics_client_example_test.go | 12 +- .../eventgrid/armeventgrid/time_rfc3339.go | 42 ++- .../topiceventsubscriptions_client.go | 42 ++- ...ceventsubscriptions_client_example_test.go | 14 +- .../eventgrid/armeventgrid/topics_client.go | 44 +-- .../topics_client_example_test.go | 20 +- .../armeventgrid/topicspaces_client.go | 20 +- .../topicspaces_client_example_test.go | 8 +- .../armeventgrid/topictypes_client.go | 12 +- .../topictypes_client_example_test.go | 6 +- .../armeventgrid/verifiedpartners_client.go | 8 +- .../verifiedpartners_client_example_test.go | 4 +- 77 files changed, 1788 insertions(+), 832 deletions(-) rename sdk/resourcemanager/eventgrid/armeventgrid/{response_types.go => responses.go} (97%) diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/CHANGELOG.md b/sdk/resourcemanager/eventgrid/armeventgrid/CHANGELOG.md index 96c9d3fbc5cb..541512637e26 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/CHANGELOG.md +++ b/sdk/resourcemanager/eventgrid/armeventgrid/CHANGELOG.md @@ -1,5 +1,36 @@ # Release History +## 2.3.0-beta.2 (2024-04-30) +### Breaking Changes + +- Type of `NetworkSecurityPerimeterProfileAccessRuleProperties.Subscriptions` has been changed from `[]*string` to `[]*NetworkSecurityPerimeterSubscription` + +### Features Added + +- New enum type `CustomDomainIdentityType` with values `CustomDomainIdentityTypeSystemAssigned`, `CustomDomainIdentityTypeUserAssigned` +- New enum type `CustomDomainValidationState` with values `CustomDomainValidationStateApproved`, `CustomDomainValidationStateErrorRetrievingDNSRecord`, `CustomDomainValidationStatePending` +- New enum type `CustomJwtAuthenticationManagedIdentityType` with values `CustomJwtAuthenticationManagedIdentityTypeSystemAssigned`, `CustomJwtAuthenticationManagedIdentityTypeUserAssigned` +- New function `*NamespaceTopicEventSubscriptionsClient.GetFullURL(context.Context, string, string, string, string, *NamespaceTopicEventSubscriptionsClientGetFullURLOptions) (NamespaceTopicEventSubscriptionsClientGetFullURLResponse, error)` +- New function `*NamespacesClient.BeginValidateCustomDomainOwnership(context.Context, string, string, *NamespacesClientBeginValidateCustomDomainOwnershipOptions) (*runtime.Poller[NamespacesClientValidateCustomDomainOwnershipResponse], error)` +- New struct `CustomDomainConfiguration` +- New struct `CustomDomainIdentity` +- New struct `CustomDomainOwnershipValidationResult` +- New struct `CustomJwtAuthenticationManagedIdentity` +- New struct `CustomJwtAuthenticationSettings` +- New struct `IssuerCertificateInfo` +- New struct `NetworkSecurityPerimeterSubscription` +- New struct `SubscriptionFullURL` +- New struct `UpdateTopicsConfigurationInfo` +- New field `CustomJwtAuthentication` in struct `ClientAuthenticationSettings` +- New field `TopicsConfiguration` in struct `NamespaceUpdateParameterProperties` +- New field `Destination` in struct `PushInfo` +- New field `ExpirationTimeUTC` in struct `SubscriptionProperties` +- New field `ExpirationTimeUTC` in struct `SubscriptionUpdateParametersProperties` +- New field `CustomDomains` in struct `TopicSpacesConfiguration` +- New field `CustomDomains` in struct `TopicsConfiguration` +- New field `CustomDomains` in struct `UpdateTopicSpacesConfigurationInfo` + + ## 2.3.0-beta.1 (2023-11-24) ### Features Added diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/README.md b/sdk/resourcemanager/eventgrid/armeventgrid/README.md index 12880e13317b..126546ae6885 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/README.md +++ b/sdk/resourcemanager/eventgrid/armeventgrid/README.md @@ -57,7 +57,7 @@ clientFactory, err := armeventgrid.NewClientFactory(, cred, &op A client groups a set of related APIs, providing access to its functionality. Create one or more clients to access the APIs you require using client factory. ```go -client := clientFactory.NewPartnerNamespacesClient() +client := clientFactory.NewCaCertificatesClient() ``` ## Fakes diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/assets.json b/sdk/resourcemanager/eventgrid/armeventgrid/assets.json index 31e4228c74e1..6572d9344c96 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/assets.json +++ b/sdk/resourcemanager/eventgrid/armeventgrid/assets.json @@ -2,5 +2,5 @@ "AssetsRepo": "Azure/azure-sdk-assets", "AssetsRepoPrefixPath": "go", "TagPrefix": "go/resourcemanager/eventgrid/armeventgrid", - "Tag": "go/resourcemanager/eventgrid/armeventgrid_822a7992fe" + "Tag": "go/resourcemanager/eventgrid/armeventgrid_29c3f1b99d" } diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/autorest.md b/sdk/resourcemanager/eventgrid/armeventgrid/autorest.md index 1a6f7f5adede..687a69a9c76a 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/autorest.md +++ b/sdk/resourcemanager/eventgrid/armeventgrid/autorest.md @@ -5,9 +5,9 @@ ``` yaml azure-arm: true require: -- https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/readme.md -- https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/readme.go.md +- https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/readme.md +- https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/readme.go.md license-header: MICROSOFT_MIT_NO_VERSION -module-version: 2.3.0-beta.1 -tag: package-2023-12-preview +module-version: 2.3.0-beta.2 +tag: package-2024-06-preview ``` \ No newline at end of file diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/cacertificates_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/cacertificates_client.go index c18b8d26f830..8f243f0e6668 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/cacertificates_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/cacertificates_client.go @@ -48,7 +48,7 @@ func NewCaCertificatesClient(subscriptionID string, credential azcore.TokenCrede // BeginCreateOrUpdate - Create or update a CA certificate with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - caCertificateName - The CA certificate name. @@ -76,7 +76,7 @@ func (client *CaCertificatesClient) BeginCreateOrUpdate(ctx context.Context, res // CreateOrUpdate - Create or update a CA certificate with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *CaCertificatesClient) createOrUpdate(ctx context.Context, resourceGroupName string, namespaceName string, caCertificateName string, caCertificateInfo CaCertificate, options *CaCertificatesClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "CaCertificatesClient.BeginCreateOrUpdate" @@ -122,7 +122,7 @@ func (client *CaCertificatesClient) createOrUpdateCreateRequest(ctx context.Cont return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, caCertificateInfo); err != nil { @@ -134,7 +134,7 @@ func (client *CaCertificatesClient) createOrUpdateCreateRequest(ctx context.Cont // BeginDelete - Delete an existing CA certificate. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - caCertificateName - Name of the CA certificate. @@ -161,7 +161,7 @@ func (client *CaCertificatesClient) BeginDelete(ctx context.Context, resourceGro // Delete - Delete an existing CA certificate. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *CaCertificatesClient) deleteOperation(ctx context.Context, resourceGroupName string, namespaceName string, caCertificateName string, options *CaCertificatesClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "CaCertificatesClient.BeginDelete" @@ -207,7 +207,7 @@ func (client *CaCertificatesClient) deleteCreateRequest(ctx context.Context, res return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -216,7 +216,7 @@ func (client *CaCertificatesClient) deleteCreateRequest(ctx context.Context, res // Get - Get properties of a CA certificate. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - caCertificateName - Name of the CA certificate. @@ -267,7 +267,7 @@ func (client *CaCertificatesClient) getCreateRequest(ctx context.Context, resour return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -284,7 +284,7 @@ func (client *CaCertificatesClient) getHandleResponse(resp *http.Response) (CaCe // NewListByNamespacePager - Get all the CA certificates under a namespace. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - options - CaCertificatesClientListByNamespaceOptions contains the optional parameters for the CaCertificatesClient.NewListByNamespacePager @@ -332,13 +332,13 @@ func (client *CaCertificatesClient) listByNamespaceCreateRequest(ctx context.Con return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/cacertificates_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/cacertificates_client_example_test.go index 5d545c07e4b6..4ef7e43421cd 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/cacertificates_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/cacertificates_client_example_test.go @@ -18,7 +18,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/CaCertificates_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/CaCertificates_Get.json func ExampleCaCertificatesClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -50,7 +50,7 @@ func ExampleCaCertificatesClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/CaCertificates_CreateOrUpdate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/CaCertificates_CreateOrUpdate.json func ExampleCaCertificatesClient_BeginCreateOrUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -91,7 +91,7 @@ func ExampleCaCertificatesClient_BeginCreateOrUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/CaCertificates_Delete.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/CaCertificates_Delete.json func ExampleCaCertificatesClient_BeginDelete() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -112,7 +112,7 @@ func ExampleCaCertificatesClient_BeginDelete() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/CaCertificates_ListByNamespace.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/CaCertificates_ListByNamespace.json func ExampleCaCertificatesClient_NewListByNamespacePager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/channels_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/channels_client.go index b9189dee3813..38c9fac0660e 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/channels_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/channels_client.go @@ -48,7 +48,7 @@ func NewChannelsClient(subscriptionID string, credential azcore.TokenCredential, // CreateOrUpdate - Synchronously creates or updates a new channel with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the partners subscription. // - partnerNamespaceName - Name of the partner namespace. // - channelName - Name of the channel. @@ -100,7 +100,7 @@ func (client *ChannelsClient) createOrUpdateCreateRequest(ctx context.Context, r return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, channelInfo); err != nil { @@ -121,7 +121,7 @@ func (client *ChannelsClient) createOrUpdateHandleResponse(resp *http.Response) // BeginDelete - Delete an existing channel. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the partners subscription. // - partnerNamespaceName - Name of the partner namespace. // - channelName - Name of the channel. @@ -146,7 +146,7 @@ func (client *ChannelsClient) BeginDelete(ctx context.Context, resourceGroupName // Delete - Delete an existing channel. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *ChannelsClient) deleteOperation(ctx context.Context, resourceGroupName string, partnerNamespaceName string, channelName string, options *ChannelsClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "ChannelsClient.BeginDelete" @@ -192,7 +192,7 @@ func (client *ChannelsClient) deleteCreateRequest(ctx context.Context, resourceG return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() return req, nil } @@ -200,7 +200,7 @@ func (client *ChannelsClient) deleteCreateRequest(ctx context.Context, resourceG // Get - Get properties of a channel. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the partners subscription. // - partnerNamespaceName - Name of the partner namespace. // - channelName - Name of the channel. @@ -251,7 +251,7 @@ func (client *ChannelsClient) getCreateRequest(ctx context.Context, resourceGrou return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -269,7 +269,7 @@ func (client *ChannelsClient) getHandleResponse(resp *http.Response) (ChannelsCl // GetFullURL - Get the full endpoint URL of a partner destination channel. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the partners subscription. // - partnerNamespaceName - Name of the partner namespace. // - channelName - Name of the Channel. @@ -320,7 +320,7 @@ func (client *ChannelsClient) getFullURLCreateRequest(ctx context.Context, resou return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -337,7 +337,7 @@ func (client *ChannelsClient) getFullURLHandleResponse(resp *http.Response) (Cha // NewListByPartnerNamespacePager - List all the channels in a partner namespace. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the partners subscription. // - partnerNamespaceName - Name of the partner namespace. // - options - ChannelsClientListByPartnerNamespaceOptions contains the optional parameters for the ChannelsClient.NewListByPartnerNamespacePager @@ -385,13 +385,13 @@ func (client *ChannelsClient) listByPartnerNamespaceCreateRequest(ctx context.Co return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -409,7 +409,7 @@ func (client *ChannelsClient) listByPartnerNamespaceHandleResponse(resp *http.Re // Update - Synchronously updates a channel with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the partners subscription. // - partnerNamespaceName - Name of the partner namespace. // - channelName - Name of the channel. @@ -460,7 +460,7 @@ func (client *ChannelsClient) updateCreateRequest(ctx context.Context, resourceG return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() if err := runtime.MarshalAsJSON(req, channelUpdateParameters); err != nil { return nil, err diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/channels_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/channels_client_example_test.go index 50b48000c732..ded4c6d88ca4 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/channels_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/channels_client_example_test.go @@ -20,7 +20,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Channels_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Channels_Get.json func ExampleChannelsClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -58,7 +58,7 @@ func ExampleChannelsClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Channels_CreateOrUpdate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Channels_CreateOrUpdate.json func ExampleChannelsClient_CreateOrUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -106,7 +106,7 @@ func ExampleChannelsClient_CreateOrUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Channels_Delete.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Channels_Delete.json func ExampleChannelsClient_BeginDelete() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -127,7 +127,7 @@ func ExampleChannelsClient_BeginDelete() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Channels_Update.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Channels_Update.json func ExampleChannelsClient_Update() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -148,7 +148,7 @@ func ExampleChannelsClient_Update() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Channels_ListByPartnerNamespace.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Channels_ListByPartnerNamespace.json func ExampleChannelsClient_NewListByPartnerNamespacePager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -196,7 +196,7 @@ func ExampleChannelsClient_NewListByPartnerNamespacePager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Channels_GetFullUrl.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Channels_GetFullUrl.json func ExampleChannelsClient_GetFullURL() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/client_factory.go b/sdk/resourcemanager/eventgrid/armeventgrid/client_factory.go index b4cd0572f782..2f0e233971d3 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/client_factory.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/client_factory.go @@ -17,8 +17,7 @@ import ( // Don't use this type directly, use NewClientFactory instead. type ClientFactory struct { subscriptionID string - credential azcore.TokenCredential - options *arm.ClientOptions + internal *arm.Client } // NewClientFactory creates a new instance of ClientFactory with the specified values. @@ -28,198 +27,256 @@ type ClientFactory struct { // - credential - used to authorize requests. Usually a credential from azidentity. // - options - pass nil to accept the default values. func NewClientFactory(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*ClientFactory, error) { - _, err := arm.NewClient(moduleName, moduleVersion, credential, options) + internal, err := arm.NewClient(moduleName, moduleVersion, credential, options) if err != nil { return nil, err } return &ClientFactory{ - subscriptionID: subscriptionID, credential: credential, - options: options.Clone(), + subscriptionID: subscriptionID, + internal: internal, }, nil } // NewCaCertificatesClient creates a new instance of CaCertificatesClient. func (c *ClientFactory) NewCaCertificatesClient() *CaCertificatesClient { - subClient, _ := NewCaCertificatesClient(c.subscriptionID, c.credential, c.options) - return subClient + return &CaCertificatesClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewChannelsClient creates a new instance of ChannelsClient. func (c *ClientFactory) NewChannelsClient() *ChannelsClient { - subClient, _ := NewChannelsClient(c.subscriptionID, c.credential, c.options) - return subClient + return &ChannelsClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewClientGroupsClient creates a new instance of ClientGroupsClient. func (c *ClientFactory) NewClientGroupsClient() *ClientGroupsClient { - subClient, _ := NewClientGroupsClient(c.subscriptionID, c.credential, c.options) - return subClient + return &ClientGroupsClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewClientsClient creates a new instance of ClientsClient. func (c *ClientFactory) NewClientsClient() *ClientsClient { - subClient, _ := NewClientsClient(c.subscriptionID, c.credential, c.options) - return subClient + return &ClientsClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewDomainEventSubscriptionsClient creates a new instance of DomainEventSubscriptionsClient. func (c *ClientFactory) NewDomainEventSubscriptionsClient() *DomainEventSubscriptionsClient { - subClient, _ := NewDomainEventSubscriptionsClient(c.subscriptionID, c.credential, c.options) - return subClient + return &DomainEventSubscriptionsClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewDomainTopicEventSubscriptionsClient creates a new instance of DomainTopicEventSubscriptionsClient. func (c *ClientFactory) NewDomainTopicEventSubscriptionsClient() *DomainTopicEventSubscriptionsClient { - subClient, _ := NewDomainTopicEventSubscriptionsClient(c.subscriptionID, c.credential, c.options) - return subClient + return &DomainTopicEventSubscriptionsClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewDomainTopicsClient creates a new instance of DomainTopicsClient. func (c *ClientFactory) NewDomainTopicsClient() *DomainTopicsClient { - subClient, _ := NewDomainTopicsClient(c.subscriptionID, c.credential, c.options) - return subClient + return &DomainTopicsClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewDomainsClient creates a new instance of DomainsClient. func (c *ClientFactory) NewDomainsClient() *DomainsClient { - subClient, _ := NewDomainsClient(c.subscriptionID, c.credential, c.options) - return subClient + return &DomainsClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewEventSubscriptionsClient creates a new instance of EventSubscriptionsClient. func (c *ClientFactory) NewEventSubscriptionsClient() *EventSubscriptionsClient { - subClient, _ := NewEventSubscriptionsClient(c.subscriptionID, c.credential, c.options) - return subClient + return &EventSubscriptionsClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewExtensionTopicsClient creates a new instance of ExtensionTopicsClient. func (c *ClientFactory) NewExtensionTopicsClient() *ExtensionTopicsClient { - subClient, _ := NewExtensionTopicsClient(c.credential, c.options) - return subClient + return &ExtensionTopicsClient{ + internal: c.internal, + } } // NewNamespaceTopicEventSubscriptionsClient creates a new instance of NamespaceTopicEventSubscriptionsClient. func (c *ClientFactory) NewNamespaceTopicEventSubscriptionsClient() *NamespaceTopicEventSubscriptionsClient { - subClient, _ := NewNamespaceTopicEventSubscriptionsClient(c.subscriptionID, c.credential, c.options) - return subClient + return &NamespaceTopicEventSubscriptionsClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewNamespaceTopicsClient creates a new instance of NamespaceTopicsClient. func (c *ClientFactory) NewNamespaceTopicsClient() *NamespaceTopicsClient { - subClient, _ := NewNamespaceTopicsClient(c.subscriptionID, c.credential, c.options) - return subClient + return &NamespaceTopicsClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewNamespacesClient creates a new instance of NamespacesClient. func (c *ClientFactory) NewNamespacesClient() *NamespacesClient { - subClient, _ := NewNamespacesClient(c.subscriptionID, c.credential, c.options) - return subClient + return &NamespacesClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewNetworkSecurityPerimeterConfigurationsClient creates a new instance of NetworkSecurityPerimeterConfigurationsClient. func (c *ClientFactory) NewNetworkSecurityPerimeterConfigurationsClient() *NetworkSecurityPerimeterConfigurationsClient { - subClient, _ := NewNetworkSecurityPerimeterConfigurationsClient(c.subscriptionID, c.credential, c.options) - return subClient + return &NetworkSecurityPerimeterConfigurationsClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewOperationsClient creates a new instance of OperationsClient. func (c *ClientFactory) NewOperationsClient() *OperationsClient { - subClient, _ := NewOperationsClient(c.credential, c.options) - return subClient + return &OperationsClient{ + internal: c.internal, + } } // NewPartnerConfigurationsClient creates a new instance of PartnerConfigurationsClient. func (c *ClientFactory) NewPartnerConfigurationsClient() *PartnerConfigurationsClient { - subClient, _ := NewPartnerConfigurationsClient(c.subscriptionID, c.credential, c.options) - return subClient + return &PartnerConfigurationsClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewPartnerDestinationsClient creates a new instance of PartnerDestinationsClient. func (c *ClientFactory) NewPartnerDestinationsClient() *PartnerDestinationsClient { - subClient, _ := NewPartnerDestinationsClient(c.subscriptionID, c.credential, c.options) - return subClient + return &PartnerDestinationsClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewPartnerNamespacesClient creates a new instance of PartnerNamespacesClient. func (c *ClientFactory) NewPartnerNamespacesClient() *PartnerNamespacesClient { - subClient, _ := NewPartnerNamespacesClient(c.subscriptionID, c.credential, c.options) - return subClient + return &PartnerNamespacesClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewPartnerRegistrationsClient creates a new instance of PartnerRegistrationsClient. func (c *ClientFactory) NewPartnerRegistrationsClient() *PartnerRegistrationsClient { - subClient, _ := NewPartnerRegistrationsClient(c.subscriptionID, c.credential, c.options) - return subClient + return &PartnerRegistrationsClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewPartnerTopicEventSubscriptionsClient creates a new instance of PartnerTopicEventSubscriptionsClient. func (c *ClientFactory) NewPartnerTopicEventSubscriptionsClient() *PartnerTopicEventSubscriptionsClient { - subClient, _ := NewPartnerTopicEventSubscriptionsClient(c.subscriptionID, c.credential, c.options) - return subClient + return &PartnerTopicEventSubscriptionsClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewPartnerTopicsClient creates a new instance of PartnerTopicsClient. func (c *ClientFactory) NewPartnerTopicsClient() *PartnerTopicsClient { - subClient, _ := NewPartnerTopicsClient(c.subscriptionID, c.credential, c.options) - return subClient + return &PartnerTopicsClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewPermissionBindingsClient creates a new instance of PermissionBindingsClient. func (c *ClientFactory) NewPermissionBindingsClient() *PermissionBindingsClient { - subClient, _ := NewPermissionBindingsClient(c.subscriptionID, c.credential, c.options) - return subClient + return &PermissionBindingsClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewPrivateEndpointConnectionsClient creates a new instance of PrivateEndpointConnectionsClient. func (c *ClientFactory) NewPrivateEndpointConnectionsClient() *PrivateEndpointConnectionsClient { - subClient, _ := NewPrivateEndpointConnectionsClient(c.subscriptionID, c.credential, c.options) - return subClient + return &PrivateEndpointConnectionsClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewPrivateLinkResourcesClient creates a new instance of PrivateLinkResourcesClient. func (c *ClientFactory) NewPrivateLinkResourcesClient() *PrivateLinkResourcesClient { - subClient, _ := NewPrivateLinkResourcesClient(c.subscriptionID, c.credential, c.options) - return subClient + return &PrivateLinkResourcesClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewSystemTopicEventSubscriptionsClient creates a new instance of SystemTopicEventSubscriptionsClient. func (c *ClientFactory) NewSystemTopicEventSubscriptionsClient() *SystemTopicEventSubscriptionsClient { - subClient, _ := NewSystemTopicEventSubscriptionsClient(c.subscriptionID, c.credential, c.options) - return subClient + return &SystemTopicEventSubscriptionsClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewSystemTopicsClient creates a new instance of SystemTopicsClient. func (c *ClientFactory) NewSystemTopicsClient() *SystemTopicsClient { - subClient, _ := NewSystemTopicsClient(c.subscriptionID, c.credential, c.options) - return subClient + return &SystemTopicsClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewTopicEventSubscriptionsClient creates a new instance of TopicEventSubscriptionsClient. func (c *ClientFactory) NewTopicEventSubscriptionsClient() *TopicEventSubscriptionsClient { - subClient, _ := NewTopicEventSubscriptionsClient(c.subscriptionID, c.credential, c.options) - return subClient + return &TopicEventSubscriptionsClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewTopicSpacesClient creates a new instance of TopicSpacesClient. func (c *ClientFactory) NewTopicSpacesClient() *TopicSpacesClient { - subClient, _ := NewTopicSpacesClient(c.subscriptionID, c.credential, c.options) - return subClient + return &TopicSpacesClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewTopicTypesClient creates a new instance of TopicTypesClient. func (c *ClientFactory) NewTopicTypesClient() *TopicTypesClient { - subClient, _ := NewTopicTypesClient(c.credential, c.options) - return subClient + return &TopicTypesClient{ + internal: c.internal, + } } // NewTopicsClient creates a new instance of TopicsClient. func (c *ClientFactory) NewTopicsClient() *TopicsClient { - subClient, _ := NewTopicsClient(c.subscriptionID, c.credential, c.options) - return subClient + return &TopicsClient{ + subscriptionID: c.subscriptionID, + internal: c.internal, + } } // NewVerifiedPartnersClient creates a new instance of VerifiedPartnersClient. func (c *ClientFactory) NewVerifiedPartnersClient() *VerifiedPartnersClient { - subClient, _ := NewVerifiedPartnersClient(c.credential, c.options) - return subClient + return &VerifiedPartnersClient{ + internal: c.internal, + } } diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/clientgroups_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/clientgroups_client.go index 09e1a1970464..cfebfffcbe04 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/clientgroups_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/clientgroups_client.go @@ -48,7 +48,7 @@ func NewClientGroupsClient(subscriptionID string, credential azcore.TokenCredent // BeginCreateOrUpdate - Create or update a client group with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - clientGroupName - The client group name. @@ -76,7 +76,7 @@ func (client *ClientGroupsClient) BeginCreateOrUpdate(ctx context.Context, resou // CreateOrUpdate - Create or update a client group with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *ClientGroupsClient) createOrUpdate(ctx context.Context, resourceGroupName string, namespaceName string, clientGroupName string, clientGroupInfo ClientGroup, options *ClientGroupsClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "ClientGroupsClient.BeginCreateOrUpdate" @@ -122,7 +122,7 @@ func (client *ClientGroupsClient) createOrUpdateCreateRequest(ctx context.Contex return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, clientGroupInfo); err != nil { @@ -134,7 +134,7 @@ func (client *ClientGroupsClient) createOrUpdateCreateRequest(ctx context.Contex // BeginDelete - Delete an existing client group. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - clientGroupName - Name of the client group. @@ -161,7 +161,7 @@ func (client *ClientGroupsClient) BeginDelete(ctx context.Context, resourceGroup // Delete - Delete an existing client group. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *ClientGroupsClient) deleteOperation(ctx context.Context, resourceGroupName string, namespaceName string, clientGroupName string, options *ClientGroupsClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "ClientGroupsClient.BeginDelete" @@ -207,7 +207,7 @@ func (client *ClientGroupsClient) deleteCreateRequest(ctx context.Context, resou return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -216,7 +216,7 @@ func (client *ClientGroupsClient) deleteCreateRequest(ctx context.Context, resou // Get - Get properties of a client group. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - clientGroupName - Name of the client group. @@ -267,7 +267,7 @@ func (client *ClientGroupsClient) getCreateRequest(ctx context.Context, resource return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -284,7 +284,7 @@ func (client *ClientGroupsClient) getHandleResponse(resp *http.Response) (Client // NewListByNamespacePager - Get all the client groups under a namespace. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - options - ClientGroupsClientListByNamespaceOptions contains the optional parameters for the ClientGroupsClient.NewListByNamespacePager @@ -332,13 +332,13 @@ func (client *ClientGroupsClient) listByNamespaceCreateRequest(ctx context.Conte return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/clientgroups_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/clientgroups_client_example_test.go index a09902ce9980..6bf3d20758e9 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/clientgroups_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/clientgroups_client_example_test.go @@ -18,7 +18,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/ClientGroups_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/ClientGroups_Get.json func ExampleClientGroupsClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -47,7 +47,7 @@ func ExampleClientGroupsClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/ClientGroups_CreateOrUpdate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/ClientGroups_CreateOrUpdate.json func ExampleClientGroupsClient_BeginCreateOrUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -85,7 +85,7 @@ func ExampleClientGroupsClient_BeginCreateOrUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/ClientGroups_Delete.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/ClientGroups_Delete.json func ExampleClientGroupsClient_BeginDelete() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -106,7 +106,7 @@ func ExampleClientGroupsClient_BeginDelete() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/ClientGroups_ListByNamespace.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/ClientGroups_ListByNamespace.json func ExampleClientGroupsClient_NewListByNamespacePager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/clients_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/clients_client.go index 9fae4b1729fe..a272052ba6d5 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/clients_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/clients_client.go @@ -48,7 +48,7 @@ func NewClientsClient(subscriptionID string, credential azcore.TokenCredential, // BeginCreateOrUpdate - Create or update a client with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - clientName - The client name. @@ -76,7 +76,7 @@ func (client *ClientsClient) BeginCreateOrUpdate(ctx context.Context, resourceGr // CreateOrUpdate - Create or update a client with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *ClientsClient) createOrUpdate(ctx context.Context, resourceGroupName string, namespaceName string, clientName string, clientInfo Client, options *ClientsClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "ClientsClient.BeginCreateOrUpdate" @@ -122,7 +122,7 @@ func (client *ClientsClient) createOrUpdateCreateRequest(ctx context.Context, re return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, clientInfo); err != nil { @@ -134,7 +134,7 @@ func (client *ClientsClient) createOrUpdateCreateRequest(ctx context.Context, re // BeginDelete - Delete an existing client. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - clientName - Name of the client. @@ -160,7 +160,7 @@ func (client *ClientsClient) BeginDelete(ctx context.Context, resourceGroupName // Delete - Delete an existing client. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *ClientsClient) deleteOperation(ctx context.Context, resourceGroupName string, namespaceName string, clientName string, options *ClientsClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "ClientsClient.BeginDelete" @@ -206,7 +206,7 @@ func (client *ClientsClient) deleteCreateRequest(ctx context.Context, resourceGr return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -215,7 +215,7 @@ func (client *ClientsClient) deleteCreateRequest(ctx context.Context, resourceGr // Get - Get properties of a client. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - clientName - Name of the client. @@ -266,7 +266,7 @@ func (client *ClientsClient) getCreateRequest(ctx context.Context, resourceGroup return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -283,7 +283,7 @@ func (client *ClientsClient) getHandleResponse(resp *http.Response) (ClientsClie // NewListByNamespacePager - Get all the permission bindings under a namespace. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - options - ClientsClientListByNamespaceOptions contains the optional parameters for the ClientsClient.NewListByNamespacePager @@ -331,13 +331,13 @@ func (client *ClientsClient) listByNamespaceCreateRequest(ctx context.Context, r return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/clients_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/clients_client_example_test.go index eeb63589d445..51e5506b8062 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/clients_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/clients_client_example_test.go @@ -18,7 +18,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Clients_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Clients_Get.json func ExampleClientsClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -59,7 +59,7 @@ func ExampleClientsClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Clients_CreateOrUpdate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Clients_CreateOrUpdate.json func ExampleClientsClient_BeginCreateOrUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -121,7 +121,7 @@ func ExampleClientsClient_BeginCreateOrUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Clients_Delete.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Clients_Delete.json func ExampleClientsClient_BeginDelete() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -142,7 +142,7 @@ func ExampleClientsClient_BeginDelete() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Clients_ListByNamespace.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Clients_ListByNamespace.json func ExampleClientsClient_NewListByNamespacePager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/constants.go b/sdk/resourcemanager/eventgrid/armeventgrid/constants.go index 08805459b6d8..49e1e4bca0e2 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/constants.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/constants.go @@ -10,7 +10,7 @@ package armeventgrid const ( moduleName = "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid" - moduleVersion = "v2.3.0-beta.1" + moduleVersion = "v2.3.0-beta.2" ) // AdvancedFilterOperatorType - The operator type used for filtering, e.g., NumberIn, StringContains, BoolEquals and others. @@ -63,6 +63,8 @@ func PossibleAdvancedFilterOperatorTypeValues() []AdvancedFilterOperatorType { } } +// AlternativeAuthenticationNameSource - Alternative authentication name sources related to client authentication settings +// for namespace resource. type AlternativeAuthenticationNameSource string const ( @@ -266,6 +268,58 @@ func PossibleCreatedByTypeValues() []CreatedByType { } } +// CustomDomainIdentityType - The type of managed identity used. Can be either 'SystemAssigned' or 'UserAssigned'. +type CustomDomainIdentityType string + +const ( + CustomDomainIdentityTypeSystemAssigned CustomDomainIdentityType = "SystemAssigned" + CustomDomainIdentityTypeUserAssigned CustomDomainIdentityType = "UserAssigned" +) + +// PossibleCustomDomainIdentityTypeValues returns the possible values for the CustomDomainIdentityType const type. +func PossibleCustomDomainIdentityTypeValues() []CustomDomainIdentityType { + return []CustomDomainIdentityType{ + CustomDomainIdentityTypeSystemAssigned, + CustomDomainIdentityTypeUserAssigned, + } +} + +// CustomDomainValidationState - Validation state for the custom domain. This is a read only property and is initially set +// to 'Pending' and will be updated to 'Approved' by Event Grid only after ownership of the domain name has been +// successfully validated. +type CustomDomainValidationState string + +const ( + CustomDomainValidationStateApproved CustomDomainValidationState = "Approved" + CustomDomainValidationStateErrorRetrievingDNSRecord CustomDomainValidationState = "ErrorRetrievingDnsRecord" + CustomDomainValidationStatePending CustomDomainValidationState = "Pending" +) + +// PossibleCustomDomainValidationStateValues returns the possible values for the CustomDomainValidationState const type. +func PossibleCustomDomainValidationStateValues() []CustomDomainValidationState { + return []CustomDomainValidationState{ + CustomDomainValidationStateApproved, + CustomDomainValidationStateErrorRetrievingDNSRecord, + CustomDomainValidationStatePending, + } +} + +// CustomJwtAuthenticationManagedIdentityType - The type of managed identity used. Can be either 'SystemAssigned' or 'UserAssigned'. +type CustomJwtAuthenticationManagedIdentityType string + +const ( + CustomJwtAuthenticationManagedIdentityTypeSystemAssigned CustomJwtAuthenticationManagedIdentityType = "SystemAssigned" + CustomJwtAuthenticationManagedIdentityTypeUserAssigned CustomJwtAuthenticationManagedIdentityType = "UserAssigned" +) + +// PossibleCustomJwtAuthenticationManagedIdentityTypeValues returns the possible values for the CustomJwtAuthenticationManagedIdentityType const type. +func PossibleCustomJwtAuthenticationManagedIdentityTypeValues() []CustomJwtAuthenticationManagedIdentityType { + return []CustomJwtAuthenticationManagedIdentityType{ + CustomJwtAuthenticationManagedIdentityTypeSystemAssigned, + CustomJwtAuthenticationManagedIdentityTypeUserAssigned, + } +} + // DataResidencyBoundary - Data Residency Boundary of the resource. type DataResidencyBoundary string @@ -468,8 +522,7 @@ func PossibleEventInputSchemaValues() []EventInputSchema { } } -// EventSubscriptionIdentityType - The type of managed identity used. The type 'SystemAssigned, UserAssigned' includes both -// an implicitly created identity and a set of user-assigned identities. The type 'None' will remove any identity. +// EventSubscriptionIdentityType - The type of managed identity used. Can be either 'SystemAssigned' or 'UserAssigned'. type EventSubscriptionIdentityType string const ( @@ -1220,6 +1273,7 @@ func PossibleResourceRegionTypeValues() []ResourceRegionType { } } +// RoutingIdentityType - Routing identity type for topic spaces configuration. type RoutingIdentityType string const ( diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/domaineventsubscriptions_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/domaineventsubscriptions_client.go index 7c71db9067cc..c408e8660dd4 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/domaineventsubscriptions_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/domaineventsubscriptions_client.go @@ -48,10 +48,10 @@ func NewDomainEventSubscriptionsClient(subscriptionID string, credential azcore. // BeginCreateOrUpdate - Asynchronously creates a new event subscription or updates an existing event subscription. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Name of the domain topic. -// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 100 +// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 64 // characters in length and use alphanumeric letters only. // - eventSubscriptionInfo - Event subscription properties containing the destination and filter information. // - options - DomainEventSubscriptionsClientBeginCreateOrUpdateOptions contains the optional parameters for the DomainEventSubscriptionsClient.BeginCreateOrUpdate @@ -76,7 +76,7 @@ func (client *DomainEventSubscriptionsClient) BeginCreateOrUpdate(ctx context.Co // CreateOrUpdate - Asynchronously creates a new event subscription or updates an existing event subscription. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *DomainEventSubscriptionsClient) createOrUpdate(ctx context.Context, resourceGroupName string, domainName string, eventSubscriptionName string, eventSubscriptionInfo EventSubscription, options *DomainEventSubscriptionsClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "DomainEventSubscriptionsClient.BeginCreateOrUpdate" @@ -122,7 +122,7 @@ func (client *DomainEventSubscriptionsClient) createOrUpdateCreateRequest(ctx co return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, eventSubscriptionInfo); err != nil { @@ -134,11 +134,10 @@ func (client *DomainEventSubscriptionsClient) createOrUpdateCreateRequest(ctx co // BeginDelete - Delete an existing event subscription for a domain. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Name of the domain. -// - eventSubscriptionName - Name of the event subscription to be deleted. Event subscription names must be between 3 and 100 -// characters in length and use alphanumeric letters only. +// - eventSubscriptionName - Name of the event subscription to be deleted. // - options - DomainEventSubscriptionsClientBeginDeleteOptions contains the optional parameters for the DomainEventSubscriptionsClient.BeginDelete // method. func (client *DomainEventSubscriptionsClient) BeginDelete(ctx context.Context, resourceGroupName string, domainName string, eventSubscriptionName string, options *DomainEventSubscriptionsClientBeginDeleteOptions) (*runtime.Poller[DomainEventSubscriptionsClientDeleteResponse], error) { @@ -161,7 +160,7 @@ func (client *DomainEventSubscriptionsClient) BeginDelete(ctx context.Context, r // Delete - Delete an existing event subscription for a domain. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *DomainEventSubscriptionsClient) deleteOperation(ctx context.Context, resourceGroupName string, domainName string, eventSubscriptionName string, options *DomainEventSubscriptionsClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "DomainEventSubscriptionsClient.BeginDelete" @@ -207,7 +206,7 @@ func (client *DomainEventSubscriptionsClient) deleteCreateRequest(ctx context.Co return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() return req, nil } @@ -215,11 +214,10 @@ func (client *DomainEventSubscriptionsClient) deleteCreateRequest(ctx context.Co // Get - Get properties of an event subscription of a domain. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Name of the domain. -// - eventSubscriptionName - Name of the event subscription to be found. Event subscription names must be between 3 and 100 -// characters in length and use alphanumeric letters only. +// - eventSubscriptionName - Name of the event subscription to be found. // - options - DomainEventSubscriptionsClientGetOptions contains the optional parameters for the DomainEventSubscriptionsClient.Get // method. func (client *DomainEventSubscriptionsClient) Get(ctx context.Context, resourceGroupName string, domainName string, eventSubscriptionName string, options *DomainEventSubscriptionsClientGetOptions) (DomainEventSubscriptionsClientGetResponse, error) { @@ -268,7 +266,7 @@ func (client *DomainEventSubscriptionsClient) getCreateRequest(ctx context.Conte return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -286,7 +284,7 @@ func (client *DomainEventSubscriptionsClient) getHandleResponse(resp *http.Respo // GetDeliveryAttributes - Get all delivery attributes for an event subscription for domain. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Name of the domain. // - eventSubscriptionName - Name of the event subscription. @@ -338,7 +336,7 @@ func (client *DomainEventSubscriptionsClient) getDeliveryAttributesCreateRequest return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -356,7 +354,7 @@ func (client *DomainEventSubscriptionsClient) getDeliveryAttributesHandleRespons // GetFullURL - Get the full endpoint URL for an event subscription for domain. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Name of the domain topic. // - eventSubscriptionName - Name of the event subscription. @@ -408,7 +406,7 @@ func (client *DomainEventSubscriptionsClient) getFullURLCreateRequest(ctx contex return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -425,7 +423,7 @@ func (client *DomainEventSubscriptionsClient) getFullURLHandleResponse(resp *htt // NewListPager - List all event subscriptions that have been created for a specific topic. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Name of the domain. // - options - DomainEventSubscriptionsClientListOptions contains the optional parameters for the DomainEventSubscriptionsClient.NewListPager @@ -473,13 +471,13 @@ func (client *DomainEventSubscriptionsClient) listCreateRequest(ctx context.Cont return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -497,7 +495,7 @@ func (client *DomainEventSubscriptionsClient) listHandleResponse(resp *http.Resp // BeginUpdate - Update an existing event subscription for a topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Name of the domain. // - eventSubscriptionName - Name of the event subscription to be updated. @@ -524,7 +522,7 @@ func (client *DomainEventSubscriptionsClient) BeginUpdate(ctx context.Context, r // Update - Update an existing event subscription for a topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *DomainEventSubscriptionsClient) update(ctx context.Context, resourceGroupName string, domainName string, eventSubscriptionName string, eventSubscriptionUpdateParameters EventSubscriptionUpdateParameters, options *DomainEventSubscriptionsClientBeginUpdateOptions) (*http.Response, error) { var err error const operationName = "DomainEventSubscriptionsClient.BeginUpdate" @@ -570,7 +568,7 @@ func (client *DomainEventSubscriptionsClient) updateCreateRequest(ctx context.Co return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, eventSubscriptionUpdateParameters); err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/domaineventsubscriptions_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/domaineventsubscriptions_client_example_test.go index 80353903a3ef..f4f914c61eda 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/domaineventsubscriptions_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/domaineventsubscriptions_client_example_test.go @@ -18,7 +18,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/DomainEventSubscriptions_GetDeliveryAttributes.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/DomainEventSubscriptions_GetDeliveryAttributes.json func ExampleDomainEventSubscriptionsClient_GetDeliveryAttributes() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -64,7 +64,7 @@ func ExampleDomainEventSubscriptionsClient_GetDeliveryAttributes() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/DomainEventSubscriptions_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/DomainEventSubscriptions_Get.json func ExampleDomainEventSubscriptionsClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -116,7 +116,7 @@ func ExampleDomainEventSubscriptionsClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/DomainEventSubscriptions_CreateOrUpdate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/DomainEventSubscriptions_CreateOrUpdate.json func ExampleDomainEventSubscriptionsClient_BeginCreateOrUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -179,7 +179,7 @@ func ExampleDomainEventSubscriptionsClient_BeginCreateOrUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/DomainEventSubscriptions_Delete.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/DomainEventSubscriptions_Delete.json func ExampleDomainEventSubscriptionsClient_BeginDelete() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -200,7 +200,7 @@ func ExampleDomainEventSubscriptionsClient_BeginDelete() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/DomainEventSubscriptions_Update.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/DomainEventSubscriptions_Update.json func ExampleDomainEventSubscriptionsClient_BeginUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -236,7 +236,7 @@ func ExampleDomainEventSubscriptionsClient_BeginUpdate() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/DomainEventSubscriptions_GetFullUrl.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/DomainEventSubscriptions_GetFullUrl.json func ExampleDomainEventSubscriptionsClient_GetFullURL() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -259,7 +259,7 @@ func ExampleDomainEventSubscriptionsClient_GetFullURL() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/DomainEventSubscriptions_List.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/DomainEventSubscriptions_List.json func ExampleDomainEventSubscriptionsClient_NewListPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/domains_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/domains_client.go index ed7744997e0f..e6dea2ea6e84 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/domains_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/domains_client.go @@ -48,7 +48,7 @@ func NewDomainsClient(subscriptionID string, credential azcore.TokenCredential, // BeginCreateOrUpdate - Asynchronously creates or updates a new domain with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Name of the domain. // - domainInfo - Domain information. @@ -74,7 +74,7 @@ func (client *DomainsClient) BeginCreateOrUpdate(ctx context.Context, resourceGr // CreateOrUpdate - Asynchronously creates or updates a new domain with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *DomainsClient) createOrUpdate(ctx context.Context, resourceGroupName string, domainName string, domainInfo Domain, options *DomainsClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "DomainsClient.BeginCreateOrUpdate" @@ -116,7 +116,7 @@ func (client *DomainsClient) createOrUpdateCreateRequest(ctx context.Context, re return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, domainInfo); err != nil { @@ -128,7 +128,7 @@ func (client *DomainsClient) createOrUpdateCreateRequest(ctx context.Context, re // BeginDelete - Delete existing domain. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Name of the domain. // - options - DomainsClientBeginDeleteOptions contains the optional parameters for the DomainsClient.BeginDelete method. @@ -152,7 +152,7 @@ func (client *DomainsClient) BeginDelete(ctx context.Context, resourceGroupName // Delete - Delete existing domain. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *DomainsClient) deleteOperation(ctx context.Context, resourceGroupName string, domainName string, options *DomainsClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "DomainsClient.BeginDelete" @@ -194,7 +194,7 @@ func (client *DomainsClient) deleteCreateRequest(ctx context.Context, resourceGr return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() return req, nil } @@ -202,7 +202,7 @@ func (client *DomainsClient) deleteCreateRequest(ctx context.Context, resourceGr // Get - Get properties of a domain. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Name of the domain. // - options - DomainsClientGetOptions contains the optional parameters for the DomainsClient.Get method. @@ -248,7 +248,7 @@ func (client *DomainsClient) getCreateRequest(ctx context.Context, resourceGroup return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -265,7 +265,7 @@ func (client *DomainsClient) getHandleResponse(resp *http.Response) (DomainsClie // NewListByResourceGroupPager - List all the domains under a resource group. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - options - DomainsClientListByResourceGroupOptions contains the optional parameters for the DomainsClient.NewListByResourceGroupPager // method. @@ -308,13 +308,13 @@ func (client *DomainsClient) listByResourceGroupCreateRequest(ctx context.Contex return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -331,7 +331,7 @@ func (client *DomainsClient) listByResourceGroupHandleResponse(resp *http.Respon // NewListBySubscriptionPager - List all the domains under an Azure subscription. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - options - DomainsClientListBySubscriptionOptions contains the optional parameters for the DomainsClient.NewListBySubscriptionPager // method. func (client *DomainsClient) NewListBySubscriptionPager(options *DomainsClientListBySubscriptionOptions) *runtime.Pager[DomainsClientListBySubscriptionResponse] { @@ -369,13 +369,13 @@ func (client *DomainsClient) listBySubscriptionCreateRequest(ctx context.Context return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -393,7 +393,7 @@ func (client *DomainsClient) listBySubscriptionHandleResponse(resp *http.Respons // ListSharedAccessKeys - List the two keys used to publish to a domain. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Name of the domain. // - options - DomainsClientListSharedAccessKeysOptions contains the optional parameters for the DomainsClient.ListSharedAccessKeys @@ -440,7 +440,7 @@ func (client *DomainsClient) listSharedAccessKeysCreateRequest(ctx context.Conte return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -458,7 +458,7 @@ func (client *DomainsClient) listSharedAccessKeysHandleResponse(resp *http.Respo // RegenerateKey - Regenerate a shared access key for a domain. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Name of the domain. // - regenerateKeyRequest - Request body to regenerate key. @@ -505,7 +505,7 @@ func (client *DomainsClient) regenerateKeyCreateRequest(ctx context.Context, res return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, regenerateKeyRequest); err != nil { @@ -526,7 +526,7 @@ func (client *DomainsClient) regenerateKeyHandleResponse(resp *http.Response) (D // BeginUpdate - Asynchronously updates a domain with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Name of the domain. // - domainUpdateParameters - Domain update information. @@ -551,7 +551,7 @@ func (client *DomainsClient) BeginUpdate(ctx context.Context, resourceGroupName // Update - Asynchronously updates a domain with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *DomainsClient) update(ctx context.Context, resourceGroupName string, domainName string, domainUpdateParameters DomainUpdateParameters, options *DomainsClientBeginUpdateOptions) (*http.Response, error) { var err error const operationName = "DomainsClient.BeginUpdate" @@ -593,7 +593,7 @@ func (client *DomainsClient) updateCreateRequest(ctx context.Context, resourceGr return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, domainUpdateParameters); err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/domains_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/domains_client_example_test.go index 1c6de2812535..9d3d5ca0609f 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/domains_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/domains_client_example_test.go @@ -18,7 +18,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Domains_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Domains_Get.json func ExampleDomainsClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -52,7 +52,7 @@ func ExampleDomainsClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Domains_CreateOrUpdate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Domains_CreateOrUpdate.json func ExampleDomainsClient_BeginCreateOrUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -91,7 +91,7 @@ func ExampleDomainsClient_BeginCreateOrUpdate() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Domains_Delete.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Domains_Delete.json func ExampleDomainsClient_BeginDelete() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -112,7 +112,7 @@ func ExampleDomainsClient_BeginDelete() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Domains_Update.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Domains_Update.json func ExampleDomainsClient_BeginUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -150,7 +150,7 @@ func ExampleDomainsClient_BeginUpdate() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Domains_ListBySubscription.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Domains_ListBySubscription.json func ExampleDomainsClient_NewListBySubscriptionPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -208,7 +208,7 @@ func ExampleDomainsClient_NewListBySubscriptionPager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Domains_ListByResourceGroup.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Domains_ListByResourceGroup.json func ExampleDomainsClient_NewListByResourceGroupPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -266,7 +266,7 @@ func ExampleDomainsClient_NewListByResourceGroupPager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Domains_ListSharedAccessKeys.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Domains_ListSharedAccessKeys.json func ExampleDomainsClient_ListSharedAccessKeys() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -290,7 +290,7 @@ func ExampleDomainsClient_ListSharedAccessKeys() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Domains_RegenerateKey.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Domains_RegenerateKey.json func ExampleDomainsClient_RegenerateKey() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/domaintopiceventsubscriptions_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/domaintopiceventsubscriptions_client.go index 7b3b73c377cc..9e6fb09e5cce 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/domaintopiceventsubscriptions_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/domaintopiceventsubscriptions_client.go @@ -48,11 +48,11 @@ func NewDomainTopicEventSubscriptionsClient(subscriptionID string, credential az // BeginCreateOrUpdate - Asynchronously creates a new event subscription or updates an existing event subscription. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Name of the top level domain. // - topicName - Name of the domain topic. -// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 100 +// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 64 // characters in length and use alphanumeric letters only. // - eventSubscriptionInfo - Event subscription properties containing the destination and filter information. // - options - DomainTopicEventSubscriptionsClientBeginCreateOrUpdateOptions contains the optional parameters for the DomainTopicEventSubscriptionsClient.BeginCreateOrUpdate @@ -77,7 +77,7 @@ func (client *DomainTopicEventSubscriptionsClient) BeginCreateOrUpdate(ctx conte // CreateOrUpdate - Asynchronously creates a new event subscription or updates an existing event subscription. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *DomainTopicEventSubscriptionsClient) createOrUpdate(ctx context.Context, resourceGroupName string, domainName string, topicName string, eventSubscriptionName string, eventSubscriptionInfo EventSubscription, options *DomainTopicEventSubscriptionsClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "DomainTopicEventSubscriptionsClient.BeginCreateOrUpdate" @@ -127,7 +127,7 @@ func (client *DomainTopicEventSubscriptionsClient) createOrUpdateCreateRequest(c return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, eventSubscriptionInfo); err != nil { @@ -139,12 +139,11 @@ func (client *DomainTopicEventSubscriptionsClient) createOrUpdateCreateRequest(c // BeginDelete - Delete a nested existing event subscription for a domain topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Name of the top level domain. // - topicName - Name of the domain topic. -// - eventSubscriptionName - Name of the event subscription to be deleted. Event subscription names must be between 3 and 100 -// characters in length and use alphanumeric letters only. +// - eventSubscriptionName - Name of the event subscription to be deleted. // - options - DomainTopicEventSubscriptionsClientBeginDeleteOptions contains the optional parameters for the DomainTopicEventSubscriptionsClient.BeginDelete // method. func (client *DomainTopicEventSubscriptionsClient) BeginDelete(ctx context.Context, resourceGroupName string, domainName string, topicName string, eventSubscriptionName string, options *DomainTopicEventSubscriptionsClientBeginDeleteOptions) (*runtime.Poller[DomainTopicEventSubscriptionsClientDeleteResponse], error) { @@ -167,7 +166,7 @@ func (client *DomainTopicEventSubscriptionsClient) BeginDelete(ctx context.Conte // Delete - Delete a nested existing event subscription for a domain topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *DomainTopicEventSubscriptionsClient) deleteOperation(ctx context.Context, resourceGroupName string, domainName string, topicName string, eventSubscriptionName string, options *DomainTopicEventSubscriptionsClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "DomainTopicEventSubscriptionsClient.BeginDelete" @@ -217,7 +216,7 @@ func (client *DomainTopicEventSubscriptionsClient) deleteCreateRequest(ctx conte return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() return req, nil } @@ -225,11 +224,11 @@ func (client *DomainTopicEventSubscriptionsClient) deleteCreateRequest(ctx conte // Get - Get properties of a nested event subscription for a domain topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Name of the top level domain. // - topicName - Name of the domain topic. -// - eventSubscriptionName - Name of the event subscription. +// - eventSubscriptionName - Name of the event subscription to be found. // - options - DomainTopicEventSubscriptionsClientGetOptions contains the optional parameters for the DomainTopicEventSubscriptionsClient.Get // method. func (client *DomainTopicEventSubscriptionsClient) Get(ctx context.Context, resourceGroupName string, domainName string, topicName string, eventSubscriptionName string, options *DomainTopicEventSubscriptionsClientGetOptions) (DomainTopicEventSubscriptionsClientGetResponse, error) { @@ -282,7 +281,7 @@ func (client *DomainTopicEventSubscriptionsClient) getCreateRequest(ctx context. return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -300,7 +299,7 @@ func (client *DomainTopicEventSubscriptionsClient) getHandleResponse(resp *http. // GetDeliveryAttributes - Get all delivery attributes for an event subscription for domain topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Name of the top level domain. // - topicName - Name of the domain topic. @@ -357,7 +356,7 @@ func (client *DomainTopicEventSubscriptionsClient) getDeliveryAttributesCreateRe return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -375,7 +374,7 @@ func (client *DomainTopicEventSubscriptionsClient) getDeliveryAttributesHandleRe // GetFullURL - Get the full endpoint URL for a nested event subscription for domain topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Name of the top level domain. // - topicName - Name of the domain topic. @@ -432,7 +431,7 @@ func (client *DomainTopicEventSubscriptionsClient) getFullURLCreateRequest(ctx c return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -449,7 +448,7 @@ func (client *DomainTopicEventSubscriptionsClient) getFullURLHandleResponse(resp // NewListPager - List all event subscriptions that have been created for a specific domain topic. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Name of the top level domain. // - topicName - Name of the domain topic. @@ -502,13 +501,13 @@ func (client *DomainTopicEventSubscriptionsClient) listCreateRequest(ctx context return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -526,7 +525,7 @@ func (client *DomainTopicEventSubscriptionsClient) listHandleResponse(resp *http // BeginUpdate - Update an existing event subscription for a domain topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Name of the domain. // - topicName - Name of the topic. @@ -554,7 +553,7 @@ func (client *DomainTopicEventSubscriptionsClient) BeginUpdate(ctx context.Conte // Update - Update an existing event subscription for a domain topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *DomainTopicEventSubscriptionsClient) update(ctx context.Context, resourceGroupName string, domainName string, topicName string, eventSubscriptionName string, eventSubscriptionUpdateParameters EventSubscriptionUpdateParameters, options *DomainTopicEventSubscriptionsClientBeginUpdateOptions) (*http.Response, error) { var err error const operationName = "DomainTopicEventSubscriptionsClient.BeginUpdate" @@ -604,7 +603,7 @@ func (client *DomainTopicEventSubscriptionsClient) updateCreateRequest(ctx conte return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, eventSubscriptionUpdateParameters); err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/domaintopiceventsubscriptions_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/domaintopiceventsubscriptions_client_example_test.go index de8d99565c3a..574b49833ea0 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/domaintopiceventsubscriptions_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/domaintopiceventsubscriptions_client_example_test.go @@ -18,7 +18,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/DomainTopicEventSubscriptions_GetDeliveryAttributes.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/DomainTopicEventSubscriptions_GetDeliveryAttributes.json func ExampleDomainTopicEventSubscriptionsClient_GetDeliveryAttributes() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -64,7 +64,7 @@ func ExampleDomainTopicEventSubscriptionsClient_GetDeliveryAttributes() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/DomainTopicEventSubscriptions_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/DomainTopicEventSubscriptions_Get.json func ExampleDomainTopicEventSubscriptionsClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -116,7 +116,7 @@ func ExampleDomainTopicEventSubscriptionsClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/DomainTopicEventSubscriptions_CreateOrUpdate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/DomainTopicEventSubscriptions_CreateOrUpdate.json func ExampleDomainTopicEventSubscriptionsClient_BeginCreateOrUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -179,7 +179,7 @@ func ExampleDomainTopicEventSubscriptionsClient_BeginCreateOrUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/DomainTopicEventSubscriptions_Delete.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/DomainTopicEventSubscriptions_Delete.json func ExampleDomainTopicEventSubscriptionsClient_BeginDelete() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -200,7 +200,7 @@ func ExampleDomainTopicEventSubscriptionsClient_BeginDelete() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/DomainTopicEventSubscriptions_Update.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/DomainTopicEventSubscriptions_Update.json func ExampleDomainTopicEventSubscriptionsClient_BeginUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -236,7 +236,7 @@ func ExampleDomainTopicEventSubscriptionsClient_BeginUpdate() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/DomainTopicEventSubscriptions_GetFullUrl.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/DomainTopicEventSubscriptions_GetFullUrl.json func ExampleDomainTopicEventSubscriptionsClient_GetFullURL() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -259,7 +259,7 @@ func ExampleDomainTopicEventSubscriptionsClient_GetFullURL() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/DomainTopicEventSubscriptions_List.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/DomainTopicEventSubscriptions_List.json func ExampleDomainTopicEventSubscriptionsClient_NewListPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/domaintopics_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/domaintopics_client.go index e014cf422bdb..17d5afe6ebf1 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/domaintopics_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/domaintopics_client.go @@ -48,7 +48,7 @@ func NewDomainTopicsClient(subscriptionID string, credential azcore.TokenCredent // BeginCreateOrUpdate - Asynchronously creates or updates a new domain topic with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Name of the domain. // - domainTopicName - Name of the domain topic. @@ -74,7 +74,7 @@ func (client *DomainTopicsClient) BeginCreateOrUpdate(ctx context.Context, resou // CreateOrUpdate - Asynchronously creates or updates a new domain topic with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *DomainTopicsClient) createOrUpdate(ctx context.Context, resourceGroupName string, domainName string, domainTopicName string, options *DomainTopicsClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "DomainTopicsClient.BeginCreateOrUpdate" @@ -120,7 +120,7 @@ func (client *DomainTopicsClient) createOrUpdateCreateRequest(ctx context.Contex return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -129,7 +129,7 @@ func (client *DomainTopicsClient) createOrUpdateCreateRequest(ctx context.Contex // BeginDelete - Delete existing domain topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Name of the domain. // - domainTopicName - Name of the domain topic. @@ -155,7 +155,7 @@ func (client *DomainTopicsClient) BeginDelete(ctx context.Context, resourceGroup // Delete - Delete existing domain topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *DomainTopicsClient) deleteOperation(ctx context.Context, resourceGroupName string, domainName string, domainTopicName string, options *DomainTopicsClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "DomainTopicsClient.BeginDelete" @@ -201,7 +201,7 @@ func (client *DomainTopicsClient) deleteCreateRequest(ctx context.Context, resou return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() return req, nil } @@ -209,7 +209,7 @@ func (client *DomainTopicsClient) deleteCreateRequest(ctx context.Context, resou // Get - Get properties of a domain topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Name of the domain. // - domainTopicName - Name of the topic. @@ -260,7 +260,7 @@ func (client *DomainTopicsClient) getCreateRequest(ctx context.Context, resource return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -277,7 +277,7 @@ func (client *DomainTopicsClient) getHandleResponse(resp *http.Response) (Domain // NewListByDomainPager - List all the topics in a domain. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Domain name. // - options - DomainTopicsClientListByDomainOptions contains the optional parameters for the DomainTopicsClient.NewListByDomainPager @@ -325,13 +325,13 @@ func (client *DomainTopicsClient) listByDomainCreateRequest(ctx context.Context, return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/domaintopics_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/domaintopics_client_example_test.go index 220b525191c3..680449511b84 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/domaintopics_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/domaintopics_client_example_test.go @@ -17,7 +17,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/DomainTopics_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/DomainTopics_Get.json func ExampleDomainTopicsClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -45,7 +45,7 @@ func ExampleDomainTopicsClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/DomainTopics_CreateOrUpdate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/DomainTopics_CreateOrUpdate.json func ExampleDomainTopicsClient_BeginCreateOrUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -66,7 +66,7 @@ func ExampleDomainTopicsClient_BeginCreateOrUpdate() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/DomainTopics_Delete.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/DomainTopics_Delete.json func ExampleDomainTopicsClient_BeginDelete() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -87,7 +87,7 @@ func ExampleDomainTopicsClient_BeginDelete() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/DomainTopics_ListByDomain.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/DomainTopics_ListByDomain.json func ExampleDomainTopicsClient_NewListByDomainPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/eventsubscriptions_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/eventsubscriptions_client.go index 63118d350bae..e5d9afb31dc2 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/eventsubscriptions_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/eventsubscriptions_client.go @@ -49,7 +49,7 @@ func NewEventSubscriptionsClient(subscriptionID string, credential azcore.TokenC // the specified scope. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - scope - The identifier of the resource to which the event subscription needs to be created or updated. The scope can be // a subscription, or a resource group, or a top level resource belonging to a resource // provider namespace, or an EventGrid topic. For example, use '/subscriptions/{subscriptionId}/' for a subscription, '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' @@ -58,8 +58,8 @@ func NewEventSubscriptionsClient(subscriptionID string, credential azcore.TokenC // for a resource, and // '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventGrid/topics/{topicName}' for // an EventGrid topic. -// - eventSubscriptionName - Name of the event subscription. Event subscription names must be between 3 and 64 characters in -// length and should use alphanumeric letters only. +// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 64 +// characters in length and should use alphanumeric letters only. // - eventSubscriptionInfo - Event subscription properties containing the destination and filter information. // - options - EventSubscriptionsClientBeginCreateOrUpdateOptions contains the optional parameters for the EventSubscriptionsClient.BeginCreateOrUpdate // method. @@ -84,7 +84,7 @@ func (client *EventSubscriptionsClient) BeginCreateOrUpdate(ctx context.Context, // specified scope. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *EventSubscriptionsClient) createOrUpdate(ctx context.Context, scope string, eventSubscriptionName string, eventSubscriptionInfo EventSubscription, options *EventSubscriptionsClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "EventSubscriptionsClient.BeginCreateOrUpdate" @@ -119,7 +119,7 @@ func (client *EventSubscriptionsClient) createOrUpdateCreateRequest(ctx context. return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, eventSubscriptionInfo); err != nil { @@ -131,7 +131,7 @@ func (client *EventSubscriptionsClient) createOrUpdateCreateRequest(ctx context. // BeginDelete - Delete an existing event subscription. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - scope - The scope of the event subscription. The scope can be a subscription, or a resource group, or a top level resource // belonging to a resource provider namespace, or an EventGrid topic. For example, use // '/subscriptions/{subscriptionId}/' for a subscription, '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' @@ -140,7 +140,7 @@ func (client *EventSubscriptionsClient) createOrUpdateCreateRequest(ctx context. // for a resource, and // '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventGrid/topics/{topicName}' for // an EventGrid topic. -// - eventSubscriptionName - Name of the event subscription. +// - eventSubscriptionName - Name of the event subscription to be deleted. // - options - EventSubscriptionsClientBeginDeleteOptions contains the optional parameters for the EventSubscriptionsClient.BeginDelete // method. func (client *EventSubscriptionsClient) BeginDelete(ctx context.Context, scope string, eventSubscriptionName string, options *EventSubscriptionsClientBeginDeleteOptions) (*runtime.Poller[EventSubscriptionsClientDeleteResponse], error) { @@ -163,7 +163,7 @@ func (client *EventSubscriptionsClient) BeginDelete(ctx context.Context, scope s // Delete - Delete an existing event subscription. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *EventSubscriptionsClient) deleteOperation(ctx context.Context, scope string, eventSubscriptionName string, options *EventSubscriptionsClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "EventSubscriptionsClient.BeginDelete" @@ -198,7 +198,7 @@ func (client *EventSubscriptionsClient) deleteCreateRequest(ctx context.Context, return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() return req, nil } @@ -206,7 +206,7 @@ func (client *EventSubscriptionsClient) deleteCreateRequest(ctx context.Context, // Get - Get properties of an event subscription. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - scope - The scope of the event subscription. The scope can be a subscription, or a resource group, or a top level resource // belonging to a resource provider namespace, or an EventGrid topic. For example, use // '/subscriptions/{subscriptionId}/' for a subscription, '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' @@ -215,7 +215,7 @@ func (client *EventSubscriptionsClient) deleteCreateRequest(ctx context.Context, // for a resource, and // '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventGrid/topics/{topicName}' for // an EventGrid topic. -// - eventSubscriptionName - Name of the event subscription. +// - eventSubscriptionName - Name of the event subscription to be found. // - options - EventSubscriptionsClientGetOptions contains the optional parameters for the EventSubscriptionsClient.Get method. func (client *EventSubscriptionsClient) Get(ctx context.Context, scope string, eventSubscriptionName string, options *EventSubscriptionsClientGetOptions) (EventSubscriptionsClientGetResponse, error) { var err error @@ -252,7 +252,7 @@ func (client *EventSubscriptionsClient) getCreateRequest(ctx context.Context, sc return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -270,7 +270,7 @@ func (client *EventSubscriptionsClient) getHandleResponse(resp *http.Response) ( // GetDeliveryAttributes - Get all delivery attributes for an event subscription. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - scope - The scope of the event subscription. The scope can be a subscription, or a resource group, or a top level resource // belonging to a resource provider namespace, or an EventGrid topic. For example, use // '/subscriptions/{subscriptionId}/' for a subscription, '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' @@ -317,7 +317,7 @@ func (client *EventSubscriptionsClient) getDeliveryAttributesCreateRequest(ctx c return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -335,7 +335,7 @@ func (client *EventSubscriptionsClient) getDeliveryAttributesHandleResponse(resp // GetFullURL - Get the full endpoint URL for an event subscription. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - scope - The scope of the event subscription. The scope can be a subscription, or a resource group, or a top level resource // belonging to a resource provider namespace, or an EventGrid topic. For example, use // '/subscriptions/{subscriptionId}/' for a subscription, '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' @@ -382,7 +382,7 @@ func (client *EventSubscriptionsClient) getFullURLCreateRequest(ctx context.Cont return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -399,7 +399,7 @@ func (client *EventSubscriptionsClient) getFullURLHandleResponse(resp *http.Resp // NewListByDomainTopicPager - List all event subscriptions that have been created for a specific domain topic. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - domainName - Name of the top level domain. // - topicName - Name of the domain topic. @@ -452,13 +452,13 @@ func (client *EventSubscriptionsClient) listByDomainTopicCreateRequest(ctx conte return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -475,7 +475,7 @@ func (client *EventSubscriptionsClient) listByDomainTopicHandleResponse(resp *ht // NewListByResourcePager - List all event subscriptions that have been created for a specific resource. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - providerNamespace - Namespace of the provider of the topic. // - resourceTypeName - Name of the resource type. @@ -533,13 +533,13 @@ func (client *EventSubscriptionsClient) listByResourceCreateRequest(ctx context. return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -557,7 +557,7 @@ func (client *EventSubscriptionsClient) listByResourceHandleResponse(resp *http. // NewListGlobalByResourceGroupPager - List all global event subscriptions under a specific Azure subscription and resource // group. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - options - EventSubscriptionsClientListGlobalByResourceGroupOptions contains the optional parameters for the EventSubscriptionsClient.NewListGlobalByResourceGroupPager // method. @@ -600,13 +600,13 @@ func (client *EventSubscriptionsClient) listGlobalByResourceGroupCreateRequest(c return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -624,7 +624,7 @@ func (client *EventSubscriptionsClient) listGlobalByResourceGroupHandleResponse( // NewListGlobalByResourceGroupForTopicTypePager - List all global event subscriptions under a resource group for a specific // topic type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - topicTypeName - Name of the topic type. // - options - EventSubscriptionsClientListGlobalByResourceGroupForTopicTypeOptions contains the optional parameters for the @@ -672,13 +672,13 @@ func (client *EventSubscriptionsClient) listGlobalByResourceGroupForTopicTypeCre return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -695,7 +695,7 @@ func (client *EventSubscriptionsClient) listGlobalByResourceGroupForTopicTypeHan // NewListGlobalBySubscriptionPager - List all aggregated global event subscriptions under a specific Azure subscription. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - options - EventSubscriptionsClientListGlobalBySubscriptionOptions contains the optional parameters for the EventSubscriptionsClient.NewListGlobalBySubscriptionPager // method. func (client *EventSubscriptionsClient) NewListGlobalBySubscriptionPager(options *EventSubscriptionsClientListGlobalBySubscriptionOptions) *runtime.Pager[EventSubscriptionsClientListGlobalBySubscriptionResponse] { @@ -733,13 +733,13 @@ func (client *EventSubscriptionsClient) listGlobalBySubscriptionCreateRequest(ct return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -757,7 +757,7 @@ func (client *EventSubscriptionsClient) listGlobalBySubscriptionHandleResponse(r // NewListGlobalBySubscriptionForTopicTypePager - List all global event subscriptions under an Azure subscription for a topic // type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - topicTypeName - Name of the topic type. // - options - EventSubscriptionsClientListGlobalBySubscriptionForTopicTypeOptions contains the optional parameters for the // EventSubscriptionsClient.NewListGlobalBySubscriptionForTopicTypePager method. @@ -800,13 +800,13 @@ func (client *EventSubscriptionsClient) listGlobalBySubscriptionForTopicTypeCrea return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -824,7 +824,7 @@ func (client *EventSubscriptionsClient) listGlobalBySubscriptionForTopicTypeHand // NewListRegionalByResourceGroupPager - List all event subscriptions from the given location under a specific Azure subscription // and resource group. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - location - Name of the location. // - options - EventSubscriptionsClientListRegionalByResourceGroupOptions contains the optional parameters for the EventSubscriptionsClient.NewListRegionalByResourceGroupPager @@ -872,13 +872,13 @@ func (client *EventSubscriptionsClient) listRegionalByResourceGroupCreateRequest return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -896,7 +896,7 @@ func (client *EventSubscriptionsClient) listRegionalByResourceGroupHandleRespons // NewListRegionalByResourceGroupForTopicTypePager - List all event subscriptions from the given location under a specific // Azure subscription and resource group and topic type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - location - Name of the location. // - topicTypeName - Name of the topic type. @@ -949,13 +949,13 @@ func (client *EventSubscriptionsClient) listRegionalByResourceGroupForTopicTypeC return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -972,7 +972,7 @@ func (client *EventSubscriptionsClient) listRegionalByResourceGroupForTopicTypeH // NewListRegionalBySubscriptionPager - List all event subscriptions from the given location under a specific Azure subscription. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - location - Name of the location. // - options - EventSubscriptionsClientListRegionalBySubscriptionOptions contains the optional parameters for the EventSubscriptionsClient.NewListRegionalBySubscriptionPager // method. @@ -1015,13 +1015,13 @@ func (client *EventSubscriptionsClient) listRegionalBySubscriptionCreateRequest( return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -1039,7 +1039,7 @@ func (client *EventSubscriptionsClient) listRegionalBySubscriptionHandleResponse // NewListRegionalBySubscriptionForTopicTypePager - List all event subscriptions from the given location under a specific // Azure subscription and topic type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - location - Name of the location. // - topicTypeName - Name of the topic type. // - options - EventSubscriptionsClientListRegionalBySubscriptionForTopicTypeOptions contains the optional parameters for the @@ -1087,13 +1087,13 @@ func (client *EventSubscriptionsClient) listRegionalBySubscriptionForTopicTypeCr return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -1111,7 +1111,7 @@ func (client *EventSubscriptionsClient) listRegionalBySubscriptionForTopicTypeHa // BeginUpdate - Asynchronously updates an existing event subscription. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - scope - The scope of existing event subscription. The scope can be a subscription, or a resource group, or a top level // resource belonging to a resource provider namespace, or an EventGrid topic. For example, // use '/subscriptions/{subscriptionId}/' for a subscription, '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' @@ -1144,7 +1144,7 @@ func (client *EventSubscriptionsClient) BeginUpdate(ctx context.Context, scope s // Update - Asynchronously updates an existing event subscription. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *EventSubscriptionsClient) update(ctx context.Context, scope string, eventSubscriptionName string, eventSubscriptionUpdateParameters EventSubscriptionUpdateParameters, options *EventSubscriptionsClientBeginUpdateOptions) (*http.Response, error) { var err error const operationName = "EventSubscriptionsClient.BeginUpdate" @@ -1179,7 +1179,7 @@ func (client *EventSubscriptionsClient) updateCreateRequest(ctx context.Context, return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, eventSubscriptionUpdateParameters); err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/eventsubscriptions_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/eventsubscriptions_client_example_test.go index 3b1dbd8723a1..92b6e0284268 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/eventsubscriptions_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/eventsubscriptions_client_example_test.go @@ -18,7 +18,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_GetDeliveryAttributes.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_GetDeliveryAttributes.json func ExampleEventSubscriptionsClient_GetDeliveryAttributes() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -64,7 +64,7 @@ func ExampleEventSubscriptionsClient_GetDeliveryAttributes() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_GetForCustomTopic.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_GetForCustomTopic.json func ExampleEventSubscriptionsClient_Get_eventSubscriptionsGetForCustomTopic() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -107,7 +107,7 @@ func ExampleEventSubscriptionsClient_Get_eventSubscriptionsGetForCustomTopic() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_GetForCustomTopic_AzureFunctionDestination.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_GetForCustomTopic_AzureFunctionDestination.json func ExampleEventSubscriptionsClient_Get_eventSubscriptionsGetForCustomTopicAzureFunctionDestination() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -150,7 +150,7 @@ func ExampleEventSubscriptionsClient_Get_eventSubscriptionsGetForCustomTopicAzur // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_GetForCustomTopic_EventHubDestination.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_GetForCustomTopic_EventHubDestination.json func ExampleEventSubscriptionsClient_Get_eventSubscriptionsGetForCustomTopicEventHubDestination() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -193,7 +193,7 @@ func ExampleEventSubscriptionsClient_Get_eventSubscriptionsGetForCustomTopicEven // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_GetForCustomTopic_HybridConnectionDestination.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_GetForCustomTopic_HybridConnectionDestination.json func ExampleEventSubscriptionsClient_Get_eventSubscriptionsGetForCustomTopicHybridConnectionDestination() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -236,7 +236,7 @@ func ExampleEventSubscriptionsClient_Get_eventSubscriptionsGetForCustomTopicHybr // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_GetForCustomTopic_ServiceBusQueueDestination.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_GetForCustomTopic_ServiceBusQueueDestination.json func ExampleEventSubscriptionsClient_Get_eventSubscriptionsGetForCustomTopicServiceBusQueueDestination() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -279,7 +279,7 @@ func ExampleEventSubscriptionsClient_Get_eventSubscriptionsGetForCustomTopicServ // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_GetForCustomTopic_ServiceBusTopicDestination.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_GetForCustomTopic_ServiceBusTopicDestination.json func ExampleEventSubscriptionsClient_Get_eventSubscriptionsGetForCustomTopicServiceBusTopicDestination() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -322,7 +322,7 @@ func ExampleEventSubscriptionsClient_Get_eventSubscriptionsGetForCustomTopicServ // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_GetForCustomTopic_StorageQueueDestination.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_GetForCustomTopic_StorageQueueDestination.json func ExampleEventSubscriptionsClient_Get_eventSubscriptionsGetForCustomTopicStorageQueueDestination() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -367,7 +367,7 @@ func ExampleEventSubscriptionsClient_Get_eventSubscriptionsGetForCustomTopicStor // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_GetForCustomTopic_WebhookDestination.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_GetForCustomTopic_WebhookDestination.json func ExampleEventSubscriptionsClient_Get_eventSubscriptionsGetForCustomTopicWebhookDestination() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -410,7 +410,7 @@ func ExampleEventSubscriptionsClient_Get_eventSubscriptionsGetForCustomTopicWebh // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_GetForResource.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_GetForResource.json func ExampleEventSubscriptionsClient_Get_eventSubscriptionsGetForResource() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -453,7 +453,7 @@ func ExampleEventSubscriptionsClient_Get_eventSubscriptionsGetForResource() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_GetForResourceGroup.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_GetForResourceGroup.json func ExampleEventSubscriptionsClient_Get_eventSubscriptionsGetForResourceGroup() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -496,7 +496,7 @@ func ExampleEventSubscriptionsClient_Get_eventSubscriptionsGetForResourceGroup() // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_GetForSubscription.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_GetForSubscription.json func ExampleEventSubscriptionsClient_Get_eventSubscriptionsGetForSubscription() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -539,7 +539,7 @@ func ExampleEventSubscriptionsClient_Get_eventSubscriptionsGetForSubscription() // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_CreateOrUpdateForCustomTopic.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_CreateOrUpdateForCustomTopic.json func ExampleEventSubscriptionsClient_BeginCreateOrUpdate_eventSubscriptionsCreateOrUpdateForCustomTopic() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -574,7 +574,7 @@ func ExampleEventSubscriptionsClient_BeginCreateOrUpdate_eventSubscriptionsCreat } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_CreateOrUpdateForCustomTopic_AzureFunctionDestination.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_CreateOrUpdateForCustomTopic_AzureFunctionDestination.json func ExampleEventSubscriptionsClient_BeginCreateOrUpdate_eventSubscriptionsCreateOrUpdateForCustomTopicAzureFunctionDestination() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -616,7 +616,7 @@ func ExampleEventSubscriptionsClient_BeginCreateOrUpdate_eventSubscriptionsCreat } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_CreateOrUpdateForCustomTopic_EventHubDestination.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_CreateOrUpdateForCustomTopic_EventHubDestination.json func ExampleEventSubscriptionsClient_BeginCreateOrUpdate_eventSubscriptionsCreateOrUpdateForCustomTopicEventHubDestination() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -658,7 +658,7 @@ func ExampleEventSubscriptionsClient_BeginCreateOrUpdate_eventSubscriptionsCreat } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_CreateOrUpdateForCustomTopic_HybridConnectionDestination.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_CreateOrUpdateForCustomTopic_HybridConnectionDestination.json func ExampleEventSubscriptionsClient_BeginCreateOrUpdate_eventSubscriptionsCreateOrUpdateForCustomTopicHybridConnectionDestination() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -700,7 +700,7 @@ func ExampleEventSubscriptionsClient_BeginCreateOrUpdate_eventSubscriptionsCreat } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_CreateOrUpdateForCustomTopic_ServiceBusQueueDestination.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_CreateOrUpdateForCustomTopic_ServiceBusQueueDestination.json func ExampleEventSubscriptionsClient_BeginCreateOrUpdate_eventSubscriptionsCreateOrUpdateForCustomTopicServiceBusQueueDestination() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -742,7 +742,7 @@ func ExampleEventSubscriptionsClient_BeginCreateOrUpdate_eventSubscriptionsCreat } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_CreateOrUpdateForCustomTopic_ServiceBusTopicDestination.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_CreateOrUpdateForCustomTopic_ServiceBusTopicDestination.json func ExampleEventSubscriptionsClient_BeginCreateOrUpdate_eventSubscriptionsCreateOrUpdateForCustomTopicServiceBusTopicDestination() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -784,7 +784,7 @@ func ExampleEventSubscriptionsClient_BeginCreateOrUpdate_eventSubscriptionsCreat } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_CreateOrUpdateForCustomTopic_StorageQueueDestination.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_CreateOrUpdateForCustomTopic_StorageQueueDestination.json func ExampleEventSubscriptionsClient_BeginCreateOrUpdate_eventSubscriptionsCreateOrUpdateForCustomTopicStorageQueueDestination() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -828,7 +828,7 @@ func ExampleEventSubscriptionsClient_BeginCreateOrUpdate_eventSubscriptionsCreat } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_CreateOrUpdateForCustomTopic_WebhookDestination.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_CreateOrUpdateForCustomTopic_WebhookDestination.json func ExampleEventSubscriptionsClient_BeginCreateOrUpdate_eventSubscriptionsCreateOrUpdateForCustomTopicWebhookDestination() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -863,7 +863,7 @@ func ExampleEventSubscriptionsClient_BeginCreateOrUpdate_eventSubscriptionsCreat } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_CreateOrUpdateForResource.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_CreateOrUpdateForResource.json func ExampleEventSubscriptionsClient_BeginCreateOrUpdate_eventSubscriptionsCreateOrUpdateForResource() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -898,7 +898,7 @@ func ExampleEventSubscriptionsClient_BeginCreateOrUpdate_eventSubscriptionsCreat } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_CreateOrUpdateForResourceGroup.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_CreateOrUpdateForResourceGroup.json func ExampleEventSubscriptionsClient_BeginCreateOrUpdate_eventSubscriptionsCreateOrUpdateForResourceGroup() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -933,7 +933,7 @@ func ExampleEventSubscriptionsClient_BeginCreateOrUpdate_eventSubscriptionsCreat } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_CreateOrUpdateForSubscription.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_CreateOrUpdateForSubscription.json func ExampleEventSubscriptionsClient_BeginCreateOrUpdate_eventSubscriptionsCreateOrUpdateForSubscription() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -966,7 +966,7 @@ func ExampleEventSubscriptionsClient_BeginCreateOrUpdate_eventSubscriptionsCreat } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_DeleteForCustomTopic.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_DeleteForCustomTopic.json func ExampleEventSubscriptionsClient_BeginDelete_eventSubscriptionsDeleteForCustomTopic() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -987,7 +987,7 @@ func ExampleEventSubscriptionsClient_BeginDelete_eventSubscriptionsDeleteForCust } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_DeleteForResource.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_DeleteForResource.json func ExampleEventSubscriptionsClient_BeginDelete_eventSubscriptionsDeleteForResource() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -1008,7 +1008,7 @@ func ExampleEventSubscriptionsClient_BeginDelete_eventSubscriptionsDeleteForReso } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_DeleteForResourceGroup.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_DeleteForResourceGroup.json func ExampleEventSubscriptionsClient_BeginDelete_eventSubscriptionsDeleteForResourceGroup() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -1029,7 +1029,7 @@ func ExampleEventSubscriptionsClient_BeginDelete_eventSubscriptionsDeleteForReso } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_DeleteForSubscription.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_DeleteForSubscription.json func ExampleEventSubscriptionsClient_BeginDelete_eventSubscriptionsDeleteForSubscription() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -1050,7 +1050,7 @@ func ExampleEventSubscriptionsClient_BeginDelete_eventSubscriptionsDeleteForSubs } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_UpdateForCustomTopic.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_UpdateForCustomTopic.json func ExampleEventSubscriptionsClient_BeginUpdate_eventSubscriptionsUpdateForCustomTopic() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -1086,7 +1086,7 @@ func ExampleEventSubscriptionsClient_BeginUpdate_eventSubscriptionsUpdateForCust } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_UpdateForCustomTopic_AzureFunctionDestination.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_UpdateForCustomTopic_AzureFunctionDestination.json func ExampleEventSubscriptionsClient_BeginUpdate_eventSubscriptionsUpdateForCustomTopicAzureFunctionDestination() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -1126,7 +1126,7 @@ func ExampleEventSubscriptionsClient_BeginUpdate_eventSubscriptionsUpdateForCust } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_UpdateForCustomTopic_EventHubDestination.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_UpdateForCustomTopic_EventHubDestination.json func ExampleEventSubscriptionsClient_BeginUpdate_eventSubscriptionsUpdateForCustomTopicEventHubDestination() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -1162,7 +1162,7 @@ func ExampleEventSubscriptionsClient_BeginUpdate_eventSubscriptionsUpdateForCust } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_UpdateForCustomTopic_HybridConnectionDestination.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_UpdateForCustomTopic_HybridConnectionDestination.json func ExampleEventSubscriptionsClient_BeginUpdate_eventSubscriptionsUpdateForCustomTopicHybridConnectionDestination() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -1198,7 +1198,7 @@ func ExampleEventSubscriptionsClient_BeginUpdate_eventSubscriptionsUpdateForCust } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_UpdateForCustomTopic_ServiceBusQueueDestination.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_UpdateForCustomTopic_ServiceBusQueueDestination.json func ExampleEventSubscriptionsClient_BeginUpdate_eventSubscriptionsUpdateForCustomTopicServiceBusQueueDestination() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -1238,7 +1238,7 @@ func ExampleEventSubscriptionsClient_BeginUpdate_eventSubscriptionsUpdateForCust } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_UpdateForCustomTopic_ServiceBusTopicDestination.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_UpdateForCustomTopic_ServiceBusTopicDestination.json func ExampleEventSubscriptionsClient_BeginUpdate_eventSubscriptionsUpdateForCustomTopicServiceBusTopicDestination() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -1274,7 +1274,7 @@ func ExampleEventSubscriptionsClient_BeginUpdate_eventSubscriptionsUpdateForCust } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_UpdateForCustomTopic_StorageQueueDestination.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_UpdateForCustomTopic_StorageQueueDestination.json func ExampleEventSubscriptionsClient_BeginUpdate_eventSubscriptionsUpdateForCustomTopicStorageQueueDestination() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -1316,7 +1316,7 @@ func ExampleEventSubscriptionsClient_BeginUpdate_eventSubscriptionsUpdateForCust } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_UpdateForCustomTopic_WebhookDestination.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_UpdateForCustomTopic_WebhookDestination.json func ExampleEventSubscriptionsClient_BeginUpdate_eventSubscriptionsUpdateForCustomTopicWebhookDestination() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -1352,7 +1352,7 @@ func ExampleEventSubscriptionsClient_BeginUpdate_eventSubscriptionsUpdateForCust } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_UpdateForResource.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_UpdateForResource.json func ExampleEventSubscriptionsClient_BeginUpdate_eventSubscriptionsUpdateForResource() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -1388,7 +1388,7 @@ func ExampleEventSubscriptionsClient_BeginUpdate_eventSubscriptionsUpdateForReso } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_UpdateForResourceGroup.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_UpdateForResourceGroup.json func ExampleEventSubscriptionsClient_BeginUpdate_eventSubscriptionsUpdateForResourceGroup() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -1424,7 +1424,7 @@ func ExampleEventSubscriptionsClient_BeginUpdate_eventSubscriptionsUpdateForReso } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_UpdateForSubscription.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_UpdateForSubscription.json func ExampleEventSubscriptionsClient_BeginUpdate_eventSubscriptionsUpdateForSubscription() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -1460,7 +1460,7 @@ func ExampleEventSubscriptionsClient_BeginUpdate_eventSubscriptionsUpdateForSubs } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_GetFullUrlForCustomTopic.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_GetFullUrlForCustomTopic.json func ExampleEventSubscriptionsClient_GetFullURL_eventSubscriptionsGetFullUrlForCustomTopic() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -1483,7 +1483,7 @@ func ExampleEventSubscriptionsClient_GetFullURL_eventSubscriptionsGetFullUrlForC // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_GetFullUrlForResource.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_GetFullUrlForResource.json func ExampleEventSubscriptionsClient_GetFullURL_eventSubscriptionsGetFullUrlForResource() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -1506,7 +1506,7 @@ func ExampleEventSubscriptionsClient_GetFullURL_eventSubscriptionsGetFullUrlForR // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_GetFullUrlForResourceGroup.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_GetFullUrlForResourceGroup.json func ExampleEventSubscriptionsClient_GetFullURL_eventSubscriptionsGetFullUrlForResourceGroup() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -1529,7 +1529,7 @@ func ExampleEventSubscriptionsClient_GetFullURL_eventSubscriptionsGetFullUrlForR // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_GetFullUrlForSubscription.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_GetFullUrlForSubscription.json func ExampleEventSubscriptionsClient_GetFullURL_eventSubscriptionsGetFullUrlForSubscription() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -1552,7 +1552,7 @@ func ExampleEventSubscriptionsClient_GetFullURL_eventSubscriptionsGetFullUrlForS // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_ListGlobalBySubscription.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_ListGlobalBySubscription.json func ExampleEventSubscriptionsClient_NewListGlobalBySubscriptionPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -1622,7 +1622,7 @@ func ExampleEventSubscriptionsClient_NewListGlobalBySubscriptionPager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_ListGlobalBySubscriptionForTopicType.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_ListGlobalBySubscriptionForTopicType.json func ExampleEventSubscriptionsClient_NewListGlobalBySubscriptionForTopicTypePager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -1675,7 +1675,7 @@ func ExampleEventSubscriptionsClient_NewListGlobalBySubscriptionForTopicTypePage } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_ListGlobalByResourceGroup.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_ListGlobalByResourceGroup.json func ExampleEventSubscriptionsClient_NewListGlobalByResourceGroupPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -1745,7 +1745,7 @@ func ExampleEventSubscriptionsClient_NewListGlobalByResourceGroupPager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_ListGlobalByResourceGroupForTopicType.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_ListGlobalByResourceGroupForTopicType.json func ExampleEventSubscriptionsClient_NewListGlobalByResourceGroupForTopicTypePager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -1798,7 +1798,7 @@ func ExampleEventSubscriptionsClient_NewListGlobalByResourceGroupForTopicTypePag } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_ListRegionalBySubscription.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_ListRegionalBySubscription.json func ExampleEventSubscriptionsClient_NewListRegionalBySubscriptionPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -1874,7 +1874,7 @@ func ExampleEventSubscriptionsClient_NewListRegionalBySubscriptionPager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_ListRegionalByResourceGroup.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_ListRegionalByResourceGroup.json func ExampleEventSubscriptionsClient_NewListRegionalByResourceGroupPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -1950,7 +1950,7 @@ func ExampleEventSubscriptionsClient_NewListRegionalByResourceGroupPager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_ListRegionalBySubscriptionForTopicType.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_ListRegionalBySubscriptionForTopicType.json func ExampleEventSubscriptionsClient_NewListRegionalBySubscriptionForTopicTypePager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -2026,7 +2026,7 @@ func ExampleEventSubscriptionsClient_NewListRegionalBySubscriptionForTopicTypePa } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_ListRegionalByResourceGroupForTopicType.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_ListRegionalByResourceGroupForTopicType.json func ExampleEventSubscriptionsClient_NewListRegionalByResourceGroupForTopicTypePager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -2102,7 +2102,7 @@ func ExampleEventSubscriptionsClient_NewListRegionalByResourceGroupForTopicTypeP } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_ListByResource.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_ListByResource.json func ExampleEventSubscriptionsClient_NewListByResourcePager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -2194,7 +2194,7 @@ func ExampleEventSubscriptionsClient_NewListByResourcePager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/EventSubscriptions_ListByDomainTopic.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/EventSubscriptions_ListByDomainTopic.json func ExampleEventSubscriptionsClient_NewListByDomainTopicPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/extensiontopics_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/extensiontopics_client.go index 2a5248de8f2c..2e50c79a9170 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/extensiontopics_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/extensiontopics_client.go @@ -43,7 +43,7 @@ func NewExtensionTopicsClient(credential azcore.TokenCredential, options *arm.Cl // Get - Get the properties of an extension topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - scope - The identifier of the resource to which extension topic is queried. The scope can be a subscription, or a resource // group, or a top level resource belonging to a resource provider namespace. For // example, use '/subscriptions/{subscriptionId}/' for a subscription, '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}' @@ -85,7 +85,7 @@ func (client *ExtensionTopicsClient) getCreateRequest(ctx context.Context, scope return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/extensiontopics_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/extensiontopics_client_example_test.go index 52e7f8ed42b5..6171b728147f 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/extensiontopics_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/extensiontopics_client_example_test.go @@ -17,7 +17,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/ExtensionTopics_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/ExtensionTopics_Get.json func ExampleExtensionTopicsClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/fake/namespaces_server.go b/sdk/resourcemanager/eventgrid/armeventgrid/fake/namespaces_server.go index 868d4b0115df..b51b17e0adcf 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/fake/namespaces_server.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/fake/namespaces_server.go @@ -56,6 +56,10 @@ type NamespacesServer struct { // BeginUpdate is the fake for method NamespacesClient.BeginUpdate // HTTP status codes to indicate success: http.StatusOK, http.StatusAccepted BeginUpdate func(ctx context.Context, resourceGroupName string, namespaceName string, namespaceUpdateParameters armeventgrid.NamespaceUpdateParameters, options *armeventgrid.NamespacesClientBeginUpdateOptions) (resp azfake.PollerResponder[armeventgrid.NamespacesClientUpdateResponse], errResp azfake.ErrorResponder) + + // BeginValidateCustomDomainOwnership is the fake for method NamespacesClient.BeginValidateCustomDomainOwnership + // HTTP status codes to indicate success: http.StatusOK, http.StatusAccepted + BeginValidateCustomDomainOwnership func(ctx context.Context, resourceGroupName string, namespaceName string, options *armeventgrid.NamespacesClientBeginValidateCustomDomainOwnershipOptions) (resp azfake.PollerResponder[armeventgrid.NamespacesClientValidateCustomDomainOwnershipResponse], errResp azfake.ErrorResponder) } // NewNamespacesServerTransport creates a new instance of NamespacesServerTransport with the provided implementation. @@ -63,26 +67,28 @@ type NamespacesServer struct { // azcore.ClientOptions.Transporter field in the client's constructor parameters. func NewNamespacesServerTransport(srv *NamespacesServer) *NamespacesServerTransport { return &NamespacesServerTransport{ - srv: srv, - beginCreateOrUpdate: newTracker[azfake.PollerResponder[armeventgrid.NamespacesClientCreateOrUpdateResponse]](), - beginDelete: newTracker[azfake.PollerResponder[armeventgrid.NamespacesClientDeleteResponse]](), - newListByResourceGroupPager: newTracker[azfake.PagerResponder[armeventgrid.NamespacesClientListByResourceGroupResponse]](), - newListBySubscriptionPager: newTracker[azfake.PagerResponder[armeventgrid.NamespacesClientListBySubscriptionResponse]](), - beginRegenerateKey: newTracker[azfake.PollerResponder[armeventgrid.NamespacesClientRegenerateKeyResponse]](), - beginUpdate: newTracker[azfake.PollerResponder[armeventgrid.NamespacesClientUpdateResponse]](), + srv: srv, + beginCreateOrUpdate: newTracker[azfake.PollerResponder[armeventgrid.NamespacesClientCreateOrUpdateResponse]](), + beginDelete: newTracker[azfake.PollerResponder[armeventgrid.NamespacesClientDeleteResponse]](), + newListByResourceGroupPager: newTracker[azfake.PagerResponder[armeventgrid.NamespacesClientListByResourceGroupResponse]](), + newListBySubscriptionPager: newTracker[azfake.PagerResponder[armeventgrid.NamespacesClientListBySubscriptionResponse]](), + beginRegenerateKey: newTracker[azfake.PollerResponder[armeventgrid.NamespacesClientRegenerateKeyResponse]](), + beginUpdate: newTracker[azfake.PollerResponder[armeventgrid.NamespacesClientUpdateResponse]](), + beginValidateCustomDomainOwnership: newTracker[azfake.PollerResponder[armeventgrid.NamespacesClientValidateCustomDomainOwnershipResponse]](), } } // NamespacesServerTransport connects instances of armeventgrid.NamespacesClient to instances of NamespacesServer. // Don't use this type directly, use NewNamespacesServerTransport instead. type NamespacesServerTransport struct { - srv *NamespacesServer - beginCreateOrUpdate *tracker[azfake.PollerResponder[armeventgrid.NamespacesClientCreateOrUpdateResponse]] - beginDelete *tracker[azfake.PollerResponder[armeventgrid.NamespacesClientDeleteResponse]] - newListByResourceGroupPager *tracker[azfake.PagerResponder[armeventgrid.NamespacesClientListByResourceGroupResponse]] - newListBySubscriptionPager *tracker[azfake.PagerResponder[armeventgrid.NamespacesClientListBySubscriptionResponse]] - beginRegenerateKey *tracker[azfake.PollerResponder[armeventgrid.NamespacesClientRegenerateKeyResponse]] - beginUpdate *tracker[azfake.PollerResponder[armeventgrid.NamespacesClientUpdateResponse]] + srv *NamespacesServer + beginCreateOrUpdate *tracker[azfake.PollerResponder[armeventgrid.NamespacesClientCreateOrUpdateResponse]] + beginDelete *tracker[azfake.PollerResponder[armeventgrid.NamespacesClientDeleteResponse]] + newListByResourceGroupPager *tracker[azfake.PagerResponder[armeventgrid.NamespacesClientListByResourceGroupResponse]] + newListBySubscriptionPager *tracker[azfake.PagerResponder[armeventgrid.NamespacesClientListBySubscriptionResponse]] + beginRegenerateKey *tracker[azfake.PollerResponder[armeventgrid.NamespacesClientRegenerateKeyResponse]] + beginUpdate *tracker[azfake.PollerResponder[armeventgrid.NamespacesClientUpdateResponse]] + beginValidateCustomDomainOwnership *tracker[azfake.PollerResponder[armeventgrid.NamespacesClientValidateCustomDomainOwnershipResponse]] } // Do implements the policy.Transporter interface for NamespacesServerTransport. @@ -113,6 +119,8 @@ func (n *NamespacesServerTransport) Do(req *http.Request) (*http.Response, error resp, err = n.dispatchBeginRegenerateKey(req) case "NamespacesClient.BeginUpdate": resp, err = n.dispatchBeginUpdate(req) + case "NamespacesClient.BeginValidateCustomDomainOwnership": + resp, err = n.dispatchBeginValidateCustomDomainOwnership(req) default: err = fmt.Errorf("unhandled API %s", method) } @@ -501,3 +509,47 @@ func (n *NamespacesServerTransport) dispatchBeginUpdate(req *http.Request) (*htt return resp, nil } + +func (n *NamespacesServerTransport) dispatchBeginValidateCustomDomainOwnership(req *http.Request) (*http.Response, error) { + if n.srv.BeginValidateCustomDomainOwnership == nil { + return nil, &nonRetriableError{errors.New("fake for method BeginValidateCustomDomainOwnership not implemented")} + } + beginValidateCustomDomainOwnership := n.beginValidateCustomDomainOwnership.get(req) + if beginValidateCustomDomainOwnership == nil { + const regexStr = `/subscriptions/(?P[!#&$-;=?-\[\]_a-zA-Z0-9~%@]+)/resourceGroups/(?P[!#&$-;=?-\[\]_a-zA-Z0-9~%@]+)/providers/Microsoft\.EventGrid/namespaces/(?P[!#&$-;=?-\[\]_a-zA-Z0-9~%@]+)/validateCustomDomainOwnership` + regex := regexp.MustCompile(regexStr) + matches := regex.FindStringSubmatch(req.URL.EscapedPath()) + if matches == nil || len(matches) < 3 { + return nil, fmt.Errorf("failed to parse path %s", req.URL.Path) + } + resourceGroupNameParam, err := url.PathUnescape(matches[regex.SubexpIndex("resourceGroupName")]) + if err != nil { + return nil, err + } + namespaceNameParam, err := url.PathUnescape(matches[regex.SubexpIndex("namespaceName")]) + if err != nil { + return nil, err + } + respr, errRespr := n.srv.BeginValidateCustomDomainOwnership(req.Context(), resourceGroupNameParam, namespaceNameParam, nil) + if respErr := server.GetError(errRespr, req); respErr != nil { + return nil, respErr + } + beginValidateCustomDomainOwnership = &respr + n.beginValidateCustomDomainOwnership.add(req, beginValidateCustomDomainOwnership) + } + + resp, err := server.PollerResponderNext(beginValidateCustomDomainOwnership, req) + if err != nil { + return nil, err + } + + if !contains([]int{http.StatusOK, http.StatusAccepted}, resp.StatusCode) { + n.beginValidateCustomDomainOwnership.remove(req) + return nil, &nonRetriableError{fmt.Errorf("unexpected status code %d. acceptable values are http.StatusOK, http.StatusAccepted", resp.StatusCode)} + } + if !server.PollerResponderMore(beginValidateCustomDomainOwnership) { + n.beginValidateCustomDomainOwnership.remove(req) + } + + return resp, nil +} diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/fake/namespacetopiceventsubscriptions_server.go b/sdk/resourcemanager/eventgrid/armeventgrid/fake/namespacetopiceventsubscriptions_server.go index b0842ad80576..ebadc6695ef7 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/fake/namespacetopiceventsubscriptions_server.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/fake/namespacetopiceventsubscriptions_server.go @@ -41,6 +41,10 @@ type NamespaceTopicEventSubscriptionsServer struct { // HTTP status codes to indicate success: http.StatusOK GetDeliveryAttributes func(ctx context.Context, resourceGroupName string, namespaceName string, topicName string, eventSubscriptionName string, options *armeventgrid.NamespaceTopicEventSubscriptionsClientGetDeliveryAttributesOptions) (resp azfake.Responder[armeventgrid.NamespaceTopicEventSubscriptionsClientGetDeliveryAttributesResponse], errResp azfake.ErrorResponder) + // GetFullURL is the fake for method NamespaceTopicEventSubscriptionsClient.GetFullURL + // HTTP status codes to indicate success: http.StatusOK + GetFullURL func(ctx context.Context, resourceGroupName string, namespaceName string, topicName string, eventSubscriptionName string, options *armeventgrid.NamespaceTopicEventSubscriptionsClientGetFullURLOptions) (resp azfake.Responder[armeventgrid.NamespaceTopicEventSubscriptionsClientGetFullURLResponse], errResp azfake.ErrorResponder) + // NewListByNamespaceTopicPager is the fake for method NamespaceTopicEventSubscriptionsClient.NewListByNamespaceTopicPager // HTTP status codes to indicate success: http.StatusOK NewListByNamespaceTopicPager func(resourceGroupName string, namespaceName string, topicName string, options *armeventgrid.NamespaceTopicEventSubscriptionsClientListByNamespaceTopicOptions) (resp azfake.PagerResponder[armeventgrid.NamespaceTopicEventSubscriptionsClientListByNamespaceTopicResponse]) @@ -93,6 +97,8 @@ func (n *NamespaceTopicEventSubscriptionsServerTransport) Do(req *http.Request) resp, err = n.dispatchGet(req) case "NamespaceTopicEventSubscriptionsClient.GetDeliveryAttributes": resp, err = n.dispatchGetDeliveryAttributes(req) + case "NamespaceTopicEventSubscriptionsClient.GetFullURL": + resp, err = n.dispatchGetFullURL(req) case "NamespaceTopicEventSubscriptionsClient.NewListByNamespaceTopicPager": resp, err = n.dispatchNewListByNamespaceTopicPager(req) case "NamespaceTopicEventSubscriptionsClient.BeginUpdate": @@ -298,6 +304,47 @@ func (n *NamespaceTopicEventSubscriptionsServerTransport) dispatchGetDeliveryAtt return resp, nil } +func (n *NamespaceTopicEventSubscriptionsServerTransport) dispatchGetFullURL(req *http.Request) (*http.Response, error) { + if n.srv.GetFullURL == nil { + return nil, &nonRetriableError{errors.New("fake for method GetFullURL not implemented")} + } + const regexStr = `/subscriptions/(?P[!#&$-;=?-\[\]_a-zA-Z0-9~%@]+)/resourceGroups/(?P[!#&$-;=?-\[\]_a-zA-Z0-9~%@]+)/providers/Microsoft\.EventGrid/namespaces/(?P[!#&$-;=?-\[\]_a-zA-Z0-9~%@]+)/topics/(?P[!#&$-;=?-\[\]_a-zA-Z0-9~%@]+)/eventSubscriptions/(?P[!#&$-;=?-\[\]_a-zA-Z0-9~%@]+)/getFullUrl` + regex := regexp.MustCompile(regexStr) + matches := regex.FindStringSubmatch(req.URL.EscapedPath()) + if matches == nil || len(matches) < 5 { + return nil, fmt.Errorf("failed to parse path %s", req.URL.Path) + } + resourceGroupNameParam, err := url.PathUnescape(matches[regex.SubexpIndex("resourceGroupName")]) + if err != nil { + return nil, err + } + namespaceNameParam, err := url.PathUnescape(matches[regex.SubexpIndex("namespaceName")]) + if err != nil { + return nil, err + } + topicNameParam, err := url.PathUnescape(matches[regex.SubexpIndex("topicName")]) + if err != nil { + return nil, err + } + eventSubscriptionNameParam, err := url.PathUnescape(matches[regex.SubexpIndex("eventSubscriptionName")]) + if err != nil { + return nil, err + } + respr, errRespr := n.srv.GetFullURL(req.Context(), resourceGroupNameParam, namespaceNameParam, topicNameParam, eventSubscriptionNameParam, nil) + if respErr := server.GetError(errRespr, req); respErr != nil { + return nil, respErr + } + respContent := server.GetResponseContent(respr) + if !contains([]int{http.StatusOK}, respContent.HTTPStatus) { + return nil, &nonRetriableError{fmt.Errorf("unexpected status code %d. acceptable values are http.StatusOK", respContent.HTTPStatus)} + } + resp, err := server.MarshalResponseAsJSON(respContent, server.GetResponse(respr).SubscriptionFullURL, req) + if err != nil { + return nil, err + } + return resp, nil +} + func (n *NamespaceTopicEventSubscriptionsServerTransport) dispatchNewListByNamespaceTopicPager(req *http.Request) (*http.Response, error) { if n.srv.NewListByNamespaceTopicPager == nil { return nil, &nonRetriableError{errors.New("fake for method NewListByNamespaceTopicPager not implemented")} diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/fake/time_rfc3339.go b/sdk/resourcemanager/eventgrid/armeventgrid/fake/time_rfc3339.go index b0535a7b63e6..81f308b0d343 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/fake/time_rfc3339.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/fake/time_rfc3339.go @@ -19,12 +19,16 @@ import ( ) // Azure reports time in UTC but it doesn't include the 'Z' time zone suffix in some cases. -var tzOffsetRegex = regexp.MustCompile(`(Z|z|\+|-)(\d+:\d+)*"*$`) +var tzOffsetRegex = regexp.MustCompile(`(?:Z|z|\+|-)(?:\d+:\d+)*"*$`) const ( - utcDateTimeJSON = `"2006-01-02T15:04:05.999999999"` - utcDateTime = "2006-01-02T15:04:05.999999999" - dateTimeJSON = `"` + time.RFC3339Nano + `"` + utcDateTime = "2006-01-02T15:04:05.999999999" + utcDateTimeJSON = `"` + utcDateTime + `"` + utcDateTimeNoT = "2006-01-02 15:04:05.999999999" + utcDateTimeJSONNoT = `"` + utcDateTimeNoT + `"` + dateTimeNoT = `2006-01-02 15:04:05.999999999Z07:00` + dateTimeJSON = `"` + time.RFC3339Nano + `"` + dateTimeJSONNoT = `"` + dateTimeNoT + `"` ) type dateTimeRFC3339 time.Time @@ -40,17 +44,33 @@ func (t dateTimeRFC3339) MarshalText() ([]byte, error) { } func (t *dateTimeRFC3339) UnmarshalJSON(data []byte) error { - layout := utcDateTimeJSON - if tzOffsetRegex.Match(data) { + tzOffset := tzOffsetRegex.Match(data) + hasT := strings.Contains(string(data), "T") || strings.Contains(string(data), "t") + var layout string + if tzOffset && hasT { layout = dateTimeJSON + } else if tzOffset { + layout = dateTimeJSONNoT + } else if hasT { + layout = utcDateTimeJSON + } else { + layout = utcDateTimeJSONNoT } return t.Parse(layout, string(data)) } func (t *dateTimeRFC3339) UnmarshalText(data []byte) error { - layout := utcDateTime - if tzOffsetRegex.Match(data) { + tzOffset := tzOffsetRegex.Match(data) + hasT := strings.Contains(string(data), "T") || strings.Contains(string(data), "t") + var layout string + if tzOffset && hasT { layout = time.RFC3339Nano + } else if tzOffset { + layout = dateTimeNoT + } else if hasT { + layout = utcDateTime + } else { + layout = utcDateTimeNoT } return t.Parse(layout, string(data)) } @@ -61,6 +81,10 @@ func (t *dateTimeRFC3339) Parse(layout, value string) error { return err } +func (t dateTimeRFC3339) String() string { + return time.Time(t).Format(time.RFC3339Nano) +} + func populateDateTimeRFC3339(m map[string]any, k string, t *time.Time) { if t == nil { return @@ -74,7 +98,7 @@ func populateDateTimeRFC3339(m map[string]any, k string, t *time.Time) { } func unpopulateDateTimeRFC3339(data json.RawMessage, fn string, t **time.Time) error { - if data == nil || strings.EqualFold(string(data), "null") { + if data == nil || string(data) == "null" { return nil } var aux dateTimeRFC3339 diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/models.go b/sdk/resourcemanager/eventgrid/armeventgrid/models.go index 82a9392fed22..b2ed0ddf71a7 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/models.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/models.go @@ -264,6 +264,9 @@ type Client struct { type ClientAuthenticationSettings struct { // Alternative authentication name sources related to client authentication settings for namespace resource. AlternativeAuthenticationNameSources []*AlternativeAuthenticationNameSource + + // Custom JWT authentication settings for namespace resource. + CustomJwtAuthentication *CustomJwtAuthenticationSettings } // ClientCertificateAuthentication - The certificate authentication properties for the client. @@ -358,6 +361,73 @@ type ConnectionState struct { Status *PersistedConnectionStatus } +// CustomDomainConfiguration - A custom domain configuration that allows users to publish to their own domain name. +type CustomDomainConfiguration struct { + // REQUIRED; Fully Qualified Domain Name (FQDN) for the custom domain. + FullyQualifiedDomainName *string + + // The URL for the certificate that is used for publishing to the custom domain. We currently support certificates stored + // in Azure Key Vault only. While certificate URL can be either versioned URL of the + // following format https://{key-vault-name}.vault.azure.net/certificates/{certificate-name}/{version-id}, or unversioned + // URL of the following format (e.g., + // https://contosovault.vault.azure.net/certificates/contosocert, we support unversioned certificate URL only (e.g., https://contosovault.vault.azure.net/certificates/contosocert) + CertificateURL *string + + // Expected DNS TXT record name. Event Grid will check for a TXT record with this name in the DNS record set of the custom + // domain name to prove ownership over the domain. The values under this TXT record + // must contain the expected TXT record value. + ExpectedTxtRecordName *string + + // Expected DNS TXT record value. Event Grid will check for a TXT record with this value in the DNS record set of the custom + // domain name to prove ownership over the domain. + ExpectedTxtRecordValue *string + + // Identity info for accessing the certificate for the custom domain. This identity info must match an identity that has been + // set on the namespace. + Identity *CustomDomainIdentity + + // Validation state for the custom domain. This is a read only property and is initially set to 'Pending' and will be updated + // to 'Approved' by Event Grid only after ownership of the domain name has been + // successfully validated. + ValidationState *CustomDomainValidationState +} + +// CustomDomainIdentity - The identity information for retrieving the certificate for the custom domain. +type CustomDomainIdentity struct { + // The type of managed identity used. Can be either 'SystemAssigned' or 'UserAssigned'. + Type *CustomDomainIdentityType + + // The user identity associated with the resource. + UserAssignedIdentity *string +} + +// CustomDomainOwnershipValidationResult - Namespace custom domain ownership validation result. +type CustomDomainOwnershipValidationResult struct { + // List of custom domain configurations for the namespace under topic spaces configuration. + CustomDomainsForTopicSpacesConfiguration []*CustomDomainConfiguration + + // List of custom domain configurations for the namespace under topics configuration. + CustomDomainsForTopicsConfiguration []*CustomDomainConfiguration +} + +// CustomJwtAuthenticationManagedIdentity - The identity information for retrieving the certificate for custom JWT authentication. +type CustomJwtAuthenticationManagedIdentity struct { + // REQUIRED; The type of managed identity used. Can be either 'SystemAssigned' or 'UserAssigned'. + Type *CustomJwtAuthenticationManagedIdentityType + + // The user identity associated with the resource. + UserAssignedIdentity *string +} + +// CustomJwtAuthenticationSettings - Custom JWT authentication settings for namespace resource. +type CustomJwtAuthenticationSettings struct { + // Information about the certificate that is used for token validation. We currently support maximum 2 certificates. + IssuerCertificates []*IssuerCertificateInfo + + // Expected JWT token issuer. + TokenIssuer *string +} + // DeadLetterDestination - Information about the dead letter destination for an event subscription. To configure a deadletter // destination, do not directly instantiate an object of this class. Instead, instantiate an object of a // derived class. Currently, StorageBlobDeadLetterDestination is the only class that derives from this class. @@ -373,7 +443,7 @@ func (d *DeadLetterDestination) GetDeadLetterDestination() *DeadLetterDestinatio type DeadLetterWithResourceIdentity struct { // Information about the destination where events have to be delivered for the event subscription. Uses the managed identity // setup on the parent resource (namely, topic or domain) to acquire the - // authentication tokens being used during delivery / dead-lettering. + // authentication tokens being used during dead-lettering. DeadLetterDestination DeadLetterDestinationClassification // The identity to use when dead-lettering events. @@ -412,9 +482,9 @@ type DeliveryConfiguration struct { // DeliveryWithResourceIdentity - Information about the delivery for an event subscription with resource identity. type DeliveryWithResourceIdentity struct { - // Information about the destination where events have to be delivered for the event subscription. Uses Azure Event Grid's - // identity to acquire the authentication tokens being used during delivery / - // dead-lettering. + // Information about the destination where events have to be delivered for the event subscription. Uses the managed identity + // setup on the parent resource (namely, topic or domain) to acquire the + // authentication tokens being used during delivery. Destination EventSubscriptionDestinationClassification // The identity to use when delivering events. @@ -511,7 +581,7 @@ type DomainProperties struct { // READ-ONLY; Metric resource id for the Event Grid Domain Resource. MetricResourceID *string - // READ-ONLY + // READ-ONLY; List of private endpoint connections. PrivateEndpointConnections []*PrivateEndpointConnection // READ-ONLY; Provisioning state of the Event Grid Domain Resource. @@ -786,7 +856,7 @@ type EventSubscriptionFilter struct { SubjectEndsWith *string } -// EventSubscriptionFullURL - Full endpoint url of an event subscription +// EventSubscriptionFullURL - Full endpoint URL of an event subscription type EventSubscriptionFullURL struct { // The URL that represents the endpoint of the destination of an event subscription. EndpointURL *string @@ -794,8 +864,7 @@ type EventSubscriptionFullURL struct { // EventSubscriptionIdentity - The identity information with the event subscription. type EventSubscriptionIdentity struct { - // The type of managed identity used. The type 'SystemAssigned, UserAssigned' includes both an implicitly created identity - // and a set of user-assigned identities. The type 'None' will remove any identity. + // The type of managed identity used. Can be either 'SystemAssigned' or 'UserAssigned'. Type *EventSubscriptionIdentityType // The user identity associated with the resource. @@ -1148,6 +1217,16 @@ func (i *IsNullOrUndefinedFilter) GetFilter() *Filter { } } +// IssuerCertificateInfo - Information about the certificate that is used for token validation. +type IssuerCertificateInfo struct { + // REQUIRED; Keyvault certificate URL in https://keyvaultname.vault.azure.net/certificates/certificateName/certificateVersion + // format. + CertificateURL *string + + // The identity that will be used to access the certificate. + Identity *CustomJwtAuthenticationManagedIdentity +} + // JSONField - This is used to express the source of an input schema mapping for a single target field in the Event Grid Event // schema. This is currently used in the mappings for the 'id', 'topic' and 'eventtime' // properties. This represents a field in the input event schema. @@ -1283,7 +1362,9 @@ type NamespaceProperties struct { IsZoneRedundant *bool // Minimum TLS version of the publisher allowed to publish to this namespace. Only TLS version 1.2 is supported. - MinimumTLSVersionAllowed *TLSVersion + MinimumTLSVersionAllowed *TLSVersion + + // List of private endpoint connections. PrivateEndpointConnections []*PrivateEndpointConnection // This determines if traffic is allowed over public network. By default it is enabled. You can further restrict to specific @@ -1420,6 +1501,9 @@ type NamespaceUpdateParameterProperties struct { // Topic spaces configuration properties that can be updated. TopicSpacesConfiguration *UpdateTopicSpacesConfigurationInfo + + // Topics configuration properties that can be updated. + TopicsConfiguration *UpdateTopicsConfigurationInfo } // NamespaceUpdateParameters - Properties to update namespace. @@ -1582,7 +1666,13 @@ type NetworkSecurityPerimeterProfileAccessRuleProperties struct { PhoneNumbers []*string // List of subscriptions. - Subscriptions []*string + Subscriptions []*NetworkSecurityPerimeterSubscription +} + +// NetworkSecurityPerimeterSubscription - Network security perimeter subscription inbound access rule. +type NetworkSecurityPerimeterSubscription struct { + // Subscription id. + ID *string } // NumberGreaterThanAdvancedFilter - NumberGreaterThan Advanced Filter. @@ -2217,7 +2307,7 @@ type PartnerNamespaceProperties struct { // READ-ONLY; Endpoint for the partner namespace. Endpoint *string - // READ-ONLY + // READ-ONLY; List of private endpoint connections. PrivateEndpointConnections []*PrivateEndpointConnection // READ-ONLY; Provisioning state of the partner namespace. @@ -2566,14 +2656,18 @@ type PrivateLinkResourcesListResult struct { type PushInfo struct { // The dead letter destination of the event subscription. Any event that cannot be delivered to its' destination is sent to // the dead letter destination. Uses the managed identity setup on the parent - // resource (namely, namespace) to acquire the authentication tokens being used during delivery / dead-lettering. + // resource (namely, namespace) to acquire the authentication tokens being used during dead-lettering. DeadLetterDestinationWithResourceIdentity *DeadLetterWithResourceIdentity // Information about the destination where events have to be delivered for the event subscription. Uses the managed identity // setup on the parent resource (namely, topic or domain) to acquire the - // authentication tokens being used during delivery / dead-lettering. + // authentication tokens being used during delivery. DeliveryWithResourceIdentity *DeliveryWithResourceIdentity + // Information about the destination where events have to be delivered for the event subscription. Uses Azure Event Grid's + // identity to acquire the authentication tokens being used during delivery. + Destination EventSubscriptionDestinationClassification + // Time span duration in ISO 8601 format that determines how long messages are available to the subscription from the time // the message was published. This duration value is expressed using the following // format: \'P(n)Y(n)M(n)DT(n)H(n)M(n)S\', where: - (n) is replaced by the value of each time element that follows the (n). @@ -2685,6 +2779,7 @@ type RoutingEnrichments struct { // RoutingIdentityInfo - Routing identity info for topic spaces configuration. type RoutingIdentityInfo struct { + // Routing identity type for topic spaces configuration. Type *RoutingIdentityType UserAssignedIdentity *string } @@ -3193,6 +3288,12 @@ type Subscription struct { Type *string } +// SubscriptionFullURL - Full endpoint URL of an event subscription +type SubscriptionFullURL struct { + // The URL that represents the endpoint of the destination of an event subscription. + EndpointURL *string +} + // SubscriptionProperties - Properties of the event subscription. type SubscriptionProperties struct { // Information about the delivery configuration of the event subscription. @@ -3201,6 +3302,9 @@ type SubscriptionProperties struct { // The event delivery schema for the event subscription. EventDeliverySchema *DeliverySchema + // Expiration time of the event subscription. + ExpirationTimeUTC *time.Time + // Information about the filter for the event subscription. FiltersConfiguration *FiltersConfiguration @@ -3222,6 +3326,9 @@ type SubscriptionUpdateParametersProperties struct { // The event delivery schema for the event subscription. EventDeliverySchema *DeliverySchema + // Expiration time of the event subscription. + ExpirationTimeUTC *time.Time + // Information about the filter for the event subscription. FiltersConfiguration *FiltersConfiguration } @@ -3389,7 +3496,7 @@ type TopicProperties struct { // READ-ONLY; Metric resource id for the topic. MetricResourceID *string - // READ-ONLY + // READ-ONLY; List of private endpoint connections. PrivateEndpointConnections []*PrivateEndpointConnection // READ-ONLY; Provisioning state of the topic. @@ -3447,6 +3554,9 @@ type TopicSpacesConfiguration struct { // Client authentication settings for topic spaces configuration. ClientAuthentication *ClientAuthenticationSettings + // List of custom domain configurations for the namespace. + CustomDomains []*CustomDomainConfiguration + // The maximum number of sessions per authentication name. The property default value is 1. Min allowed value is 1 and max // allowed value is 100. MaximumClientSessionsPerAuthenticationName *int32 @@ -3583,6 +3693,9 @@ type TopicUpdateParameters struct { // TopicsConfiguration - Properties of the Topics Configuration. type TopicsConfiguration struct { + // List of custom domain configurations for the namespace. + CustomDomains []*CustomDomainConfiguration + // READ-ONLY; The hostname for the topics configuration. This is a read-only property. Hostname *string } @@ -3619,6 +3732,9 @@ type UpdateTopicSpacesConfigurationInfo struct { // Client authentication settings for topic spaces configuration. ClientAuthentication *ClientAuthenticationSettings + // Custom domain info for topic spaces configuration. + CustomDomains []*CustomDomainConfiguration + // The maximum number of sessions per authentication name. The property default value is 1. Min allowed value is 1 and max // allowed value is 100. MaximumClientSessionsPerAuthenticationName *int32 @@ -3640,6 +3756,12 @@ type UpdateTopicSpacesConfigurationInfo struct { State *TopicSpacesConfigurationState } +// UpdateTopicsConfigurationInfo - Properties of the topics configuration info of a namespace. +type UpdateTopicsConfigurationInfo struct { + // Custom domain info for topics configuration. + CustomDomains []*CustomDomainConfiguration +} + // UserIdentityProperties - The information about the user identity. type UserIdentityProperties struct { // The client id of user assigned identity. diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/models_serde.go b/sdk/resourcemanager/eventgrid/armeventgrid/models_serde.go index 74503f3caadb..89750ac22fc1 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/models_serde.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/models_serde.go @@ -599,6 +599,7 @@ func (c *Client) UnmarshalJSON(data []byte) error { func (c ClientAuthenticationSettings) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) populate(objectMap, "alternativeAuthenticationNameSources", c.AlternativeAuthenticationNameSources) + populate(objectMap, "customJwtAuthentication", c.CustomJwtAuthentication) return json.Marshal(objectMap) } @@ -614,6 +615,9 @@ func (c *ClientAuthenticationSettings) UnmarshalJSON(data []byte) error { case "alternativeAuthenticationNameSources": err = unpopulate(val, "AlternativeAuthenticationNameSources", &c.AlternativeAuthenticationNameSources) delete(rawMsg, key) + case "customJwtAuthentication": + err = unpopulate(val, "CustomJwtAuthentication", &c.CustomJwtAuthentication) + delete(rawMsg, key) } if err != nil { return fmt.Errorf("unmarshalling type %T: %v", c, err) @@ -875,6 +879,177 @@ func (c *ConnectionState) UnmarshalJSON(data []byte) error { return nil } +// MarshalJSON implements the json.Marshaller interface for type CustomDomainConfiguration. +func (c CustomDomainConfiguration) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "certificateUrl", c.CertificateURL) + populate(objectMap, "expectedTxtRecordName", c.ExpectedTxtRecordName) + populate(objectMap, "expectedTxtRecordValue", c.ExpectedTxtRecordValue) + populate(objectMap, "fullyQualifiedDomainName", c.FullyQualifiedDomainName) + populate(objectMap, "identity", c.Identity) + populate(objectMap, "validationState", c.ValidationState) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type CustomDomainConfiguration. +func (c *CustomDomainConfiguration) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", c, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "certificateUrl": + err = unpopulate(val, "CertificateURL", &c.CertificateURL) + delete(rawMsg, key) + case "expectedTxtRecordName": + err = unpopulate(val, "ExpectedTxtRecordName", &c.ExpectedTxtRecordName) + delete(rawMsg, key) + case "expectedTxtRecordValue": + err = unpopulate(val, "ExpectedTxtRecordValue", &c.ExpectedTxtRecordValue) + delete(rawMsg, key) + case "fullyQualifiedDomainName": + err = unpopulate(val, "FullyQualifiedDomainName", &c.FullyQualifiedDomainName) + delete(rawMsg, key) + case "identity": + err = unpopulate(val, "Identity", &c.Identity) + delete(rawMsg, key) + case "validationState": + err = unpopulate(val, "ValidationState", &c.ValidationState) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", c, err) + } + } + return nil +} + +// MarshalJSON implements the json.Marshaller interface for type CustomDomainIdentity. +func (c CustomDomainIdentity) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "type", c.Type) + populate(objectMap, "userAssignedIdentity", c.UserAssignedIdentity) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type CustomDomainIdentity. +func (c *CustomDomainIdentity) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", c, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "type": + err = unpopulate(val, "Type", &c.Type) + delete(rawMsg, key) + case "userAssignedIdentity": + err = unpopulate(val, "UserAssignedIdentity", &c.UserAssignedIdentity) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", c, err) + } + } + return nil +} + +// MarshalJSON implements the json.Marshaller interface for type CustomDomainOwnershipValidationResult. +func (c CustomDomainOwnershipValidationResult) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "customDomainsForTopicSpacesConfiguration", c.CustomDomainsForTopicSpacesConfiguration) + populate(objectMap, "customDomainsForTopicsConfiguration", c.CustomDomainsForTopicsConfiguration) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type CustomDomainOwnershipValidationResult. +func (c *CustomDomainOwnershipValidationResult) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", c, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "customDomainsForTopicSpacesConfiguration": + err = unpopulate(val, "CustomDomainsForTopicSpacesConfiguration", &c.CustomDomainsForTopicSpacesConfiguration) + delete(rawMsg, key) + case "customDomainsForTopicsConfiguration": + err = unpopulate(val, "CustomDomainsForTopicsConfiguration", &c.CustomDomainsForTopicsConfiguration) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", c, err) + } + } + return nil +} + +// MarshalJSON implements the json.Marshaller interface for type CustomJwtAuthenticationManagedIdentity. +func (c CustomJwtAuthenticationManagedIdentity) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "type", c.Type) + populate(objectMap, "userAssignedIdentity", c.UserAssignedIdentity) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type CustomJwtAuthenticationManagedIdentity. +func (c *CustomJwtAuthenticationManagedIdentity) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", c, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "type": + err = unpopulate(val, "Type", &c.Type) + delete(rawMsg, key) + case "userAssignedIdentity": + err = unpopulate(val, "UserAssignedIdentity", &c.UserAssignedIdentity) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", c, err) + } + } + return nil +} + +// MarshalJSON implements the json.Marshaller interface for type CustomJwtAuthenticationSettings. +func (c CustomJwtAuthenticationSettings) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "issuerCertificates", c.IssuerCertificates) + populate(objectMap, "tokenIssuer", c.TokenIssuer) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type CustomJwtAuthenticationSettings. +func (c *CustomJwtAuthenticationSettings) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", c, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "issuerCertificates": + err = unpopulate(val, "IssuerCertificates", &c.IssuerCertificates) + delete(rawMsg, key) + case "tokenIssuer": + err = unpopulate(val, "TokenIssuer", &c.TokenIssuer) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", c, err) + } + } + return nil +} + // MarshalJSON implements the json.Marshaller interface for type DeadLetterDestination. func (d DeadLetterDestination) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) @@ -2692,6 +2867,37 @@ func (i *IsNullOrUndefinedFilter) UnmarshalJSON(data []byte) error { return nil } +// MarshalJSON implements the json.Marshaller interface for type IssuerCertificateInfo. +func (i IssuerCertificateInfo) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "certificateUrl", i.CertificateURL) + populate(objectMap, "identity", i.Identity) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type IssuerCertificateInfo. +func (i *IssuerCertificateInfo) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", i, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "certificateUrl": + err = unpopulate(val, "CertificateURL", &i.CertificateURL) + delete(rawMsg, key) + case "identity": + err = unpopulate(val, "Identity", &i.Identity) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", i, err) + } + } + return nil +} + // MarshalJSON implements the json.Marshaller interface for type JSONField. func (j JSONField) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) @@ -3328,6 +3534,7 @@ func (n NamespaceUpdateParameterProperties) MarshalJSON() ([]byte, error) { populate(objectMap, "inboundIpRules", n.InboundIPRules) populate(objectMap, "publicNetworkAccess", n.PublicNetworkAccess) populate(objectMap, "topicSpacesConfiguration", n.TopicSpacesConfiguration) + populate(objectMap, "topicsConfiguration", n.TopicsConfiguration) return json.Marshal(objectMap) } @@ -3349,6 +3556,9 @@ func (n *NamespaceUpdateParameterProperties) UnmarshalJSON(data []byte) error { case "topicSpacesConfiguration": err = unpopulate(val, "TopicSpacesConfiguration", &n.TopicSpacesConfiguration) delete(rawMsg, key) + case "topicsConfiguration": + err = unpopulate(val, "TopicsConfiguration", &n.TopicsConfiguration) + delete(rawMsg, key) } if err != nil { return fmt.Errorf("unmarshalling type %T: %v", n, err) @@ -3782,6 +3992,33 @@ func (n *NetworkSecurityPerimeterProfileAccessRuleProperties) UnmarshalJSON(data return nil } +// MarshalJSON implements the json.Marshaller interface for type NetworkSecurityPerimeterSubscription. +func (n NetworkSecurityPerimeterSubscription) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "id", n.ID) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type NetworkSecurityPerimeterSubscription. +func (n *NetworkSecurityPerimeterSubscription) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", n, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "id": + err = unpopulate(val, "ID", &n.ID) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", n, err) + } + } + return nil +} + // MarshalJSON implements the json.Marshaller interface for type NumberGreaterThanAdvancedFilter. func (n NumberGreaterThanAdvancedFilter) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) @@ -6060,6 +6297,7 @@ func (p PushInfo) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) populate(objectMap, "deadLetterDestinationWithResourceIdentity", p.DeadLetterDestinationWithResourceIdentity) populate(objectMap, "deliveryWithResourceIdentity", p.DeliveryWithResourceIdentity) + populate(objectMap, "destination", p.Destination) populate(objectMap, "eventTimeToLive", p.EventTimeToLive) populate(objectMap, "maxDeliveryCount", p.MaxDeliveryCount) return json.Marshal(objectMap) @@ -6080,6 +6318,9 @@ func (p *PushInfo) UnmarshalJSON(data []byte) error { case "deliveryWithResourceIdentity": err = unpopulate(val, "DeliveryWithResourceIdentity", &p.DeliveryWithResourceIdentity) delete(rawMsg, key) + case "destination": + p.Destination, err = unmarshalEventSubscriptionDestinationClassification(val) + delete(rawMsg, key) case "eventTimeToLive": err = unpopulate(val, "EventTimeToLive", &p.EventTimeToLive) delete(rawMsg, key) @@ -7341,11 +7582,39 @@ func (s *Subscription) UnmarshalJSON(data []byte) error { return nil } +// MarshalJSON implements the json.Marshaller interface for type SubscriptionFullURL. +func (s SubscriptionFullURL) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "endpointUrl", s.EndpointURL) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type SubscriptionFullURL. +func (s *SubscriptionFullURL) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", s, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "endpointUrl": + err = unpopulate(val, "EndpointURL", &s.EndpointURL) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", s, err) + } + } + return nil +} + // MarshalJSON implements the json.Marshaller interface for type SubscriptionProperties. func (s SubscriptionProperties) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) populate(objectMap, "deliveryConfiguration", s.DeliveryConfiguration) populate(objectMap, "eventDeliverySchema", s.EventDeliverySchema) + populateDateTimeRFC3339(objectMap, "expirationTimeUtc", s.ExpirationTimeUTC) populate(objectMap, "filtersConfiguration", s.FiltersConfiguration) populate(objectMap, "provisioningState", s.ProvisioningState) return json.Marshal(objectMap) @@ -7366,6 +7635,9 @@ func (s *SubscriptionProperties) UnmarshalJSON(data []byte) error { case "eventDeliverySchema": err = unpopulate(val, "EventDeliverySchema", &s.EventDeliverySchema) delete(rawMsg, key) + case "expirationTimeUtc": + err = unpopulateDateTimeRFC3339(val, "ExpirationTimeUTC", &s.ExpirationTimeUTC) + delete(rawMsg, key) case "filtersConfiguration": err = unpopulate(val, "FiltersConfiguration", &s.FiltersConfiguration) delete(rawMsg, key) @@ -7412,6 +7684,7 @@ func (s SubscriptionUpdateParametersProperties) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) populate(objectMap, "deliveryConfiguration", s.DeliveryConfiguration) populate(objectMap, "eventDeliverySchema", s.EventDeliverySchema) + populateDateTimeRFC3339(objectMap, "expirationTimeUtc", s.ExpirationTimeUTC) populate(objectMap, "filtersConfiguration", s.FiltersConfiguration) return json.Marshal(objectMap) } @@ -7431,6 +7704,9 @@ func (s *SubscriptionUpdateParametersProperties) UnmarshalJSON(data []byte) erro case "eventDeliverySchema": err = unpopulate(val, "EventDeliverySchema", &s.EventDeliverySchema) delete(rawMsg, key) + case "expirationTimeUtc": + err = unpopulateDateTimeRFC3339(val, "ExpirationTimeUTC", &s.ExpirationTimeUTC) + delete(rawMsg, key) case "filtersConfiguration": err = unpopulate(val, "FiltersConfiguration", &s.FiltersConfiguration) delete(rawMsg, key) @@ -7954,6 +8230,7 @@ func (t *TopicSpaceProperties) UnmarshalJSON(data []byte) error { func (t TopicSpacesConfiguration) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) populate(objectMap, "clientAuthentication", t.ClientAuthentication) + populate(objectMap, "customDomains", t.CustomDomains) populate(objectMap, "hostname", t.Hostname) populate(objectMap, "maximumClientSessionsPerAuthenticationName", t.MaximumClientSessionsPerAuthenticationName) populate(objectMap, "maximumSessionExpiryInHours", t.MaximumSessionExpiryInHours) @@ -7976,6 +8253,9 @@ func (t *TopicSpacesConfiguration) UnmarshalJSON(data []byte) error { case "clientAuthentication": err = unpopulate(val, "ClientAuthentication", &t.ClientAuthentication) delete(rawMsg, key) + case "customDomains": + err = unpopulate(val, "CustomDomains", &t.CustomDomains) + delete(rawMsg, key) case "hostname": err = unpopulate(val, "Hostname", &t.Hostname) delete(rawMsg, key) @@ -8285,6 +8565,7 @@ func (t *TopicUpdateParameters) UnmarshalJSON(data []byte) error { // MarshalJSON implements the json.Marshaller interface for type TopicsConfiguration. func (t TopicsConfiguration) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) + populate(objectMap, "customDomains", t.CustomDomains) populate(objectMap, "hostname", t.Hostname) return json.Marshal(objectMap) } @@ -8298,6 +8579,9 @@ func (t *TopicsConfiguration) UnmarshalJSON(data []byte) error { for key, val := range rawMsg { var err error switch key { + case "customDomains": + err = unpopulate(val, "CustomDomains", &t.CustomDomains) + delete(rawMsg, key) case "hostname": err = unpopulate(val, "Hostname", &t.Hostname) delete(rawMsg, key) @@ -8387,6 +8671,7 @@ func (t *TrackedResource) UnmarshalJSON(data []byte) error { func (u UpdateTopicSpacesConfigurationInfo) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) populate(objectMap, "clientAuthentication", u.ClientAuthentication) + populate(objectMap, "customDomains", u.CustomDomains) populate(objectMap, "maximumClientSessionsPerAuthenticationName", u.MaximumClientSessionsPerAuthenticationName) populate(objectMap, "maximumSessionExpiryInHours", u.MaximumSessionExpiryInHours) populate(objectMap, "routeTopicResourceId", u.RouteTopicResourceID) @@ -8408,6 +8693,9 @@ func (u *UpdateTopicSpacesConfigurationInfo) UnmarshalJSON(data []byte) error { case "clientAuthentication": err = unpopulate(val, "ClientAuthentication", &u.ClientAuthentication) delete(rawMsg, key) + case "customDomains": + err = unpopulate(val, "CustomDomains", &u.CustomDomains) + delete(rawMsg, key) case "maximumClientSessionsPerAuthenticationName": err = unpopulate(val, "MaximumClientSessionsPerAuthenticationName", &u.MaximumClientSessionsPerAuthenticationName) delete(rawMsg, key) @@ -8434,6 +8722,33 @@ func (u *UpdateTopicSpacesConfigurationInfo) UnmarshalJSON(data []byte) error { return nil } +// MarshalJSON implements the json.Marshaller interface for type UpdateTopicsConfigurationInfo. +func (u UpdateTopicsConfigurationInfo) MarshalJSON() ([]byte, error) { + objectMap := make(map[string]any) + populate(objectMap, "customDomains", u.CustomDomains) + return json.Marshal(objectMap) +} + +// UnmarshalJSON implements the json.Unmarshaller interface for type UpdateTopicsConfigurationInfo. +func (u *UpdateTopicsConfigurationInfo) UnmarshalJSON(data []byte) error { + var rawMsg map[string]json.RawMessage + if err := json.Unmarshal(data, &rawMsg); err != nil { + return fmt.Errorf("unmarshalling type %T: %v", u, err) + } + for key, val := range rawMsg { + var err error + switch key { + case "customDomains": + err = unpopulate(val, "CustomDomains", &u.CustomDomains) + delete(rawMsg, key) + } + if err != nil { + return fmt.Errorf("unmarshalling type %T: %v", u, err) + } + } + return nil +} + // MarshalJSON implements the json.Marshaller interface for type UserIdentityProperties. func (u UserIdentityProperties) MarshalJSON() ([]byte, error) { objectMap := make(map[string]any) @@ -8810,7 +9125,7 @@ func populateAny(m map[string]any, k string, v any) { } func unpopulate(data json.RawMessage, fn string, v any) error { - if data == nil { + if data == nil || string(data) == "null" { return nil } if err := json.Unmarshal(data, v); err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/namespaces_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/namespaces_client.go index 659f4f7cf7ee..cbc25d36001d 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/namespaces_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/namespaces_client.go @@ -48,7 +48,7 @@ func NewNamespacesClient(subscriptionID string, credential azcore.TokenCredentia // BeginCreateOrUpdate - Asynchronously creates or updates a new namespace with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - namespaceInfo - Namespace information. @@ -75,7 +75,7 @@ func (client *NamespacesClient) BeginCreateOrUpdate(ctx context.Context, resourc // CreateOrUpdate - Asynchronously creates or updates a new namespace with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *NamespacesClient) createOrUpdate(ctx context.Context, resourceGroupName string, namespaceName string, namespaceInfo Namespace, options *NamespacesClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "NamespacesClient.BeginCreateOrUpdate" @@ -117,7 +117,7 @@ func (client *NamespacesClient) createOrUpdateCreateRequest(ctx context.Context, return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, namespaceInfo); err != nil { @@ -129,7 +129,7 @@ func (client *NamespacesClient) createOrUpdateCreateRequest(ctx context.Context, // BeginDelete - Delete existing namespace. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - options - NamespacesClientBeginDeleteOptions contains the optional parameters for the NamespacesClient.BeginDelete method. @@ -154,7 +154,7 @@ func (client *NamespacesClient) BeginDelete(ctx context.Context, resourceGroupNa // Delete - Delete existing namespace. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *NamespacesClient) deleteOperation(ctx context.Context, resourceGroupName string, namespaceName string, options *NamespacesClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "NamespacesClient.BeginDelete" @@ -196,7 +196,7 @@ func (client *NamespacesClient) deleteCreateRequest(ctx context.Context, resourc return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -205,7 +205,7 @@ func (client *NamespacesClient) deleteCreateRequest(ctx context.Context, resourc // Get - Get properties of a namespace. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - options - NamespacesClientGetOptions contains the optional parameters for the NamespacesClient.Get method. @@ -251,7 +251,7 @@ func (client *NamespacesClient) getCreateRequest(ctx context.Context, resourceGr return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -268,7 +268,7 @@ func (client *NamespacesClient) getHandleResponse(resp *http.Response) (Namespac // NewListByResourceGroupPager - List all the namespaces under a resource group. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - options - NamespacesClientListByResourceGroupOptions contains the optional parameters for the NamespacesClient.NewListByResourceGroupPager // method. @@ -311,13 +311,13 @@ func (client *NamespacesClient) listByResourceGroupCreateRequest(ctx context.Con return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -334,7 +334,7 @@ func (client *NamespacesClient) listByResourceGroupHandleResponse(resp *http.Res // NewListBySubscriptionPager - List all the namespaces under an Azure subscription. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - options - NamespacesClientListBySubscriptionOptions contains the optional parameters for the NamespacesClient.NewListBySubscriptionPager // method. func (client *NamespacesClient) NewListBySubscriptionPager(options *NamespacesClientListBySubscriptionOptions) *runtime.Pager[NamespacesClientListBySubscriptionResponse] { @@ -372,13 +372,13 @@ func (client *NamespacesClient) listBySubscriptionCreateRequest(ctx context.Cont return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -396,7 +396,7 @@ func (client *NamespacesClient) listBySubscriptionHandleResponse(resp *http.Resp // ListSharedAccessKeys - List the two keys used to publish to a namespace. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - options - NamespacesClientListSharedAccessKeysOptions contains the optional parameters for the NamespacesClient.ListSharedAccessKeys @@ -443,7 +443,7 @@ func (client *NamespacesClient) listSharedAccessKeysCreateRequest(ctx context.Co return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -461,7 +461,7 @@ func (client *NamespacesClient) listSharedAccessKeysHandleResponse(resp *http.Re // BeginRegenerateKey - Regenerate a shared access key for a namespace. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the Namespace. // - regenerateKeyRequest - Request body to regenerate key. @@ -488,7 +488,7 @@ func (client *NamespacesClient) BeginRegenerateKey(ctx context.Context, resource // RegenerateKey - Regenerate a shared access key for a namespace. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *NamespacesClient) regenerateKey(ctx context.Context, resourceGroupName string, namespaceName string, regenerateKeyRequest NamespaceRegenerateKeyRequest, options *NamespacesClientBeginRegenerateKeyOptions) (*http.Response, error) { var err error const operationName = "NamespacesClient.BeginRegenerateKey" @@ -530,7 +530,7 @@ func (client *NamespacesClient) regenerateKeyCreateRequest(ctx context.Context, return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, regenerateKeyRequest); err != nil { @@ -542,7 +542,7 @@ func (client *NamespacesClient) regenerateKeyCreateRequest(ctx context.Context, // BeginUpdate - Asynchronously updates a namespace with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - namespaceUpdateParameters - Namespace update information. @@ -568,7 +568,7 @@ func (client *NamespacesClient) BeginUpdate(ctx context.Context, resourceGroupNa // Update - Asynchronously updates a namespace with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *NamespacesClient) update(ctx context.Context, resourceGroupName string, namespaceName string, namespaceUpdateParameters NamespaceUpdateParameters, options *NamespacesClientBeginUpdateOptions) (*http.Response, error) { var err error const operationName = "NamespacesClient.BeginUpdate" @@ -610,7 +610,7 @@ func (client *NamespacesClient) updateCreateRequest(ctx context.Context, resourc return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, namespaceUpdateParameters); err != nil { @@ -618,3 +618,81 @@ func (client *NamespacesClient) updateCreateRequest(ctx context.Context, resourc } return req, nil } + +// BeginValidateCustomDomainOwnership - Performs ownership validation via checking TXT records for all custom domains in a +// namespace. +// If the operation fails it returns an *azcore.ResponseError type. +// +// Generated from API version 2024-06-01-preview +// - resourceGroupName - The name of the resource group within the user's subscription. +// - namespaceName - Name of the Namespace. +// - options - NamespacesClientBeginValidateCustomDomainOwnershipOptions contains the optional parameters for the NamespacesClient.BeginValidateCustomDomainOwnership +// method. +func (client *NamespacesClient) BeginValidateCustomDomainOwnership(ctx context.Context, resourceGroupName string, namespaceName string, options *NamespacesClientBeginValidateCustomDomainOwnershipOptions) (*runtime.Poller[NamespacesClientValidateCustomDomainOwnershipResponse], error) { + if options == nil || options.ResumeToken == "" { + resp, err := client.validateCustomDomainOwnership(ctx, resourceGroupName, namespaceName, options) + if err != nil { + return nil, err + } + poller, err := runtime.NewPoller(resp, client.internal.Pipeline(), &runtime.NewPollerOptions[NamespacesClientValidateCustomDomainOwnershipResponse]{ + FinalStateVia: runtime.FinalStateViaLocation, + Tracer: client.internal.Tracer(), + }) + return poller, err + } else { + return runtime.NewPollerFromResumeToken(options.ResumeToken, client.internal.Pipeline(), &runtime.NewPollerFromResumeTokenOptions[NamespacesClientValidateCustomDomainOwnershipResponse]{ + Tracer: client.internal.Tracer(), + }) + } +} + +// ValidateCustomDomainOwnership - Performs ownership validation via checking TXT records for all custom domains in a namespace. +// If the operation fails it returns an *azcore.ResponseError type. +// +// Generated from API version 2024-06-01-preview +func (client *NamespacesClient) validateCustomDomainOwnership(ctx context.Context, resourceGroupName string, namespaceName string, options *NamespacesClientBeginValidateCustomDomainOwnershipOptions) (*http.Response, error) { + var err error + const operationName = "NamespacesClient.BeginValidateCustomDomainOwnership" + ctx = context.WithValue(ctx, runtime.CtxAPINameKey{}, operationName) + ctx, endSpan := runtime.StartSpan(ctx, operationName, client.internal.Tracer(), nil) + defer func() { endSpan(err) }() + req, err := client.validateCustomDomainOwnershipCreateRequest(ctx, resourceGroupName, namespaceName, options) + if err != nil { + return nil, err + } + httpResp, err := client.internal.Pipeline().Do(req) + if err != nil { + return nil, err + } + if !runtime.HasStatusCode(httpResp, http.StatusOK, http.StatusAccepted) { + err = runtime.NewResponseError(httpResp) + return nil, err + } + return httpResp, nil +} + +// validateCustomDomainOwnershipCreateRequest creates the ValidateCustomDomainOwnership request. +func (client *NamespacesClient) validateCustomDomainOwnershipCreateRequest(ctx context.Context, resourceGroupName string, namespaceName string, options *NamespacesClientBeginValidateCustomDomainOwnershipOptions) (*policy.Request, error) { + urlPath := "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventGrid/namespaces/{namespaceName}/validateCustomDomainOwnership" + if client.subscriptionID == "" { + return nil, errors.New("parameter client.subscriptionID cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{subscriptionId}", url.PathEscape(client.subscriptionID)) + if resourceGroupName == "" { + return nil, errors.New("parameter resourceGroupName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{resourceGroupName}", url.PathEscape(resourceGroupName)) + if namespaceName == "" { + return nil, errors.New("parameter namespaceName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{namespaceName}", url.PathEscape(namespaceName)) + req, err := runtime.NewRequest(ctx, http.MethodPost, runtime.JoinPaths(client.internal.Endpoint(), urlPath)) + if err != nil { + return nil, err + } + reqQP := req.Raw().URL.Query() + reqQP.Set("api-version", "2024-06-01-preview") + req.Raw().URL.RawQuery = reqQP.Encode() + req.Raw().Header["Accept"] = []string{"application/json"} + return req, nil +} diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/namespaces_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/namespaces_client_example_test.go index d69f93bc0f96..169c8e8893e1 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/namespaces_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/namespaces_client_example_test.go @@ -18,7 +18,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Namespaces_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Namespaces_Get.json func ExampleNamespacesClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -57,7 +57,7 @@ func ExampleNamespacesClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Namespaces_CreateOrUpdate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Namespaces_CreateOrUpdate.json func ExampleNamespacesClient_BeginCreateOrUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -110,7 +110,7 @@ func ExampleNamespacesClient_BeginCreateOrUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Namespaces_Delete.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Namespaces_Delete.json func ExampleNamespacesClient_BeginDelete() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -131,7 +131,7 @@ func ExampleNamespacesClient_BeginDelete() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Namespaces_Update.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Namespaces_Update.json func ExampleNamespacesClient_BeginUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -173,7 +173,7 @@ func ExampleNamespacesClient_BeginUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Namespaces_ListBySubscription.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Namespaces_ListBySubscription.json func ExampleNamespacesClient_NewListBySubscriptionPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -222,7 +222,7 @@ func ExampleNamespacesClient_NewListBySubscriptionPager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Namespaces_ListByResourceGroup.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Namespaces_ListByResourceGroup.json func ExampleNamespacesClient_NewListByResourceGroupPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -271,7 +271,7 @@ func ExampleNamespacesClient_NewListByResourceGroupPager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Namespaces_ListSharedAccessKeys.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Namespaces_ListSharedAccessKeys.json func ExampleNamespacesClient_ListSharedAccessKeys() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -295,7 +295,7 @@ func ExampleNamespacesClient_ListSharedAccessKeys() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Namespaces_RegenerateKey.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Namespaces_RegenerateKey.json func ExampleNamespacesClient_BeginRegenerateKey() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -324,3 +324,51 @@ func ExampleNamespacesClient_BeginRegenerateKey() { // Key2: to.Ptr("testKey2Value"), // } } + +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Namespaces_ValidateCustomDomainOwnership.json +func ExampleNamespacesClient_BeginValidateCustomDomainOwnership() { + cred, err := azidentity.NewDefaultAzureCredential(nil) + if err != nil { + log.Fatalf("failed to obtain a credential: %v", err) + } + ctx := context.Background() + clientFactory, err := armeventgrid.NewClientFactory("", cred, nil) + if err != nil { + log.Fatalf("failed to create client: %v", err) + } + poller, err := clientFactory.NewNamespacesClient().BeginValidateCustomDomainOwnership(ctx, "examplerg", "exampleNamespaceName1", nil) + if err != nil { + log.Fatalf("failed to finish the request: %v", err) + } + res, err := poller.PollUntilDone(ctx, nil) + if err != nil { + log.Fatalf("failed to pull the result: %v", err) + } + // You could use response here. We use blank identifier for just demo purposes. + _ = res + // If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes. + // res.CustomDomainOwnershipValidationResult = armeventgrid.CustomDomainOwnershipValidationResult{ + // CustomDomainsForTopicSpacesConfiguration: []*armeventgrid.CustomDomainConfiguration{ + // { + // CertificateURL: to.Ptr("string"), + // ExpectedTxtRecordName: to.Ptr("txt-record-name-2"), + // ExpectedTxtRecordValue: to.Ptr("txt-record-value-2"), + // FullyQualifiedDomainName: to.Ptr("custom-domain-name-2"), + // Identity: &armeventgrid.CustomDomainIdentity{ + // Type: to.Ptr(armeventgrid.CustomDomainIdentityTypeSystemAssigned), + // }, + // ValidationState: to.Ptr(armeventgrid.CustomDomainValidationStatePending), + // }}, + // CustomDomainsForTopicsConfiguration: []*armeventgrid.CustomDomainConfiguration{ + // { + // CertificateURL: to.Ptr("string"), + // ExpectedTxtRecordName: to.Ptr("txt-record-name-1"), + // ExpectedTxtRecordValue: to.Ptr("txt-record-value-1"), + // FullyQualifiedDomainName: to.Ptr("custom-domain-name-1"), + // Identity: &armeventgrid.CustomDomainIdentity{ + // Type: to.Ptr(armeventgrid.CustomDomainIdentityTypeSystemAssigned), + // }, + // ValidationState: to.Ptr(armeventgrid.CustomDomainValidationStatePending), + // }}, + // } +} diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/namespacetopiceventsubscriptions_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/namespacetopiceventsubscriptions_client.go index db89990fa85f..99c06313d5b9 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/namespacetopiceventsubscriptions_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/namespacetopiceventsubscriptions_client.go @@ -49,11 +49,11 @@ func NewNamespaceTopicEventSubscriptionsClient(subscriptionID string, credential // Existing event subscriptions will be updated with this API. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - topicName - Name of the namespace topic. -// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 100 +// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 50 // characters in length and use alphanumeric letters only. // - eventSubscriptionInfo - Event subscription properties containing the delivery mode, filter information, and others. // - options - NamespaceTopicEventSubscriptionsClientBeginCreateOrUpdateOptions contains the optional parameters for the NamespaceTopicEventSubscriptionsClient.BeginCreateOrUpdate @@ -80,7 +80,7 @@ func (client *NamespaceTopicEventSubscriptionsClient) BeginCreateOrUpdate(ctx co // Existing event subscriptions will be updated with this API. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *NamespaceTopicEventSubscriptionsClient) createOrUpdate(ctx context.Context, resourceGroupName string, namespaceName string, topicName string, eventSubscriptionName string, eventSubscriptionInfo Subscription, options *NamespaceTopicEventSubscriptionsClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "NamespaceTopicEventSubscriptionsClient.BeginCreateOrUpdate" @@ -130,7 +130,7 @@ func (client *NamespaceTopicEventSubscriptionsClient) createOrUpdateCreateReques return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, eventSubscriptionInfo); err != nil { @@ -142,12 +142,11 @@ func (client *NamespaceTopicEventSubscriptionsClient) createOrUpdateCreateReques // BeginDelete - Delete an existing event subscription of a namespace topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - topicName - Name of the namespace topic. -// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 100 -// characters in length and use alphanumeric letters only. +// - eventSubscriptionName - Name of the event subscription to be deleted. // - options - NamespaceTopicEventSubscriptionsClientBeginDeleteOptions contains the optional parameters for the NamespaceTopicEventSubscriptionsClient.BeginDelete // method. func (client *NamespaceTopicEventSubscriptionsClient) BeginDelete(ctx context.Context, resourceGroupName string, namespaceName string, topicName string, eventSubscriptionName string, options *NamespaceTopicEventSubscriptionsClientBeginDeleteOptions) (*runtime.Poller[NamespaceTopicEventSubscriptionsClientDeleteResponse], error) { @@ -171,7 +170,7 @@ func (client *NamespaceTopicEventSubscriptionsClient) BeginDelete(ctx context.Co // Delete - Delete an existing event subscription of a namespace topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *NamespaceTopicEventSubscriptionsClient) deleteOperation(ctx context.Context, resourceGroupName string, namespaceName string, topicName string, eventSubscriptionName string, options *NamespaceTopicEventSubscriptionsClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "NamespaceTopicEventSubscriptionsClient.BeginDelete" @@ -221,7 +220,7 @@ func (client *NamespaceTopicEventSubscriptionsClient) deleteCreateRequest(ctx co return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -230,12 +229,11 @@ func (client *NamespaceTopicEventSubscriptionsClient) deleteCreateRequest(ctx co // Get - Get properties of an event subscription of a namespace topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - topicName - Name of the namespace topic. -// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 100 -// characters in length and use alphanumeric letters only. +// - eventSubscriptionName - Name of the event subscription to be found. // - options - NamespaceTopicEventSubscriptionsClientGetOptions contains the optional parameters for the NamespaceTopicEventSubscriptionsClient.Get // method. func (client *NamespaceTopicEventSubscriptionsClient) Get(ctx context.Context, resourceGroupName string, namespaceName string, topicName string, eventSubscriptionName string, options *NamespaceTopicEventSubscriptionsClientGetOptions) (NamespaceTopicEventSubscriptionsClientGetResponse, error) { @@ -288,7 +286,7 @@ func (client *NamespaceTopicEventSubscriptionsClient) getCreateRequest(ctx conte return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -306,12 +304,11 @@ func (client *NamespaceTopicEventSubscriptionsClient) getHandleResponse(resp *ht // GetDeliveryAttributes - Get all delivery attributes for an event subscription of a namespace topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - topicName - Name of the namespace topic. -// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 100 -// characters in length and use alphanumeric letters only. +// - eventSubscriptionName - Name of the event subscription. // - options - NamespaceTopicEventSubscriptionsClientGetDeliveryAttributesOptions contains the optional parameters for the NamespaceTopicEventSubscriptionsClient.GetDeliveryAttributes // method. func (client *NamespaceTopicEventSubscriptionsClient) GetDeliveryAttributes(ctx context.Context, resourceGroupName string, namespaceName string, topicName string, eventSubscriptionName string, options *NamespaceTopicEventSubscriptionsClientGetDeliveryAttributesOptions) (NamespaceTopicEventSubscriptionsClientGetDeliveryAttributesResponse, error) { @@ -364,7 +361,7 @@ func (client *NamespaceTopicEventSubscriptionsClient) getDeliveryAttributesCreat return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -379,9 +376,84 @@ func (client *NamespaceTopicEventSubscriptionsClient) getDeliveryAttributesHandl return result, nil } +// GetFullURL - Get the full endpoint URL for an event subscription of a namespace topic. +// If the operation fails it returns an *azcore.ResponseError type. +// +// Generated from API version 2024-06-01-preview +// - resourceGroupName - The name of the resource group within the user's subscription. +// - namespaceName - Name of the namespace. +// - topicName - Name of the namespace topic. +// - eventSubscriptionName - Name of the event subscription. +// - options - NamespaceTopicEventSubscriptionsClientGetFullURLOptions contains the optional parameters for the NamespaceTopicEventSubscriptionsClient.GetFullURL +// method. +func (client *NamespaceTopicEventSubscriptionsClient) GetFullURL(ctx context.Context, resourceGroupName string, namespaceName string, topicName string, eventSubscriptionName string, options *NamespaceTopicEventSubscriptionsClientGetFullURLOptions) (NamespaceTopicEventSubscriptionsClientGetFullURLResponse, error) { + var err error + const operationName = "NamespaceTopicEventSubscriptionsClient.GetFullURL" + ctx = context.WithValue(ctx, runtime.CtxAPINameKey{}, operationName) + ctx, endSpan := runtime.StartSpan(ctx, operationName, client.internal.Tracer(), nil) + defer func() { endSpan(err) }() + req, err := client.getFullURLCreateRequest(ctx, resourceGroupName, namespaceName, topicName, eventSubscriptionName, options) + if err != nil { + return NamespaceTopicEventSubscriptionsClientGetFullURLResponse{}, err + } + httpResp, err := client.internal.Pipeline().Do(req) + if err != nil { + return NamespaceTopicEventSubscriptionsClientGetFullURLResponse{}, err + } + if !runtime.HasStatusCode(httpResp, http.StatusOK) { + err = runtime.NewResponseError(httpResp) + return NamespaceTopicEventSubscriptionsClientGetFullURLResponse{}, err + } + resp, err := client.getFullURLHandleResponse(httpResp) + return resp, err +} + +// getFullURLCreateRequest creates the GetFullURL request. +func (client *NamespaceTopicEventSubscriptionsClient) getFullURLCreateRequest(ctx context.Context, resourceGroupName string, namespaceName string, topicName string, eventSubscriptionName string, options *NamespaceTopicEventSubscriptionsClientGetFullURLOptions) (*policy.Request, error) { + urlPath := "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventGrid/namespaces/{namespaceName}/topics/{topicName}/eventSubscriptions/{eventSubscriptionName}/getFullUrl" + if client.subscriptionID == "" { + return nil, errors.New("parameter client.subscriptionID cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{subscriptionId}", url.PathEscape(client.subscriptionID)) + if resourceGroupName == "" { + return nil, errors.New("parameter resourceGroupName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{resourceGroupName}", url.PathEscape(resourceGroupName)) + if namespaceName == "" { + return nil, errors.New("parameter namespaceName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{namespaceName}", url.PathEscape(namespaceName)) + if topicName == "" { + return nil, errors.New("parameter topicName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{topicName}", url.PathEscape(topicName)) + if eventSubscriptionName == "" { + return nil, errors.New("parameter eventSubscriptionName cannot be empty") + } + urlPath = strings.ReplaceAll(urlPath, "{eventSubscriptionName}", url.PathEscape(eventSubscriptionName)) + req, err := runtime.NewRequest(ctx, http.MethodPost, runtime.JoinPaths(client.internal.Endpoint(), urlPath)) + if err != nil { + return nil, err + } + reqQP := req.Raw().URL.Query() + reqQP.Set("api-version", "2024-06-01-preview") + req.Raw().URL.RawQuery = reqQP.Encode() + req.Raw().Header["Accept"] = []string{"application/json"} + return req, nil +} + +// getFullURLHandleResponse handles the GetFullURL response. +func (client *NamespaceTopicEventSubscriptionsClient) getFullURLHandleResponse(resp *http.Response) (NamespaceTopicEventSubscriptionsClientGetFullURLResponse, error) { + result := NamespaceTopicEventSubscriptionsClientGetFullURLResponse{} + if err := runtime.UnmarshalAsJSON(resp, &result.SubscriptionFullURL); err != nil { + return NamespaceTopicEventSubscriptionsClientGetFullURLResponse{}, err + } + return result, nil +} + // NewListByNamespaceTopicPager - List event subscriptions that belong to a specific namespace topic. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - topicName - Name of the namespace topic. @@ -434,13 +506,13 @@ func (client *NamespaceTopicEventSubscriptionsClient) listByNamespaceTopicCreate return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -458,12 +530,11 @@ func (client *NamespaceTopicEventSubscriptionsClient) listByNamespaceTopicHandle // BeginUpdate - Update an existing event subscription of a namespace topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - topicName - Name of the namespace topic. -// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 100 -// characters in length and use alphanumeric letters only. +// - eventSubscriptionName - Name of the event subscription to be updated. // - eventSubscriptionUpdateParameters - Updated event subscription information. // - options - NamespaceTopicEventSubscriptionsClientBeginUpdateOptions contains the optional parameters for the NamespaceTopicEventSubscriptionsClient.BeginUpdate // method. @@ -488,7 +559,7 @@ func (client *NamespaceTopicEventSubscriptionsClient) BeginUpdate(ctx context.Co // Update - Update an existing event subscription of a namespace topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *NamespaceTopicEventSubscriptionsClient) update(ctx context.Context, resourceGroupName string, namespaceName string, topicName string, eventSubscriptionName string, eventSubscriptionUpdateParameters SubscriptionUpdateParameters, options *NamespaceTopicEventSubscriptionsClientBeginUpdateOptions) (*http.Response, error) { var err error const operationName = "NamespaceTopicEventSubscriptionsClient.BeginUpdate" @@ -538,7 +609,7 @@ func (client *NamespaceTopicEventSubscriptionsClient) updateCreateRequest(ctx co return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, eventSubscriptionUpdateParameters); err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/namespacetopiceventsubscriptions_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/namespacetopiceventsubscriptions_client_example_test.go index 40215a465488..15e5b7db783d 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/namespacetopiceventsubscriptions_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/namespacetopiceventsubscriptions_client_example_test.go @@ -18,7 +18,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/NamespaceTopicEventSubscriptions_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/NamespaceTopicEventSubscriptions_Get.json func ExampleNamespaceTopicEventSubscriptionsClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -55,7 +55,7 @@ func ExampleNamespaceTopicEventSubscriptionsClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/NamespaceTopicEventSubscriptions_CreateOrUpdate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/NamespaceTopicEventSubscriptions_CreateOrUpdate.json func ExampleNamespaceTopicEventSubscriptionsClient_BeginCreateOrUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -108,7 +108,7 @@ func ExampleNamespaceTopicEventSubscriptionsClient_BeginCreateOrUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/NamespaceTopicEventSubscriptions_Delete.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/NamespaceTopicEventSubscriptions_Delete.json func ExampleNamespaceTopicEventSubscriptionsClient_BeginDelete() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -129,7 +129,7 @@ func ExampleNamespaceTopicEventSubscriptionsClient_BeginDelete() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/NamespaceTopicEventSubscriptions_Update.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/NamespaceTopicEventSubscriptions_Update.json func ExampleNamespaceTopicEventSubscriptionsClient_BeginUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -182,7 +182,7 @@ func ExampleNamespaceTopicEventSubscriptionsClient_BeginUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/NamespaceTopicEventSubscriptions_ListByNamespaceTopic.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/NamespaceTopicEventSubscriptions_ListByNamespaceTopic.json func ExampleNamespaceTopicEventSubscriptionsClient_NewListByNamespaceTopicPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -246,7 +246,7 @@ func ExampleNamespaceTopicEventSubscriptionsClient_NewListByNamespaceTopicPager( } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/NamespaceTopicEventSubscriptions_GetDeliveryAttributes.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/NamespaceTopicEventSubscriptions_GetDeliveryAttributes.json func ExampleNamespaceTopicEventSubscriptionsClient_GetDeliveryAttributes() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -291,3 +291,26 @@ func ExampleNamespaceTopicEventSubscriptionsClient_GetDeliveryAttributes() { // }}, // } } + +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/NamespaceTopicEventSubscriptions_GetFullUrl.json +func ExampleNamespaceTopicEventSubscriptionsClient_GetFullURL() { + cred, err := azidentity.NewDefaultAzureCredential(nil) + if err != nil { + log.Fatalf("failed to obtain a credential: %v", err) + } + ctx := context.Background() + clientFactory, err := armeventgrid.NewClientFactory("", cred, nil) + if err != nil { + log.Fatalf("failed to create client: %v", err) + } + res, err := clientFactory.NewNamespaceTopicEventSubscriptionsClient().GetFullURL(ctx, "examplerg", "exampleNamespaceName1", "exampleDomainTopic1", "examplesubscription1", nil) + if err != nil { + log.Fatalf("failed to finish the request: %v", err) + } + // You could use response here. We use blank identifier for just demo purposes. + _ = res + // If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes. + // res.SubscriptionFullURL = armeventgrid.SubscriptionFullURL{ + // EndpointURL: to.Ptr("https://requestb.in/15ksip71"), + // } +} diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/namespacetopics_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/namespacetopics_client.go index 7fb32aa6c748..fee3c1e59724 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/namespacetopics_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/namespacetopics_client.go @@ -48,7 +48,7 @@ func NewNamespaceTopicsClient(subscriptionID string, credential azcore.TokenCred // BeginCreateOrUpdate - Asynchronously creates a new namespace topic with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - topicName - Name of the namespace topic. @@ -76,7 +76,7 @@ func (client *NamespaceTopicsClient) BeginCreateOrUpdate(ctx context.Context, re // CreateOrUpdate - Asynchronously creates a new namespace topic with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *NamespaceTopicsClient) createOrUpdate(ctx context.Context, resourceGroupName string, namespaceName string, topicName string, namespaceTopicInfo NamespaceTopic, options *NamespaceTopicsClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "NamespaceTopicsClient.BeginCreateOrUpdate" @@ -122,7 +122,7 @@ func (client *NamespaceTopicsClient) createOrUpdateCreateRequest(ctx context.Con return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, namespaceTopicInfo); err != nil { @@ -134,7 +134,7 @@ func (client *NamespaceTopicsClient) createOrUpdateCreateRequest(ctx context.Con // BeginDelete - Delete existing namespace topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - topicName - Name of the topic. @@ -161,7 +161,7 @@ func (client *NamespaceTopicsClient) BeginDelete(ctx context.Context, resourceGr // Delete - Delete existing namespace topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *NamespaceTopicsClient) deleteOperation(ctx context.Context, resourceGroupName string, namespaceName string, topicName string, options *NamespaceTopicsClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "NamespaceTopicsClient.BeginDelete" @@ -207,7 +207,7 @@ func (client *NamespaceTopicsClient) deleteCreateRequest(ctx context.Context, re return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -216,7 +216,7 @@ func (client *NamespaceTopicsClient) deleteCreateRequest(ctx context.Context, re // Get - Get properties of a namespace topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - topicName - Name of the namespace topic. @@ -267,7 +267,7 @@ func (client *NamespaceTopicsClient) getCreateRequest(ctx context.Context, resou return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -284,7 +284,7 @@ func (client *NamespaceTopicsClient) getHandleResponse(resp *http.Response) (Nam // NewListByNamespacePager - List all the namespace topics under a namespace. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - options - NamespaceTopicsClientListByNamespaceOptions contains the optional parameters for the NamespaceTopicsClient.NewListByNamespacePager @@ -332,13 +332,13 @@ func (client *NamespaceTopicsClient) listByNamespaceCreateRequest(ctx context.Co return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -356,7 +356,7 @@ func (client *NamespaceTopicsClient) listByNamespaceHandleResponse(resp *http.Re // ListSharedAccessKeys - List the two keys used to publish to a namespace topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - topicName - Name of the topic. @@ -408,7 +408,7 @@ func (client *NamespaceTopicsClient) listSharedAccessKeysCreateRequest(ctx conte return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -426,7 +426,7 @@ func (client *NamespaceTopicsClient) listSharedAccessKeysHandleResponse(resp *ht // BeginRegenerateKey - Regenerate a shared access key for a namespace topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - topicName - Name of the topic. @@ -454,7 +454,7 @@ func (client *NamespaceTopicsClient) BeginRegenerateKey(ctx context.Context, res // RegenerateKey - Regenerate a shared access key for a namespace topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *NamespaceTopicsClient) regenerateKey(ctx context.Context, resourceGroupName string, namespaceName string, topicName string, regenerateKeyRequest TopicRegenerateKeyRequest, options *NamespaceTopicsClientBeginRegenerateKeyOptions) (*http.Response, error) { var err error const operationName = "NamespaceTopicsClient.BeginRegenerateKey" @@ -500,7 +500,7 @@ func (client *NamespaceTopicsClient) regenerateKeyCreateRequest(ctx context.Cont return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, regenerateKeyRequest); err != nil { @@ -512,7 +512,7 @@ func (client *NamespaceTopicsClient) regenerateKeyCreateRequest(ctx context.Cont // BeginUpdate - Asynchronously updates a namespace topic with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - topicName - Name of the namespace topic. @@ -540,7 +540,7 @@ func (client *NamespaceTopicsClient) BeginUpdate(ctx context.Context, resourceGr // Update - Asynchronously updates a namespace topic with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *NamespaceTopicsClient) update(ctx context.Context, resourceGroupName string, namespaceName string, topicName string, namespaceTopicUpdateParameters NamespaceTopicUpdateParameters, options *NamespaceTopicsClientBeginUpdateOptions) (*http.Response, error) { var err error const operationName = "NamespaceTopicsClient.BeginUpdate" @@ -586,7 +586,7 @@ func (client *NamespaceTopicsClient) updateCreateRequest(ctx context.Context, re return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, namespaceTopicUpdateParameters); err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/namespacetopics_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/namespacetopics_client_example_test.go index 38999dbd9532..c2218b01181a 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/namespacetopics_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/namespacetopics_client_example_test.go @@ -18,7 +18,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/NamespaceTopics_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/NamespaceTopics_Get.json func ExampleNamespaceTopicsClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -49,7 +49,7 @@ func ExampleNamespaceTopicsClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/NamespaceTopics_CreateOrUpdate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/NamespaceTopics_CreateOrUpdate.json func ExampleNamespaceTopicsClient_BeginCreateOrUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -90,7 +90,7 @@ func ExampleNamespaceTopicsClient_BeginCreateOrUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/NamespaceTopics_Delete.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/NamespaceTopics_Delete.json func ExampleNamespaceTopicsClient_BeginDelete() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -111,7 +111,7 @@ func ExampleNamespaceTopicsClient_BeginDelete() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/NamespaceTopics_Update.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/NamespaceTopics_Update.json func ExampleNamespaceTopicsClient_BeginUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -150,7 +150,7 @@ func ExampleNamespaceTopicsClient_BeginUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/NamespaceTopics_ListByNamespace.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/NamespaceTopics_ListByNamespace.json func ExampleNamespaceTopicsClient_NewListByNamespacePager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -202,7 +202,7 @@ func ExampleNamespaceTopicsClient_NewListByNamespacePager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/NamespaceTopics_ListSharedAccessKeys.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/NamespaceTopics_ListSharedAccessKeys.json func ExampleNamespaceTopicsClient_ListSharedAccessKeys() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -226,7 +226,7 @@ func ExampleNamespaceTopicsClient_ListSharedAccessKeys() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/NamespaceTopics_RegenerateKey.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/NamespaceTopics_RegenerateKey.json func ExampleNamespaceTopicsClient_BeginRegenerateKey() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/networksecurityperimeterconfigurations_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/networksecurityperimeterconfigurations_client.go index 995527b3e110..5e11dc2784eb 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/networksecurityperimeterconfigurations_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/networksecurityperimeterconfigurations_client.go @@ -47,7 +47,7 @@ func NewNetworkSecurityPerimeterConfigurationsClient(subscriptionID string, cred // Get - Get a specific network security perimeter configuration with a topic or domain. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - resourceType - The type of the resource. This can be either \'topics\', or \'domains\'. // - resourceName - The name of the resource (namely, either, the topic name or domain name). @@ -109,7 +109,7 @@ func (client *NetworkSecurityPerimeterConfigurationsClient) getCreateRequest(ctx return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -126,7 +126,7 @@ func (client *NetworkSecurityPerimeterConfigurationsClient) getHandleResponse(re // NewListPager - Get all network security perimeter configurations associated with a topic or domain. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - resourceType - The type of the resource. This can be either \'topics\' or \'domains\'. // - resourceName - The name of the resource (namely, either, the topic name or domain name). @@ -180,7 +180,7 @@ func (client *NetworkSecurityPerimeterConfigurationsClient) listCreateRequest(ct return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -199,7 +199,7 @@ func (client *NetworkSecurityPerimeterConfigurationsClient) listHandleResponse(r // with a topic or domain. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - resourceType - The type of the resource. This can be either \'topics\' or \'domains\'. // - resourceName - The name of the resource (namely, either, the topic name or domain name). @@ -229,7 +229,7 @@ func (client *NetworkSecurityPerimeterConfigurationsClient) BeginReconcile(ctx c // with a topic or domain. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *NetworkSecurityPerimeterConfigurationsClient) reconcile(ctx context.Context, resourceGroupName string, resourceType NetworkSecurityPerimeterResourceType, resourceName string, perimeterGUID string, associationName string, options *NetworkSecurityPerimeterConfigurationsClientBeginReconcileOptions) (*http.Response, error) { var err error const operationName = "NetworkSecurityPerimeterConfigurationsClient.BeginReconcile" @@ -283,7 +283,7 @@ func (client *NetworkSecurityPerimeterConfigurationsClient) reconcileCreateReque return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/networksecurityperimeterconfigurations_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/networksecurityperimeterconfigurations_client_example_test.go index 4583487b6a7b..ff527a12064c 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/networksecurityperimeterconfigurations_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/networksecurityperimeterconfigurations_client_example_test.go @@ -17,7 +17,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/NetworkSecurityPerimeterConfigurations_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/NetworkSecurityPerimeterConfigurations_Get.json func ExampleNetworkSecurityPerimeterConfigurationsClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -70,7 +70,7 @@ func ExampleNetworkSecurityPerimeterConfigurationsClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/NetworkSecurityPerimeterConfigurations_Reconcile.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/NetworkSecurityPerimeterConfigurations_Reconcile.json func ExampleNetworkSecurityPerimeterConfigurationsClient_BeginReconcile() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -127,7 +127,7 @@ func ExampleNetworkSecurityPerimeterConfigurationsClient_BeginReconcile() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/NetworkSecurityPerimeterConfigurations_List.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/NetworkSecurityPerimeterConfigurations_List.json func ExampleNetworkSecurityPerimeterConfigurationsClient_NewListPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/operations_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/operations_client.go index b5e7b583c88b..c75b541158dc 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/operations_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/operations_client.go @@ -39,7 +39,7 @@ func NewOperationsClient(credential azcore.TokenCredential, options *arm.ClientO // NewListPager - List the available operations supported by the Microsoft.EventGrid resource provider. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - options - OperationsClientListOptions contains the optional parameters for the OperationsClient.NewListPager method. func (client *OperationsClient) NewListPager(options *OperationsClientListOptions) *runtime.Pager[OperationsClientListResponse] { return runtime.NewPager(runtime.PagingHandler[OperationsClientListResponse]{ @@ -73,7 +73,7 @@ func (client *OperationsClient) listCreateRequest(ctx context.Context, options * return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/operations_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/operations_client_example_test.go index 68ce9a2d8bdc..1d71bd3e67a2 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/operations_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/operations_client_example_test.go @@ -17,7 +17,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Operations_List.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Operations_List.json func ExampleOperationsClient_NewListPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/options.go b/sdk/resourcemanager/eventgrid/armeventgrid/options.go index c769a02fb5f8..dbbef5bcc78c 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/options.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/options.go @@ -588,6 +588,12 @@ type NamespaceTopicEventSubscriptionsClientGetDeliveryAttributesOptions struct { // placeholder for future optional parameters } +// NamespaceTopicEventSubscriptionsClientGetFullURLOptions contains the optional parameters for the NamespaceTopicEventSubscriptionsClient.GetFullURL +// method. +type NamespaceTopicEventSubscriptionsClientGetFullURLOptions struct { + // placeholder for future optional parameters +} + // NamespaceTopicEventSubscriptionsClientGetOptions contains the optional parameters for the NamespaceTopicEventSubscriptionsClient.Get // method. type NamespaceTopicEventSubscriptionsClientGetOptions struct { @@ -689,6 +695,13 @@ type NamespacesClientBeginUpdateOptions struct { ResumeToken string } +// NamespacesClientBeginValidateCustomDomainOwnershipOptions contains the optional parameters for the NamespacesClient.BeginValidateCustomDomainOwnership +// method. +type NamespacesClientBeginValidateCustomDomainOwnershipOptions struct { + // Resumes the LRO from the provided token. + ResumeToken string +} + // NamespacesClientGetOptions contains the optional parameters for the NamespacesClient.Get method. type NamespacesClientGetOptions struct { // placeholder for future optional parameters diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/partnerconfigurations_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/partnerconfigurations_client.go index 0cdfefec62e5..c6e1e21af4c1 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/partnerconfigurations_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/partnerconfigurations_client.go @@ -48,7 +48,7 @@ func NewPartnerConfigurationsClient(subscriptionID string, credential azcore.Tok // AuthorizePartner - Authorize a single partner either by partner registration immutable Id or by partner name. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerInfo - The information of the partner to be authorized. // - options - PartnerConfigurationsClientAuthorizePartnerOptions contains the optional parameters for the PartnerConfigurationsClient.AuthorizePartner @@ -91,7 +91,7 @@ func (client *PartnerConfigurationsClient) authorizePartnerCreateRequest(ctx con return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, partnerInfo); err != nil { @@ -112,7 +112,7 @@ func (client *PartnerConfigurationsClient) authorizePartnerHandleResponse(resp * // BeginCreateOrUpdate - Synchronously creates or updates a partner configuration with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerConfigurationInfo - Partner configuration information. // - options - PartnerConfigurationsClientBeginCreateOrUpdateOptions contains the optional parameters for the PartnerConfigurationsClient.BeginCreateOrUpdate @@ -137,7 +137,7 @@ func (client *PartnerConfigurationsClient) BeginCreateOrUpdate(ctx context.Conte // CreateOrUpdate - Synchronously creates or updates a partner configuration with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *PartnerConfigurationsClient) createOrUpdate(ctx context.Context, resourceGroupName string, partnerConfigurationInfo PartnerConfiguration, options *PartnerConfigurationsClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "PartnerConfigurationsClient.BeginCreateOrUpdate" @@ -175,7 +175,7 @@ func (client *PartnerConfigurationsClient) createOrUpdateCreateRequest(ctx conte return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, partnerConfigurationInfo); err != nil { @@ -187,7 +187,7 @@ func (client *PartnerConfigurationsClient) createOrUpdateCreateRequest(ctx conte // BeginDelete - Delete existing partner configuration. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - options - PartnerConfigurationsClientBeginDeleteOptions contains the optional parameters for the PartnerConfigurationsClient.BeginDelete // method. @@ -211,7 +211,7 @@ func (client *PartnerConfigurationsClient) BeginDelete(ctx context.Context, reso // Delete - Delete existing partner configuration. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *PartnerConfigurationsClient) deleteOperation(ctx context.Context, resourceGroupName string, options *PartnerConfigurationsClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "PartnerConfigurationsClient.BeginDelete" @@ -249,7 +249,7 @@ func (client *PartnerConfigurationsClient) deleteCreateRequest(ctx context.Conte return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() return req, nil } @@ -257,7 +257,7 @@ func (client *PartnerConfigurationsClient) deleteCreateRequest(ctx context.Conte // Get - Get properties of a partner configuration. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - options - PartnerConfigurationsClientGetOptions contains the optional parameters for the PartnerConfigurationsClient.Get // method. @@ -299,7 +299,7 @@ func (client *PartnerConfigurationsClient) getCreateRequest(ctx context.Context, return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -316,7 +316,7 @@ func (client *PartnerConfigurationsClient) getHandleResponse(resp *http.Response // NewListByResourceGroupPager - List all the partner configurations under a resource group. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - options - PartnerConfigurationsClientListByResourceGroupOptions contains the optional parameters for the PartnerConfigurationsClient.NewListByResourceGroupPager // method. @@ -360,7 +360,7 @@ func (client *PartnerConfigurationsClient) listByResourceGroupCreateRequest(ctx return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -377,7 +377,7 @@ func (client *PartnerConfigurationsClient) listByResourceGroupHandleResponse(res // NewListBySubscriptionPager - List all the partner configurations under an Azure subscription. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - options - PartnerConfigurationsClientListBySubscriptionOptions contains the optional parameters for the PartnerConfigurationsClient.NewListBySubscriptionPager // method. func (client *PartnerConfigurationsClient) NewListBySubscriptionPager(options *PartnerConfigurationsClientListBySubscriptionOptions) *runtime.Pager[PartnerConfigurationsClientListBySubscriptionResponse] { @@ -415,13 +415,13 @@ func (client *PartnerConfigurationsClient) listBySubscriptionCreateRequest(ctx c return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -439,7 +439,7 @@ func (client *PartnerConfigurationsClient) listBySubscriptionHandleResponse(resp // UnauthorizePartner - Unauthorize a single partner either by partner registration immutable Id or by partner name. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerInfo - The information of the partner to be unauthorized. // - options - PartnerConfigurationsClientUnauthorizePartnerOptions contains the optional parameters for the PartnerConfigurationsClient.UnauthorizePartner @@ -482,7 +482,7 @@ func (client *PartnerConfigurationsClient) unauthorizePartnerCreateRequest(ctx c return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, partnerInfo); err != nil { @@ -503,7 +503,7 @@ func (client *PartnerConfigurationsClient) unauthorizePartnerHandleResponse(resp // BeginUpdate - Synchronously updates a partner configuration with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerConfigurationUpdateParameters - Partner configuration update information. // - options - PartnerConfigurationsClientBeginUpdateOptions contains the optional parameters for the PartnerConfigurationsClient.BeginUpdate @@ -528,7 +528,7 @@ func (client *PartnerConfigurationsClient) BeginUpdate(ctx context.Context, reso // Update - Synchronously updates a partner configuration with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *PartnerConfigurationsClient) update(ctx context.Context, resourceGroupName string, partnerConfigurationUpdateParameters PartnerConfigurationUpdateParameters, options *PartnerConfigurationsClientBeginUpdateOptions) (*http.Response, error) { var err error const operationName = "PartnerConfigurationsClient.BeginUpdate" @@ -566,7 +566,7 @@ func (client *PartnerConfigurationsClient) updateCreateRequest(ctx context.Conte return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, partnerConfigurationUpdateParameters); err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/partnerconfigurations_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/partnerconfigurations_client_example_test.go index e768c5335de1..eb7ce3283b23 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/partnerconfigurations_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/partnerconfigurations_client_example_test.go @@ -20,7 +20,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerConfigurations_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerConfigurations_Get.json func ExamplePartnerConfigurationsClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -66,7 +66,7 @@ func ExamplePartnerConfigurationsClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerConfigurations_CreateOrUpdate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerConfigurations_CreateOrUpdate.json func ExamplePartnerConfigurationsClient_BeginCreateOrUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -133,7 +133,7 @@ func ExamplePartnerConfigurationsClient_BeginCreateOrUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerConfigurations_Delete.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerConfigurations_Delete.json func ExamplePartnerConfigurationsClient_BeginDelete() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -154,7 +154,7 @@ func ExamplePartnerConfigurationsClient_BeginDelete() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerConfigurations_Update.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerConfigurations_Update.json func ExamplePartnerConfigurationsClient_BeginUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -212,7 +212,7 @@ func ExamplePartnerConfigurationsClient_BeginUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerConfigurations_ListByResourceGroup.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerConfigurations_ListByResourceGroup.json func ExamplePartnerConfigurationsClient_NewListByResourceGroupPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -266,7 +266,7 @@ func ExamplePartnerConfigurationsClient_NewListByResourceGroupPager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerConfigurations_ListBySubscription.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerConfigurations_ListBySubscription.json func ExamplePartnerConfigurationsClient_NewListBySubscriptionPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -322,7 +322,7 @@ func ExamplePartnerConfigurationsClient_NewListBySubscriptionPager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerConfigurations_AuthorizePartner.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerConfigurations_AuthorizePartner.json func ExamplePartnerConfigurationsClient_AuthorizePartner() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -372,7 +372,7 @@ func ExamplePartnerConfigurationsClient_AuthorizePartner() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerConfigurations_UnauthorizePartner.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerConfigurations_UnauthorizePartner.json func ExamplePartnerConfigurationsClient_UnauthorizePartner() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/partnerdestinations_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/partnerdestinations_client.go index ab1514e664a2..ea13946b59c2 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/partnerdestinations_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/partnerdestinations_client.go @@ -48,7 +48,7 @@ func NewPartnerDestinationsClient(subscriptionID string, credential azcore.Token // Activate - Activate a newly created partner destination. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerDestinationName - Name of the partner destination. // - options - PartnerDestinationsClientActivateOptions contains the optional parameters for the PartnerDestinationsClient.Activate @@ -95,7 +95,7 @@ func (client *PartnerDestinationsClient) activateCreateRequest(ctx context.Conte return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -113,7 +113,7 @@ func (client *PartnerDestinationsClient) activateHandleResponse(resp *http.Respo // BeginCreateOrUpdate - Asynchronously creates a new partner destination with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerDestinationName - Name of the partner destination. // - partnerDestination - Partner destination create information. @@ -140,7 +140,7 @@ func (client *PartnerDestinationsClient) BeginCreateOrUpdate(ctx context.Context // CreateOrUpdate - Asynchronously creates a new partner destination with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *PartnerDestinationsClient) createOrUpdate(ctx context.Context, resourceGroupName string, partnerDestinationName string, partnerDestination PartnerDestination, options *PartnerDestinationsClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "PartnerDestinationsClient.BeginCreateOrUpdate" @@ -182,7 +182,7 @@ func (client *PartnerDestinationsClient) createOrUpdateCreateRequest(ctx context return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, partnerDestination); err != nil { @@ -194,7 +194,7 @@ func (client *PartnerDestinationsClient) createOrUpdateCreateRequest(ctx context // BeginDelete - Delete existing partner destination. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerDestinationName - Name of the partner destination. // - options - PartnerDestinationsClientBeginDeleteOptions contains the optional parameters for the PartnerDestinationsClient.BeginDelete @@ -220,7 +220,7 @@ func (client *PartnerDestinationsClient) BeginDelete(ctx context.Context, resour // Delete - Delete existing partner destination. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *PartnerDestinationsClient) deleteOperation(ctx context.Context, resourceGroupName string, partnerDestinationName string, options *PartnerDestinationsClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "PartnerDestinationsClient.BeginDelete" @@ -262,7 +262,7 @@ func (client *PartnerDestinationsClient) deleteCreateRequest(ctx context.Context return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -271,7 +271,7 @@ func (client *PartnerDestinationsClient) deleteCreateRequest(ctx context.Context // Get - Get properties of a partner destination. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerDestinationName - Name of the partner destination. // - options - PartnerDestinationsClientGetOptions contains the optional parameters for the PartnerDestinationsClient.Get method. @@ -317,7 +317,7 @@ func (client *PartnerDestinationsClient) getCreateRequest(ctx context.Context, r return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -334,7 +334,7 @@ func (client *PartnerDestinationsClient) getHandleResponse(resp *http.Response) // NewListByResourceGroupPager - List all the partner destinations under a resource group. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - options - PartnerDestinationsClientListByResourceGroupOptions contains the optional parameters for the PartnerDestinationsClient.NewListByResourceGroupPager // method. @@ -377,13 +377,13 @@ func (client *PartnerDestinationsClient) listByResourceGroupCreateRequest(ctx co return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -400,7 +400,7 @@ func (client *PartnerDestinationsClient) listByResourceGroupHandleResponse(resp // NewListBySubscriptionPager - List all the partner destinations under an Azure subscription. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - options - PartnerDestinationsClientListBySubscriptionOptions contains the optional parameters for the PartnerDestinationsClient.NewListBySubscriptionPager // method. func (client *PartnerDestinationsClient) NewListBySubscriptionPager(options *PartnerDestinationsClientListBySubscriptionOptions) *runtime.Pager[PartnerDestinationsClientListBySubscriptionResponse] { @@ -438,13 +438,13 @@ func (client *PartnerDestinationsClient) listBySubscriptionCreateRequest(ctx con return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -462,7 +462,7 @@ func (client *PartnerDestinationsClient) listBySubscriptionHandleResponse(resp * // BeginUpdate - Asynchronously updates a partner destination with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerDestinationName - Name of the partner destination. // - partnerDestinationUpdateParameters - Partner destination update information. @@ -489,7 +489,7 @@ func (client *PartnerDestinationsClient) BeginUpdate(ctx context.Context, resour // Update - Asynchronously updates a partner destination with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *PartnerDestinationsClient) update(ctx context.Context, resourceGroupName string, partnerDestinationName string, partnerDestinationUpdateParameters PartnerDestinationUpdateParameters, options *PartnerDestinationsClientBeginUpdateOptions) (*http.Response, error) { var err error const operationName = "PartnerDestinationsClient.BeginUpdate" @@ -531,7 +531,7 @@ func (client *PartnerDestinationsClient) updateCreateRequest(ctx context.Context return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, partnerDestinationUpdateParameters); err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/partnerdestinations_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/partnerdestinations_client_example_test.go index 6374928efb11..95d703766832 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/partnerdestinations_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/partnerdestinations_client_example_test.go @@ -20,7 +20,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerDestinations_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerDestinations_Get.json func ExamplePartnerDestinationsClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -54,7 +54,7 @@ func ExamplePartnerDestinationsClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerDestinations_CreateOrUpdate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerDestinations_CreateOrUpdate.json func ExamplePartnerDestinationsClient_BeginCreateOrUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -106,7 +106,7 @@ func ExamplePartnerDestinationsClient_BeginCreateOrUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerDestinations_Delete.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerDestinations_Delete.json func ExamplePartnerDestinationsClient_BeginDelete() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -127,7 +127,7 @@ func ExamplePartnerDestinationsClient_BeginDelete() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerDestinations_Update.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerDestinations_Update.json func ExamplePartnerDestinationsClient_BeginUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -174,7 +174,7 @@ func ExamplePartnerDestinationsClient_BeginUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerDestinations_ListBySubscription.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerDestinations_ListBySubscription.json func ExamplePartnerDestinationsClient_NewListBySubscriptionPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -218,7 +218,7 @@ func ExamplePartnerDestinationsClient_NewListBySubscriptionPager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerDestinations_ListByResourceGroup.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerDestinations_ListByResourceGroup.json func ExamplePartnerDestinationsClient_NewListByResourceGroupPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -262,7 +262,7 @@ func ExamplePartnerDestinationsClient_NewListByResourceGroupPager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerDestinations_Activate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerDestinations_Activate.json func ExamplePartnerDestinationsClient_Activate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/partnernamespaces_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/partnernamespaces_client.go index ec27f37ca52d..f07e87759d78 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/partnernamespaces_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/partnernamespaces_client.go @@ -48,7 +48,7 @@ func NewPartnerNamespacesClient(subscriptionID string, credential azcore.TokenCr // BeginCreateOrUpdate - Asynchronously creates a new partner namespace with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerNamespaceName - Name of the partner namespace. // - partnerNamespaceInfo - PartnerNamespace information. @@ -74,7 +74,7 @@ func (client *PartnerNamespacesClient) BeginCreateOrUpdate(ctx context.Context, // CreateOrUpdate - Asynchronously creates a new partner namespace with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *PartnerNamespacesClient) createOrUpdate(ctx context.Context, resourceGroupName string, partnerNamespaceName string, partnerNamespaceInfo PartnerNamespace, options *PartnerNamespacesClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "PartnerNamespacesClient.BeginCreateOrUpdate" @@ -116,7 +116,7 @@ func (client *PartnerNamespacesClient) createOrUpdateCreateRequest(ctx context.C return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, partnerNamespaceInfo); err != nil { @@ -128,7 +128,7 @@ func (client *PartnerNamespacesClient) createOrUpdateCreateRequest(ctx context.C // BeginDelete - Delete existing partner namespace. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerNamespaceName - Name of the partner namespace. // - options - PartnerNamespacesClientBeginDeleteOptions contains the optional parameters for the PartnerNamespacesClient.BeginDelete @@ -153,7 +153,7 @@ func (client *PartnerNamespacesClient) BeginDelete(ctx context.Context, resource // Delete - Delete existing partner namespace. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *PartnerNamespacesClient) deleteOperation(ctx context.Context, resourceGroupName string, partnerNamespaceName string, options *PartnerNamespacesClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "PartnerNamespacesClient.BeginDelete" @@ -195,7 +195,7 @@ func (client *PartnerNamespacesClient) deleteCreateRequest(ctx context.Context, return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -204,7 +204,7 @@ func (client *PartnerNamespacesClient) deleteCreateRequest(ctx context.Context, // Get - Get properties of a partner namespace. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerNamespaceName - Name of the partner namespace. // - options - PartnerNamespacesClientGetOptions contains the optional parameters for the PartnerNamespacesClient.Get method. @@ -250,7 +250,7 @@ func (client *PartnerNamespacesClient) getCreateRequest(ctx context.Context, res return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -267,7 +267,7 @@ func (client *PartnerNamespacesClient) getHandleResponse(resp *http.Response) (P // NewListByResourceGroupPager - List all the partner namespaces under a resource group. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - options - PartnerNamespacesClientListByResourceGroupOptions contains the optional parameters for the PartnerNamespacesClient.NewListByResourceGroupPager // method. @@ -310,13 +310,13 @@ func (client *PartnerNamespacesClient) listByResourceGroupCreateRequest(ctx cont return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -333,7 +333,7 @@ func (client *PartnerNamespacesClient) listByResourceGroupHandleResponse(resp *h // NewListBySubscriptionPager - List all the partner namespaces under an Azure subscription. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - options - PartnerNamespacesClientListBySubscriptionOptions contains the optional parameters for the PartnerNamespacesClient.NewListBySubscriptionPager // method. func (client *PartnerNamespacesClient) NewListBySubscriptionPager(options *PartnerNamespacesClientListBySubscriptionOptions) *runtime.Pager[PartnerNamespacesClientListBySubscriptionResponse] { @@ -371,13 +371,13 @@ func (client *PartnerNamespacesClient) listBySubscriptionCreateRequest(ctx conte return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -395,7 +395,7 @@ func (client *PartnerNamespacesClient) listBySubscriptionHandleResponse(resp *ht // ListSharedAccessKeys - List the two keys used to publish to a partner namespace. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerNamespaceName - Name of the partner namespace. // - options - PartnerNamespacesClientListSharedAccessKeysOptions contains the optional parameters for the PartnerNamespacesClient.ListSharedAccessKeys @@ -442,7 +442,7 @@ func (client *PartnerNamespacesClient) listSharedAccessKeysCreateRequest(ctx con return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -460,7 +460,7 @@ func (client *PartnerNamespacesClient) listSharedAccessKeysHandleResponse(resp * // RegenerateKey - Regenerate a shared access key for a partner namespace. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerNamespaceName - Name of the partner namespace. // - regenerateKeyRequest - Request body to regenerate key. @@ -508,7 +508,7 @@ func (client *PartnerNamespacesClient) regenerateKeyCreateRequest(ctx context.Co return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, regenerateKeyRequest); err != nil { @@ -529,7 +529,7 @@ func (client *PartnerNamespacesClient) regenerateKeyHandleResponse(resp *http.Re // BeginUpdate - Asynchronously updates a partner namespace with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerNamespaceName - Name of the partner namespace. // - partnerNamespaceUpdateParameters - Partner namespace update information. @@ -555,7 +555,7 @@ func (client *PartnerNamespacesClient) BeginUpdate(ctx context.Context, resource // Update - Asynchronously updates a partner namespace with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *PartnerNamespacesClient) update(ctx context.Context, resourceGroupName string, partnerNamespaceName string, partnerNamespaceUpdateParameters PartnerNamespaceUpdateParameters, options *PartnerNamespacesClientBeginUpdateOptions) (*http.Response, error) { var err error const operationName = "PartnerNamespacesClient.BeginUpdate" @@ -597,7 +597,7 @@ func (client *PartnerNamespacesClient) updateCreateRequest(ctx context.Context, return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, partnerNamespaceUpdateParameters); err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/partnernamespaces_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/partnernamespaces_client_example_test.go index 01799f6693aa..c71f9dcac2b2 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/partnernamespaces_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/partnernamespaces_client_example_test.go @@ -18,7 +18,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerNamespaces_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerNamespaces_Get.json func ExamplePartnerNamespacesClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -54,7 +54,7 @@ func ExamplePartnerNamespacesClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerNamespaces_CreateOrUpdate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerNamespaces_CreateOrUpdate.json func ExamplePartnerNamespacesClient_BeginCreateOrUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -84,7 +84,7 @@ func ExamplePartnerNamespacesClient_BeginCreateOrUpdate() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerNamespaces_Delete.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerNamespaces_Delete.json func ExamplePartnerNamespacesClient_BeginDelete() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -105,7 +105,7 @@ func ExamplePartnerNamespacesClient_BeginDelete() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerNamespaces_Update.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerNamespaces_Update.json func ExamplePartnerNamespacesClient_BeginUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -130,7 +130,7 @@ func ExamplePartnerNamespacesClient_BeginUpdate() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerNamespaces_ListBySubscription.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerNamespaces_ListBySubscription.json func ExamplePartnerNamespacesClient_NewListBySubscriptionPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -176,7 +176,7 @@ func ExamplePartnerNamespacesClient_NewListBySubscriptionPager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerNamespaces_ListByResourceGroup.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerNamespaces_ListByResourceGroup.json func ExamplePartnerNamespacesClient_NewListByResourceGroupPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -222,7 +222,7 @@ func ExamplePartnerNamespacesClient_NewListByResourceGroupPager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerNamespaces_ListSharedAccessKeys.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerNamespaces_ListSharedAccessKeys.json func ExamplePartnerNamespacesClient_ListSharedAccessKeys() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -246,7 +246,7 @@ func ExamplePartnerNamespacesClient_ListSharedAccessKeys() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerNamespaces_RegenerateKey.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerNamespaces_RegenerateKey.json func ExamplePartnerNamespacesClient_RegenerateKey() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/partnerregistrations_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/partnerregistrations_client.go index 348f1eb57e40..2271fc829e8d 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/partnerregistrations_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/partnerregistrations_client.go @@ -48,7 +48,7 @@ func NewPartnerRegistrationsClient(subscriptionID string, credential azcore.Toke // BeginCreateOrUpdate - Creates a new partner registration with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerRegistrationName - Name of the partner registration. // - partnerRegistrationInfo - PartnerRegistration information. @@ -74,7 +74,7 @@ func (client *PartnerRegistrationsClient) BeginCreateOrUpdate(ctx context.Contex // CreateOrUpdate - Creates a new partner registration with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *PartnerRegistrationsClient) createOrUpdate(ctx context.Context, resourceGroupName string, partnerRegistrationName string, partnerRegistrationInfo PartnerRegistration, options *PartnerRegistrationsClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "PartnerRegistrationsClient.BeginCreateOrUpdate" @@ -116,7 +116,7 @@ func (client *PartnerRegistrationsClient) createOrUpdateCreateRequest(ctx contex return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, partnerRegistrationInfo); err != nil { @@ -128,7 +128,7 @@ func (client *PartnerRegistrationsClient) createOrUpdateCreateRequest(ctx contex // BeginDelete - Deletes a partner registration with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerRegistrationName - Name of the partner registration. // - options - PartnerRegistrationsClientBeginDeleteOptions contains the optional parameters for the PartnerRegistrationsClient.BeginDelete @@ -153,7 +153,7 @@ func (client *PartnerRegistrationsClient) BeginDelete(ctx context.Context, resou // Delete - Deletes a partner registration with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *PartnerRegistrationsClient) deleteOperation(ctx context.Context, resourceGroupName string, partnerRegistrationName string, options *PartnerRegistrationsClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "PartnerRegistrationsClient.BeginDelete" @@ -195,7 +195,7 @@ func (client *PartnerRegistrationsClient) deleteCreateRequest(ctx context.Contex return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() return req, nil } @@ -203,7 +203,7 @@ func (client *PartnerRegistrationsClient) deleteCreateRequest(ctx context.Contex // Get - Gets a partner registration with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerRegistrationName - Name of the partner registration. // - options - PartnerRegistrationsClientGetOptions contains the optional parameters for the PartnerRegistrationsClient.Get @@ -250,7 +250,7 @@ func (client *PartnerRegistrationsClient) getCreateRequest(ctx context.Context, return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -267,7 +267,7 @@ func (client *PartnerRegistrationsClient) getHandleResponse(resp *http.Response) // NewListByResourceGroupPager - List all the partner registrations under a resource group. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - options - PartnerRegistrationsClientListByResourceGroupOptions contains the optional parameters for the PartnerRegistrationsClient.NewListByResourceGroupPager // method. @@ -310,13 +310,13 @@ func (client *PartnerRegistrationsClient) listByResourceGroupCreateRequest(ctx c return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -333,7 +333,7 @@ func (client *PartnerRegistrationsClient) listByResourceGroupHandleResponse(resp // NewListBySubscriptionPager - List all the partner registrations under an Azure subscription. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - options - PartnerRegistrationsClientListBySubscriptionOptions contains the optional parameters for the PartnerRegistrationsClient.NewListBySubscriptionPager // method. func (client *PartnerRegistrationsClient) NewListBySubscriptionPager(options *PartnerRegistrationsClientListBySubscriptionOptions) *runtime.Pager[PartnerRegistrationsClientListBySubscriptionResponse] { @@ -371,13 +371,13 @@ func (client *PartnerRegistrationsClient) listBySubscriptionCreateRequest(ctx co return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -395,7 +395,7 @@ func (client *PartnerRegistrationsClient) listBySubscriptionHandleResponse(resp // BeginUpdate - Updates a partner registration with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerRegistrationName - Name of the partner registration. // - partnerRegistrationUpdateParameters - Partner registration update information. @@ -421,7 +421,7 @@ func (client *PartnerRegistrationsClient) BeginUpdate(ctx context.Context, resou // Update - Updates a partner registration with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *PartnerRegistrationsClient) update(ctx context.Context, resourceGroupName string, partnerRegistrationName string, partnerRegistrationUpdateParameters PartnerRegistrationUpdateParameters, options *PartnerRegistrationsClientBeginUpdateOptions) (*http.Response, error) { var err error const operationName = "PartnerRegistrationsClient.BeginUpdate" @@ -463,7 +463,7 @@ func (client *PartnerRegistrationsClient) updateCreateRequest(ctx context.Contex return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, partnerRegistrationUpdateParameters); err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/partnerregistrations_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/partnerregistrations_client_example_test.go index bdb089c62f94..d59fa908aba8 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/partnerregistrations_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/partnerregistrations_client_example_test.go @@ -18,7 +18,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerRegistrations_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerRegistrations_Get.json func ExamplePartnerRegistrationsClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -53,7 +53,7 @@ func ExamplePartnerRegistrationsClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerRegistrations_CreateOrUpdate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerRegistrations_CreateOrUpdate.json func ExamplePartnerRegistrationsClient_BeginCreateOrUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -99,7 +99,7 @@ func ExamplePartnerRegistrationsClient_BeginCreateOrUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerRegistrations_Delete.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerRegistrations_Delete.json func ExamplePartnerRegistrationsClient_BeginDelete() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -120,7 +120,7 @@ func ExamplePartnerRegistrationsClient_BeginDelete() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerRegistrations_Update.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerRegistrations_Update.json func ExamplePartnerRegistrationsClient_BeginUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -145,7 +145,7 @@ func ExamplePartnerRegistrationsClient_BeginUpdate() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerRegistrations_ListBySubscription.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerRegistrations_ListBySubscription.json func ExamplePartnerRegistrationsClient_NewListBySubscriptionPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -190,7 +190,7 @@ func ExamplePartnerRegistrationsClient_NewListBySubscriptionPager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerRegistrations_ListByResourceGroup.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerRegistrations_ListByResourceGroup.json func ExamplePartnerRegistrationsClient_NewListByResourceGroupPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/partnertopiceventsubscriptions_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/partnertopiceventsubscriptions_client.go index e5312448b465..2fe2a30844df 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/partnertopiceventsubscriptions_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/partnertopiceventsubscriptions_client.go @@ -49,10 +49,10 @@ func NewPartnerTopicEventSubscriptionsClient(subscriptionID string, credential a // Existing event subscriptions will be updated with this API. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerTopicName - Name of the partner topic. -// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 100 +// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 64 // characters in length and use alphanumeric letters only. // - eventSubscriptionInfo - Event subscription properties containing the destination and filter information. // - options - PartnerTopicEventSubscriptionsClientBeginCreateOrUpdateOptions contains the optional parameters for the PartnerTopicEventSubscriptionsClient.BeginCreateOrUpdate @@ -78,7 +78,7 @@ func (client *PartnerTopicEventSubscriptionsClient) BeginCreateOrUpdate(ctx cont // Existing event subscriptions will be updated with this API. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *PartnerTopicEventSubscriptionsClient) createOrUpdate(ctx context.Context, resourceGroupName string, partnerTopicName string, eventSubscriptionName string, eventSubscriptionInfo EventSubscription, options *PartnerTopicEventSubscriptionsClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "PartnerTopicEventSubscriptionsClient.BeginCreateOrUpdate" @@ -124,7 +124,7 @@ func (client *PartnerTopicEventSubscriptionsClient) createOrUpdateCreateRequest( return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, eventSubscriptionInfo); err != nil { @@ -136,11 +136,10 @@ func (client *PartnerTopicEventSubscriptionsClient) createOrUpdateCreateRequest( // BeginDelete - Delete an existing event subscription of a partner topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerTopicName - Name of the partner topic. -// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 100 -// characters in length and use alphanumeric letters only. +// - eventSubscriptionName - Name of the event subscription to be deleted. // - options - PartnerTopicEventSubscriptionsClientBeginDeleteOptions contains the optional parameters for the PartnerTopicEventSubscriptionsClient.BeginDelete // method. func (client *PartnerTopicEventSubscriptionsClient) BeginDelete(ctx context.Context, resourceGroupName string, partnerTopicName string, eventSubscriptionName string, options *PartnerTopicEventSubscriptionsClientBeginDeleteOptions) (*runtime.Poller[PartnerTopicEventSubscriptionsClientDeleteResponse], error) { @@ -163,7 +162,7 @@ func (client *PartnerTopicEventSubscriptionsClient) BeginDelete(ctx context.Cont // Delete - Delete an existing event subscription of a partner topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *PartnerTopicEventSubscriptionsClient) deleteOperation(ctx context.Context, resourceGroupName string, partnerTopicName string, eventSubscriptionName string, options *PartnerTopicEventSubscriptionsClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "PartnerTopicEventSubscriptionsClient.BeginDelete" @@ -209,7 +208,7 @@ func (client *PartnerTopicEventSubscriptionsClient) deleteCreateRequest(ctx cont return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() return req, nil } @@ -217,11 +216,10 @@ func (client *PartnerTopicEventSubscriptionsClient) deleteCreateRequest(ctx cont // Get - Get properties of an event subscription of a partner topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerTopicName - Name of the partner topic. -// - eventSubscriptionName - Name of the event subscription to be found. Event subscription names must be between 3 and 100 -// characters in length and use alphanumeric letters only. +// - eventSubscriptionName - Name of the event subscription to be found. // - options - PartnerTopicEventSubscriptionsClientGetOptions contains the optional parameters for the PartnerTopicEventSubscriptionsClient.Get // method. func (client *PartnerTopicEventSubscriptionsClient) Get(ctx context.Context, resourceGroupName string, partnerTopicName string, eventSubscriptionName string, options *PartnerTopicEventSubscriptionsClientGetOptions) (PartnerTopicEventSubscriptionsClientGetResponse, error) { @@ -270,7 +268,7 @@ func (client *PartnerTopicEventSubscriptionsClient) getCreateRequest(ctx context return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -288,11 +286,10 @@ func (client *PartnerTopicEventSubscriptionsClient) getHandleResponse(resp *http // GetDeliveryAttributes - Get all delivery attributes for an event subscription of a partner topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerTopicName - Name of the partner topic. -// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 100 -// characters in length and use alphanumeric letters only. +// - eventSubscriptionName - Name of the event subscription. // - options - PartnerTopicEventSubscriptionsClientGetDeliveryAttributesOptions contains the optional parameters for the PartnerTopicEventSubscriptionsClient.GetDeliveryAttributes // method. func (client *PartnerTopicEventSubscriptionsClient) GetDeliveryAttributes(ctx context.Context, resourceGroupName string, partnerTopicName string, eventSubscriptionName string, options *PartnerTopicEventSubscriptionsClientGetDeliveryAttributesOptions) (PartnerTopicEventSubscriptionsClientGetDeliveryAttributesResponse, error) { @@ -341,7 +338,7 @@ func (client *PartnerTopicEventSubscriptionsClient) getDeliveryAttributesCreateR return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -359,11 +356,10 @@ func (client *PartnerTopicEventSubscriptionsClient) getDeliveryAttributesHandleR // GetFullURL - Get the full endpoint URL for an event subscription of a partner topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerTopicName - Name of the partner topic. -// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 100 -// characters in length and use alphanumeric letters only. +// - eventSubscriptionName - Name of the event subscription. // - options - PartnerTopicEventSubscriptionsClientGetFullURLOptions contains the optional parameters for the PartnerTopicEventSubscriptionsClient.GetFullURL // method. func (client *PartnerTopicEventSubscriptionsClient) GetFullURL(ctx context.Context, resourceGroupName string, partnerTopicName string, eventSubscriptionName string, options *PartnerTopicEventSubscriptionsClientGetFullURLOptions) (PartnerTopicEventSubscriptionsClientGetFullURLResponse, error) { @@ -412,7 +408,7 @@ func (client *PartnerTopicEventSubscriptionsClient) getFullURLCreateRequest(ctx return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -429,7 +425,7 @@ func (client *PartnerTopicEventSubscriptionsClient) getFullURLHandleResponse(res // NewListByPartnerTopicPager - List event subscriptions that belong to a specific partner topic. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerTopicName - Name of the partner topic. // - options - PartnerTopicEventSubscriptionsClientListByPartnerTopicOptions contains the optional parameters for the PartnerTopicEventSubscriptionsClient.NewListByPartnerTopicPager @@ -477,13 +473,13 @@ func (client *PartnerTopicEventSubscriptionsClient) listByPartnerTopicCreateRequ return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -501,11 +497,10 @@ func (client *PartnerTopicEventSubscriptionsClient) listByPartnerTopicHandleResp // BeginUpdate - Update an existing event subscription of a partner topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerTopicName - Name of the partner topic. -// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 100 -// characters in length and use alphanumeric letters only. +// - eventSubscriptionName - Name of the event subscription to be updated. // - eventSubscriptionUpdateParameters - Updated event subscription information. // - options - PartnerTopicEventSubscriptionsClientBeginUpdateOptions contains the optional parameters for the PartnerTopicEventSubscriptionsClient.BeginUpdate // method. @@ -529,7 +524,7 @@ func (client *PartnerTopicEventSubscriptionsClient) BeginUpdate(ctx context.Cont // Update - Update an existing event subscription of a partner topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *PartnerTopicEventSubscriptionsClient) update(ctx context.Context, resourceGroupName string, partnerTopicName string, eventSubscriptionName string, eventSubscriptionUpdateParameters EventSubscriptionUpdateParameters, options *PartnerTopicEventSubscriptionsClientBeginUpdateOptions) (*http.Response, error) { var err error const operationName = "PartnerTopicEventSubscriptionsClient.BeginUpdate" @@ -575,7 +570,7 @@ func (client *PartnerTopicEventSubscriptionsClient) updateCreateRequest(ctx cont return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, eventSubscriptionUpdateParameters); err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/partnertopiceventsubscriptions_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/partnertopiceventsubscriptions_client_example_test.go index 0764ac2c8641..3d2322219dc1 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/partnertopiceventsubscriptions_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/partnertopiceventsubscriptions_client_example_test.go @@ -18,7 +18,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerTopicEventSubscriptions_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerTopicEventSubscriptions_Get.json func ExamplePartnerTopicEventSubscriptionsClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -70,7 +70,7 @@ func ExamplePartnerTopicEventSubscriptionsClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerTopicEventSubscriptions_CreateOrUpdate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerTopicEventSubscriptions_CreateOrUpdate.json func ExamplePartnerTopicEventSubscriptionsClient_BeginCreateOrUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -133,7 +133,7 @@ func ExamplePartnerTopicEventSubscriptionsClient_BeginCreateOrUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerTopicEventSubscriptions_Delete.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerTopicEventSubscriptions_Delete.json func ExamplePartnerTopicEventSubscriptionsClient_BeginDelete() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -154,7 +154,7 @@ func ExamplePartnerTopicEventSubscriptionsClient_BeginDelete() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerTopicEventSubscriptions_Update.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerTopicEventSubscriptions_Update.json func ExamplePartnerTopicEventSubscriptionsClient_BeginUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -190,7 +190,7 @@ func ExamplePartnerTopicEventSubscriptionsClient_BeginUpdate() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerTopicEventSubscriptions_GetFullUrl.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerTopicEventSubscriptions_GetFullUrl.json func ExamplePartnerTopicEventSubscriptionsClient_GetFullURL() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -213,7 +213,7 @@ func ExamplePartnerTopicEventSubscriptionsClient_GetFullURL() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerTopicEventSubscriptions_ListByPartnerTopic.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerTopicEventSubscriptions_ListByPartnerTopic.json func ExamplePartnerTopicEventSubscriptionsClient_NewListByPartnerTopicPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -302,7 +302,7 @@ func ExamplePartnerTopicEventSubscriptionsClient_NewListByPartnerTopicPager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerTopicEventSubscriptions_GetDeliveryAttributes.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerTopicEventSubscriptions_GetDeliveryAttributes.json func ExamplePartnerTopicEventSubscriptionsClient_GetDeliveryAttributes() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/partnertopics_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/partnertopics_client.go index 3ea185eed6f7..0f9102d9bac1 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/partnertopics_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/partnertopics_client.go @@ -48,7 +48,7 @@ func NewPartnerTopicsClient(subscriptionID string, credential azcore.TokenCreden // Activate - Activate a newly created partner topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerTopicName - Name of the partner topic. // - options - PartnerTopicsClientActivateOptions contains the optional parameters for the PartnerTopicsClient.Activate method. @@ -94,7 +94,7 @@ func (client *PartnerTopicsClient) activateCreateRequest(ctx context.Context, re return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -112,7 +112,7 @@ func (client *PartnerTopicsClient) activateHandleResponse(resp *http.Response) ( // CreateOrUpdate - Asynchronously creates a new partner topic with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerTopicName - Name of the partner topic. // - partnerTopicInfo - Partner Topic information. @@ -160,7 +160,7 @@ func (client *PartnerTopicsClient) createOrUpdateCreateRequest(ctx context.Conte return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, partnerTopicInfo); err != nil { @@ -181,7 +181,7 @@ func (client *PartnerTopicsClient) createOrUpdateHandleResponse(resp *http.Respo // Deactivate - Deactivate specific partner topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerTopicName - Name of the partner topic. // - options - PartnerTopicsClientDeactivateOptions contains the optional parameters for the PartnerTopicsClient.Deactivate @@ -228,7 +228,7 @@ func (client *PartnerTopicsClient) deactivateCreateRequest(ctx context.Context, return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -246,7 +246,7 @@ func (client *PartnerTopicsClient) deactivateHandleResponse(resp *http.Response) // BeginDelete - Delete existing partner topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerTopicName - Name of the partner topic. // - options - PartnerTopicsClientBeginDeleteOptions contains the optional parameters for the PartnerTopicsClient.BeginDelete @@ -271,7 +271,7 @@ func (client *PartnerTopicsClient) BeginDelete(ctx context.Context, resourceGrou // Delete - Delete existing partner topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *PartnerTopicsClient) deleteOperation(ctx context.Context, resourceGroupName string, partnerTopicName string, options *PartnerTopicsClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "PartnerTopicsClient.BeginDelete" @@ -313,7 +313,7 @@ func (client *PartnerTopicsClient) deleteCreateRequest(ctx context.Context, reso return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() return req, nil } @@ -321,7 +321,7 @@ func (client *PartnerTopicsClient) deleteCreateRequest(ctx context.Context, reso // Get - Get properties of a partner topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerTopicName - Name of the partner topic. // - options - PartnerTopicsClientGetOptions contains the optional parameters for the PartnerTopicsClient.Get method. @@ -367,7 +367,7 @@ func (client *PartnerTopicsClient) getCreateRequest(ctx context.Context, resourc return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -384,7 +384,7 @@ func (client *PartnerTopicsClient) getHandleResponse(resp *http.Response) (Partn // NewListByResourceGroupPager - List all the partner topics under a resource group. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - options - PartnerTopicsClientListByResourceGroupOptions contains the optional parameters for the PartnerTopicsClient.NewListByResourceGroupPager // method. @@ -427,13 +427,13 @@ func (client *PartnerTopicsClient) listByResourceGroupCreateRequest(ctx context. return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -450,7 +450,7 @@ func (client *PartnerTopicsClient) listByResourceGroupHandleResponse(resp *http. // NewListBySubscriptionPager - List all the partner topics under an Azure subscription. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - options - PartnerTopicsClientListBySubscriptionOptions contains the optional parameters for the PartnerTopicsClient.NewListBySubscriptionPager // method. func (client *PartnerTopicsClient) NewListBySubscriptionPager(options *PartnerTopicsClientListBySubscriptionOptions) *runtime.Pager[PartnerTopicsClientListBySubscriptionResponse] { @@ -488,13 +488,13 @@ func (client *PartnerTopicsClient) listBySubscriptionCreateRequest(ctx context.C return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -512,7 +512,7 @@ func (client *PartnerTopicsClient) listBySubscriptionHandleResponse(resp *http.R // Update - Asynchronously updates a partner topic with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - partnerTopicName - Name of the partner topic. // - partnerTopicUpdateParameters - PartnerTopic update information. @@ -559,7 +559,7 @@ func (client *PartnerTopicsClient) updateCreateRequest(ctx context.Context, reso return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, partnerTopicUpdateParameters); err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/partnertopics_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/partnertopics_client_example_test.go index e7de068ba862..f8607d0ad05b 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/partnertopics_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/partnertopics_client_example_test.go @@ -20,7 +20,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerTopics_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerTopics_Get.json func ExamplePartnerTopicsClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -51,7 +51,7 @@ func ExamplePartnerTopicsClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerTopics_CreateOrUpdate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerTopics_CreateOrUpdate.json func ExamplePartnerTopicsClient_CreateOrUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -99,7 +99,7 @@ func ExamplePartnerTopicsClient_CreateOrUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerTopics_Delete.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerTopics_Delete.json func ExamplePartnerTopicsClient_BeginDelete() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -120,7 +120,7 @@ func ExamplePartnerTopicsClient_BeginDelete() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerTopics_Update.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerTopics_Update.json func ExamplePartnerTopicsClient_Update() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -142,7 +142,7 @@ func ExamplePartnerTopicsClient_Update() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerTopics_ListBySubscription.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerTopics_ListBySubscription.json func ExamplePartnerTopicsClient_NewListBySubscriptionPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -183,7 +183,7 @@ func ExamplePartnerTopicsClient_NewListBySubscriptionPager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerTopics_ListByResourceGroup.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerTopics_ListByResourceGroup.json func ExamplePartnerTopicsClient_NewListByResourceGroupPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -224,7 +224,7 @@ func ExamplePartnerTopicsClient_NewListByResourceGroupPager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerTopics_Activate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerTopics_Activate.json func ExamplePartnerTopicsClient_Activate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -255,7 +255,7 @@ func ExamplePartnerTopicsClient_Activate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PartnerTopics_Deactivate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PartnerTopics_Deactivate.json func ExamplePartnerTopicsClient_Deactivate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/permissionbindings_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/permissionbindings_client.go index f5cab90bd2f5..f35740cc64b3 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/permissionbindings_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/permissionbindings_client.go @@ -48,7 +48,7 @@ func NewPermissionBindingsClient(subscriptionID string, credential azcore.TokenC // BeginCreateOrUpdate - Create or update a permission binding with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - permissionBindingName - The permission binding name. @@ -76,7 +76,7 @@ func (client *PermissionBindingsClient) BeginCreateOrUpdate(ctx context.Context, // CreateOrUpdate - Create or update a permission binding with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *PermissionBindingsClient) createOrUpdate(ctx context.Context, resourceGroupName string, namespaceName string, permissionBindingName string, permissionBindingInfo PermissionBinding, options *PermissionBindingsClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "PermissionBindingsClient.BeginCreateOrUpdate" @@ -122,7 +122,7 @@ func (client *PermissionBindingsClient) createOrUpdateCreateRequest(ctx context. return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, permissionBindingInfo); err != nil { @@ -134,7 +134,7 @@ func (client *PermissionBindingsClient) createOrUpdateCreateRequest(ctx context. // BeginDelete - Delete an existing permission binding. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - permissionBindingName - Name of the permission binding. @@ -161,7 +161,7 @@ func (client *PermissionBindingsClient) BeginDelete(ctx context.Context, resourc // Delete - Delete an existing permission binding. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *PermissionBindingsClient) deleteOperation(ctx context.Context, resourceGroupName string, namespaceName string, permissionBindingName string, options *PermissionBindingsClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "PermissionBindingsClient.BeginDelete" @@ -207,7 +207,7 @@ func (client *PermissionBindingsClient) deleteCreateRequest(ctx context.Context, return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -216,7 +216,7 @@ func (client *PermissionBindingsClient) deleteCreateRequest(ctx context.Context, // Get - Get properties of a permission binding. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - permissionBindingName - Name of the permission binding. @@ -267,7 +267,7 @@ func (client *PermissionBindingsClient) getCreateRequest(ctx context.Context, re return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -284,7 +284,7 @@ func (client *PermissionBindingsClient) getHandleResponse(resp *http.Response) ( // NewListByNamespacePager - Get all the permission bindings under a namespace. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - options - PermissionBindingsClientListByNamespaceOptions contains the optional parameters for the PermissionBindingsClient.NewListByNamespacePager @@ -332,13 +332,13 @@ func (client *PermissionBindingsClient) listByNamespaceCreateRequest(ctx context return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/permissionbindings_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/permissionbindings_client_example_test.go index 498310905f1d..d25cfb277842 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/permissionbindings_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/permissionbindings_client_example_test.go @@ -18,7 +18,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PermissionBindings_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PermissionBindings_Get.json func ExamplePermissionBindingsClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -49,7 +49,7 @@ func ExamplePermissionBindingsClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PermissionBindings_CreateOrUpdate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PermissionBindings_CreateOrUpdate.json func ExamplePermissionBindingsClient_BeginCreateOrUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -90,7 +90,7 @@ func ExamplePermissionBindingsClient_BeginCreateOrUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PermissionBindings_Delete.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PermissionBindings_Delete.json func ExamplePermissionBindingsClient_BeginDelete() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -111,7 +111,7 @@ func ExamplePermissionBindingsClient_BeginDelete() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PermissionBindings_ListByNamespace.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PermissionBindings_ListByNamespace.json func ExamplePermissionBindingsClient_NewListByNamespacePager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/polymorphic_helpers.go b/sdk/resourcemanager/eventgrid/armeventgrid/polymorphic_helpers.go index 80ef54dace53..7ea65e656494 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/polymorphic_helpers.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/polymorphic_helpers.go @@ -11,7 +11,7 @@ package armeventgrid import "encoding/json" func unmarshalAdvancedFilterClassification(rawMsg json.RawMessage) (AdvancedFilterClassification, error) { - if rawMsg == nil { + if rawMsg == nil || string(rawMsg) == "null" { return nil, nil } var m map[string]any @@ -68,7 +68,7 @@ func unmarshalAdvancedFilterClassification(rawMsg json.RawMessage) (AdvancedFilt } func unmarshalAdvancedFilterClassificationArray(rawMsg json.RawMessage) ([]AdvancedFilterClassification, error) { - if rawMsg == nil { + if rawMsg == nil || string(rawMsg) == "null" { return nil, nil } var rawMessages []json.RawMessage @@ -87,7 +87,7 @@ func unmarshalAdvancedFilterClassificationArray(rawMsg json.RawMessage) ([]Advan } func unmarshalDeadLetterDestinationClassification(rawMsg json.RawMessage) (DeadLetterDestinationClassification, error) { - if rawMsg == nil { + if rawMsg == nil || string(rawMsg) == "null" { return nil, nil } var m map[string]any @@ -108,7 +108,7 @@ func unmarshalDeadLetterDestinationClassification(rawMsg json.RawMessage) (DeadL } func unmarshalDeliveryAttributeMappingClassification(rawMsg json.RawMessage) (DeliveryAttributeMappingClassification, error) { - if rawMsg == nil { + if rawMsg == nil || string(rawMsg) == "null" { return nil, nil } var m map[string]any @@ -131,7 +131,7 @@ func unmarshalDeliveryAttributeMappingClassification(rawMsg json.RawMessage) (De } func unmarshalDeliveryAttributeMappingClassificationArray(rawMsg json.RawMessage) ([]DeliveryAttributeMappingClassification, error) { - if rawMsg == nil { + if rawMsg == nil || string(rawMsg) == "null" { return nil, nil } var rawMessages []json.RawMessage @@ -150,7 +150,7 @@ func unmarshalDeliveryAttributeMappingClassificationArray(rawMsg json.RawMessage } func unmarshalEventSubscriptionDestinationClassification(rawMsg json.RawMessage) (EventSubscriptionDestinationClassification, error) { - if rawMsg == nil { + if rawMsg == nil || string(rawMsg) == "null" { return nil, nil } var m map[string]any @@ -189,7 +189,7 @@ func unmarshalEventSubscriptionDestinationClassification(rawMsg json.RawMessage) } func unmarshalFilterClassification(rawMsg json.RawMessage) (FilterClassification, error) { - if rawMsg == nil { + if rawMsg == nil || string(rawMsg) == "null" { return nil, nil } var m map[string]any @@ -246,7 +246,7 @@ func unmarshalFilterClassification(rawMsg json.RawMessage) (FilterClassification } func unmarshalFilterClassificationArray(rawMsg json.RawMessage) ([]FilterClassification, error) { - if rawMsg == nil { + if rawMsg == nil || string(rawMsg) == "null" { return nil, nil } var rawMessages []json.RawMessage @@ -265,7 +265,7 @@ func unmarshalFilterClassificationArray(rawMsg json.RawMessage) ([]FilterClassif } func unmarshalInputSchemaMappingClassification(rawMsg json.RawMessage) (InputSchemaMappingClassification, error) { - if rawMsg == nil { + if rawMsg == nil || string(rawMsg) == "null" { return nil, nil } var m map[string]any @@ -286,7 +286,7 @@ func unmarshalInputSchemaMappingClassification(rawMsg json.RawMessage) (InputSch } func unmarshalPartnerClientAuthenticationClassification(rawMsg json.RawMessage) (PartnerClientAuthenticationClassification, error) { - if rawMsg == nil { + if rawMsg == nil || string(rawMsg) == "null" { return nil, nil } var m map[string]any @@ -307,7 +307,7 @@ func unmarshalPartnerClientAuthenticationClassification(rawMsg json.RawMessage) } func unmarshalPartnerDestinationInfoClassification(rawMsg json.RawMessage) (PartnerDestinationInfoClassification, error) { - if rawMsg == nil { + if rawMsg == nil || string(rawMsg) == "null" { return nil, nil } var m map[string]any @@ -328,7 +328,7 @@ func unmarshalPartnerDestinationInfoClassification(rawMsg json.RawMessage) (Part } func unmarshalPartnerUpdateDestinationInfoClassification(rawMsg json.RawMessage) (PartnerUpdateDestinationInfoClassification, error) { - if rawMsg == nil { + if rawMsg == nil || string(rawMsg) == "null" { return nil, nil } var m map[string]any @@ -349,7 +349,7 @@ func unmarshalPartnerUpdateDestinationInfoClassification(rawMsg json.RawMessage) } func unmarshalStaticRoutingEnrichmentClassification(rawMsg json.RawMessage) (StaticRoutingEnrichmentClassification, error) { - if rawMsg == nil { + if rawMsg == nil || string(rawMsg) == "null" { return nil, nil } var m map[string]any @@ -370,7 +370,7 @@ func unmarshalStaticRoutingEnrichmentClassification(rawMsg json.RawMessage) (Sta } func unmarshalStaticRoutingEnrichmentClassificationArray(rawMsg json.RawMessage) ([]StaticRoutingEnrichmentClassification, error) { - if rawMsg == nil { + if rawMsg == nil || string(rawMsg) == "null" { return nil, nil } var rawMessages []json.RawMessage diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/privateendpointconnections_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/privateendpointconnections_client.go index c25f2b19925f..07989b2b1096 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/privateendpointconnections_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/privateendpointconnections_client.go @@ -48,7 +48,7 @@ func NewPrivateEndpointConnectionsClient(subscriptionID string, credential azcor // BeginDelete - Delete a specific private endpoint connection under a topic, domain, or partner namespace or namespace. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - parentType - The type of the parent resource. This can be either \'topics\', \'domains\', or \'partnerNamespaces\' or \'namespaces\'. // - parentName - The name of the parent resource (namely, either, the topic name, domain name, or partner namespace name or @@ -76,7 +76,7 @@ func (client *PrivateEndpointConnectionsClient) BeginDelete(ctx context.Context, // Delete - Delete a specific private endpoint connection under a topic, domain, or partner namespace or namespace. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *PrivateEndpointConnectionsClient) deleteOperation(ctx context.Context, resourceGroupName string, parentType PrivateEndpointConnectionsParentType, parentName string, privateEndpointConnectionName string, options *PrivateEndpointConnectionsClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "PrivateEndpointConnectionsClient.BeginDelete" @@ -126,7 +126,7 @@ func (client *PrivateEndpointConnectionsClient) deleteCreateRequest(ctx context. return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() return req, nil } @@ -134,7 +134,7 @@ func (client *PrivateEndpointConnectionsClient) deleteCreateRequest(ctx context. // Get - Get a specific private endpoint connection under a topic, domain, or partner namespace or namespace. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - parentType - The type of the parent resource. This can be either \'topics\', \'domains\', or \'partnerNamespaces\' or \'namespaces\'. // - parentName - The name of the parent resource (namely, either, the topic name, domain name, or partner namespace name or @@ -192,7 +192,7 @@ func (client *PrivateEndpointConnectionsClient) getCreateRequest(ctx context.Con return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -209,7 +209,7 @@ func (client *PrivateEndpointConnectionsClient) getHandleResponse(resp *http.Res // NewListByResourcePager - Get all private endpoint connections under a topic, domain, or partner namespace or namespace. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - parentType - The type of the parent resource. This can be either \'topics\', \'domains\', or \'partnerNamespaces\' or \'namespaces\'. // - parentName - The name of the parent resource (namely, either, the topic name, domain name, or partner namespace name or @@ -263,13 +263,13 @@ func (client *PrivateEndpointConnectionsClient) listByResourceCreateRequest(ctx return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -287,7 +287,7 @@ func (client *PrivateEndpointConnectionsClient) listByResourceHandleResponse(res // BeginUpdate - Update a specific private endpoint connection under a topic, domain or partner namespace. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - parentType - The type of the parent resource. This can be either \'topics\', \'domains\', or \'partnerNamespaces\' or \'namespaces\'. // - parentName - The name of the parent resource (namely, either, the topic name, domain name, or partner namespace name or @@ -316,7 +316,7 @@ func (client *PrivateEndpointConnectionsClient) BeginUpdate(ctx context.Context, // Update - Update a specific private endpoint connection under a topic, domain or partner namespace. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *PrivateEndpointConnectionsClient) update(ctx context.Context, resourceGroupName string, parentType PrivateEndpointConnectionsParentType, parentName string, privateEndpointConnectionName string, privateEndpointConnection PrivateEndpointConnection, options *PrivateEndpointConnectionsClientBeginUpdateOptions) (*http.Response, error) { var err error const operationName = "PrivateEndpointConnectionsClient.BeginUpdate" @@ -366,7 +366,7 @@ func (client *PrivateEndpointConnectionsClient) updateCreateRequest(ctx context. return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, privateEndpointConnection); err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/privateendpointconnections_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/privateendpointconnections_client_example_test.go index 86f6df98223e..591b2f654820 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/privateendpointconnections_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/privateendpointconnections_client_example_test.go @@ -18,7 +18,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PrivateEndpointConnections_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PrivateEndpointConnections_Get.json func ExamplePrivateEndpointConnectionsClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -56,7 +56,7 @@ func ExamplePrivateEndpointConnectionsClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PrivateEndpointConnections_Update.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PrivateEndpointConnections_Update.json func ExamplePrivateEndpointConnectionsClient_BeginUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -106,7 +106,7 @@ func ExamplePrivateEndpointConnectionsClient_BeginUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PrivateEndpointConnections_Delete.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PrivateEndpointConnections_Delete.json func ExamplePrivateEndpointConnectionsClient_BeginDelete() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -127,7 +127,7 @@ func ExamplePrivateEndpointConnectionsClient_BeginDelete() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PrivateEndpointConnections_ListByResource.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PrivateEndpointConnections_ListByResource.json func ExamplePrivateEndpointConnectionsClient_NewListByResourcePager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/privatelinkresources_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/privatelinkresources_client.go index 47ab7d7af2db..ac7b1e068640 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/privatelinkresources_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/privatelinkresources_client.go @@ -48,7 +48,7 @@ func NewPrivateLinkResourcesClient(subscriptionID string, credential azcore.Toke // Get - Get properties of a private link resource. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - parentType - The type of the parent resource. This can be either \'topics\', \'domains\', or \'partnerNamespaces\' or \'namespaces\'. // - parentName - The name of the parent resource (namely, either, the topic name, domain name, or partner namespace name or @@ -106,7 +106,7 @@ func (client *PrivateLinkResourcesClient) getCreateRequest(ctx context.Context, return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -123,7 +123,7 @@ func (client *PrivateLinkResourcesClient) getHandleResponse(resp *http.Response) // NewListByResourcePager - List all the private link resources under a topic, domain, or partner namespace or namespace. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - parentType - The type of the parent resource. This can be either \'topics\', \'domains\', or \'partnerNamespaces\' or \'namespaces\'. // - parentName - The name of the parent resource (namely, either, the topic name, domain name, or partner namespace or namespace @@ -177,13 +177,13 @@ func (client *PrivateLinkResourcesClient) listByResourceCreateRequest(ctx contex return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/privatelinkresources_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/privatelinkresources_client_example_test.go index 66c69b2cc041..adc4c14d52f4 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/privatelinkresources_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/privatelinkresources_client_example_test.go @@ -17,7 +17,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PrivateLinkResources_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PrivateLinkResources_Get.json func ExamplePrivateLinkResourcesClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -50,7 +50,7 @@ func ExamplePrivateLinkResourcesClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/PrivateLinkResources_ListByResource.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/PrivateLinkResources_ListByResource.json func ExamplePrivateLinkResourcesClient_NewListByResourcePager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/response_types.go b/sdk/resourcemanager/eventgrid/armeventgrid/responses.go similarity index 97% rename from sdk/resourcemanager/eventgrid/armeventgrid/response_types.go rename to sdk/resourcemanager/eventgrid/armeventgrid/responses.go index 2c5ffba283e0..02b18acd59ba 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/response_types.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/responses.go @@ -44,7 +44,7 @@ type ChannelsClientDeleteResponse struct { // ChannelsClientGetFullURLResponse contains the response from method ChannelsClient.GetFullURL. type ChannelsClientGetFullURLResponse struct { - // Full endpoint url of an event subscription + // Full endpoint URL of an event subscription EventSubscriptionFullURL } @@ -130,7 +130,7 @@ type DomainEventSubscriptionsClientGetDeliveryAttributesResponse struct { // DomainEventSubscriptionsClientGetFullURLResponse contains the response from method DomainEventSubscriptionsClient.GetFullURL. type DomainEventSubscriptionsClientGetFullURLResponse struct { - // Full endpoint url of an event subscription + // Full endpoint URL of an event subscription EventSubscriptionFullURL } @@ -171,7 +171,7 @@ type DomainTopicEventSubscriptionsClientGetDeliveryAttributesResponse struct { // DomainTopicEventSubscriptionsClientGetFullURLResponse contains the response from method DomainTopicEventSubscriptionsClient.GetFullURL. type DomainTopicEventSubscriptionsClientGetFullURLResponse struct { - // Full endpoint url of an event subscription + // Full endpoint URL of an event subscription EventSubscriptionFullURL } @@ -282,7 +282,7 @@ type EventSubscriptionsClientGetDeliveryAttributesResponse struct { // EventSubscriptionsClientGetFullURLResponse contains the response from method EventSubscriptionsClient.GetFullURL. type EventSubscriptionsClientGetFullURLResponse struct { - // Full endpoint url of an event subscription + // Full endpoint URL of an event subscription EventSubscriptionFullURL } @@ -381,6 +381,12 @@ type NamespaceTopicEventSubscriptionsClientGetDeliveryAttributesResponse struct DeliveryAttributeListResult } +// NamespaceTopicEventSubscriptionsClientGetFullURLResponse contains the response from method NamespaceTopicEventSubscriptionsClient.GetFullURL. +type NamespaceTopicEventSubscriptionsClientGetFullURLResponse struct { + // Full endpoint URL of an event subscription + SubscriptionFullURL +} + // NamespaceTopicEventSubscriptionsClientGetResponse contains the response from method NamespaceTopicEventSubscriptionsClient.Get. type NamespaceTopicEventSubscriptionsClientGetResponse struct { // Event Subscription. @@ -487,6 +493,12 @@ type NamespacesClientUpdateResponse struct { Namespace } +// NamespacesClientValidateCustomDomainOwnershipResponse contains the response from method NamespacesClient.BeginValidateCustomDomainOwnership. +type NamespacesClientValidateCustomDomainOwnershipResponse struct { + // Namespace custom domain ownership validation result. + CustomDomainOwnershipValidationResult +} + // NetworkSecurityPerimeterConfigurationsClientGetResponse contains the response from method NetworkSecurityPerimeterConfigurationsClient.Get. type NetworkSecurityPerimeterConfigurationsClientGetResponse struct { // Network security perimeter configuration. @@ -700,7 +712,7 @@ type PartnerTopicEventSubscriptionsClientGetDeliveryAttributesResponse struct { // PartnerTopicEventSubscriptionsClientGetFullURLResponse contains the response from method PartnerTopicEventSubscriptionsClient.GetFullURL. type PartnerTopicEventSubscriptionsClientGetFullURLResponse struct { - // Full endpoint url of an event subscription + // Full endpoint URL of an event subscription EventSubscriptionFullURL } @@ -844,7 +856,7 @@ type SystemTopicEventSubscriptionsClientGetDeliveryAttributesResponse struct { // SystemTopicEventSubscriptionsClientGetFullURLResponse contains the response from method SystemTopicEventSubscriptionsClient.GetFullURL. type SystemTopicEventSubscriptionsClientGetFullURLResponse struct { - // Full endpoint url of an event subscription + // Full endpoint URL of an event subscription EventSubscriptionFullURL } @@ -920,7 +932,7 @@ type TopicEventSubscriptionsClientGetDeliveryAttributesResponse struct { // TopicEventSubscriptionsClientGetFullURLResponse contains the response from method TopicEventSubscriptionsClient.GetFullURL. type TopicEventSubscriptionsClientGetFullURLResponse struct { - // Full endpoint url of an event subscription + // Full endpoint URL of an event subscription EventSubscriptionFullURL } diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/systemtopiceventsubscriptions_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/systemtopiceventsubscriptions_client.go index d840cfd6aa11..e657d413647f 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/systemtopiceventsubscriptions_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/systemtopiceventsubscriptions_client.go @@ -49,10 +49,10 @@ func NewSystemTopicEventSubscriptionsClient(subscriptionID string, credential az // subscriptions will be updated with this API. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - systemTopicName - Name of the system topic. -// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 100 +// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 64 // characters in length and use alphanumeric letters only. // - eventSubscriptionInfo - Event subscription properties containing the destination and filter information. // - options - SystemTopicEventSubscriptionsClientBeginCreateOrUpdateOptions contains the optional parameters for the SystemTopicEventSubscriptionsClient.BeginCreateOrUpdate @@ -78,7 +78,7 @@ func (client *SystemTopicEventSubscriptionsClient) BeginCreateOrUpdate(ctx conte // subscriptions will be updated with this API. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *SystemTopicEventSubscriptionsClient) createOrUpdate(ctx context.Context, resourceGroupName string, systemTopicName string, eventSubscriptionName string, eventSubscriptionInfo EventSubscription, options *SystemTopicEventSubscriptionsClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "SystemTopicEventSubscriptionsClient.BeginCreateOrUpdate" @@ -124,7 +124,7 @@ func (client *SystemTopicEventSubscriptionsClient) createOrUpdateCreateRequest(c return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, eventSubscriptionInfo); err != nil { @@ -136,11 +136,10 @@ func (client *SystemTopicEventSubscriptionsClient) createOrUpdateCreateRequest(c // BeginDelete - Delete an existing event subscription of a system topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - systemTopicName - Name of the system topic. -// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 100 -// characters in length and use alphanumeric letters only. +// - eventSubscriptionName - Name of the event subscription to be deleted. // - options - SystemTopicEventSubscriptionsClientBeginDeleteOptions contains the optional parameters for the SystemTopicEventSubscriptionsClient.BeginDelete // method. func (client *SystemTopicEventSubscriptionsClient) BeginDelete(ctx context.Context, resourceGroupName string, systemTopicName string, eventSubscriptionName string, options *SystemTopicEventSubscriptionsClientBeginDeleteOptions) (*runtime.Poller[SystemTopicEventSubscriptionsClientDeleteResponse], error) { @@ -163,7 +162,7 @@ func (client *SystemTopicEventSubscriptionsClient) BeginDelete(ctx context.Conte // Delete - Delete an existing event subscription of a system topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *SystemTopicEventSubscriptionsClient) deleteOperation(ctx context.Context, resourceGroupName string, systemTopicName string, eventSubscriptionName string, options *SystemTopicEventSubscriptionsClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "SystemTopicEventSubscriptionsClient.BeginDelete" @@ -209,7 +208,7 @@ func (client *SystemTopicEventSubscriptionsClient) deleteCreateRequest(ctx conte return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() return req, nil } @@ -217,11 +216,10 @@ func (client *SystemTopicEventSubscriptionsClient) deleteCreateRequest(ctx conte // Get - Get an event subscription. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - systemTopicName - Name of the system topic. -// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 100 -// characters in length and use alphanumeric letters only. +// - eventSubscriptionName - Name of the event subscription to be found. // - options - SystemTopicEventSubscriptionsClientGetOptions contains the optional parameters for the SystemTopicEventSubscriptionsClient.Get // method. func (client *SystemTopicEventSubscriptionsClient) Get(ctx context.Context, resourceGroupName string, systemTopicName string, eventSubscriptionName string, options *SystemTopicEventSubscriptionsClientGetOptions) (SystemTopicEventSubscriptionsClientGetResponse, error) { @@ -270,7 +268,7 @@ func (client *SystemTopicEventSubscriptionsClient) getCreateRequest(ctx context. return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -288,11 +286,10 @@ func (client *SystemTopicEventSubscriptionsClient) getHandleResponse(resp *http. // GetDeliveryAttributes - Get all delivery attributes for an event subscription. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - systemTopicName - Name of the system topic. -// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 100 -// characters in length and use alphanumeric letters only. +// - eventSubscriptionName - Name of the event subscription. // - options - SystemTopicEventSubscriptionsClientGetDeliveryAttributesOptions contains the optional parameters for the SystemTopicEventSubscriptionsClient.GetDeliveryAttributes // method. func (client *SystemTopicEventSubscriptionsClient) GetDeliveryAttributes(ctx context.Context, resourceGroupName string, systemTopicName string, eventSubscriptionName string, options *SystemTopicEventSubscriptionsClientGetDeliveryAttributesOptions) (SystemTopicEventSubscriptionsClientGetDeliveryAttributesResponse, error) { @@ -341,7 +338,7 @@ func (client *SystemTopicEventSubscriptionsClient) getDeliveryAttributesCreateRe return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -359,11 +356,10 @@ func (client *SystemTopicEventSubscriptionsClient) getDeliveryAttributesHandleRe // GetFullURL - Get the full endpoint URL for an event subscription of a system topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - systemTopicName - Name of the system topic. -// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 100 -// characters in length and use alphanumeric letters only. +// - eventSubscriptionName - Name of the event subscription. // - options - SystemTopicEventSubscriptionsClientGetFullURLOptions contains the optional parameters for the SystemTopicEventSubscriptionsClient.GetFullURL // method. func (client *SystemTopicEventSubscriptionsClient) GetFullURL(ctx context.Context, resourceGroupName string, systemTopicName string, eventSubscriptionName string, options *SystemTopicEventSubscriptionsClientGetFullURLOptions) (SystemTopicEventSubscriptionsClientGetFullURLResponse, error) { @@ -412,7 +408,7 @@ func (client *SystemTopicEventSubscriptionsClient) getFullURLCreateRequest(ctx c return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -429,7 +425,7 @@ func (client *SystemTopicEventSubscriptionsClient) getFullURLHandleResponse(resp // NewListBySystemTopicPager - List event subscriptions that belong to a specific system topic. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - systemTopicName - Name of the system topic. // - options - SystemTopicEventSubscriptionsClientListBySystemTopicOptions contains the optional parameters for the SystemTopicEventSubscriptionsClient.NewListBySystemTopicPager @@ -477,13 +473,13 @@ func (client *SystemTopicEventSubscriptionsClient) listBySystemTopicCreateReques return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -501,11 +497,10 @@ func (client *SystemTopicEventSubscriptionsClient) listBySystemTopicHandleRespon // BeginUpdate - Update an existing event subscription of a system topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - systemTopicName - Name of the system topic. -// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 100 -// characters in length and use alphanumeric letters only. +// - eventSubscriptionName - Name of the event subscription to be updated. // - eventSubscriptionUpdateParameters - Updated event subscription information. // - options - SystemTopicEventSubscriptionsClientBeginUpdateOptions contains the optional parameters for the SystemTopicEventSubscriptionsClient.BeginUpdate // method. @@ -529,7 +524,7 @@ func (client *SystemTopicEventSubscriptionsClient) BeginUpdate(ctx context.Conte // Update - Update an existing event subscription of a system topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *SystemTopicEventSubscriptionsClient) update(ctx context.Context, resourceGroupName string, systemTopicName string, eventSubscriptionName string, eventSubscriptionUpdateParameters EventSubscriptionUpdateParameters, options *SystemTopicEventSubscriptionsClientBeginUpdateOptions) (*http.Response, error) { var err error const operationName = "SystemTopicEventSubscriptionsClient.BeginUpdate" @@ -575,7 +570,7 @@ func (client *SystemTopicEventSubscriptionsClient) updateCreateRequest(ctx conte return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, eventSubscriptionUpdateParameters); err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/systemtopiceventsubscriptions_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/systemtopiceventsubscriptions_client_example_test.go index 5681d4479de6..a2774eacb913 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/systemtopiceventsubscriptions_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/systemtopiceventsubscriptions_client_example_test.go @@ -18,7 +18,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/SystemTopicEventSubscriptions_GetDeliveryAttributes.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/SystemTopicEventSubscriptions_GetDeliveryAttributes.json func ExampleSystemTopicEventSubscriptionsClient_GetDeliveryAttributes() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -64,7 +64,7 @@ func ExampleSystemTopicEventSubscriptionsClient_GetDeliveryAttributes() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/SystemTopicEventSubscriptions_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/SystemTopicEventSubscriptions_Get.json func ExampleSystemTopicEventSubscriptionsClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -116,7 +116,7 @@ func ExampleSystemTopicEventSubscriptionsClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/SystemTopicEventSubscriptions_CreateOrUpdate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/SystemTopicEventSubscriptions_CreateOrUpdate.json func ExampleSystemTopicEventSubscriptionsClient_BeginCreateOrUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -151,7 +151,7 @@ func ExampleSystemTopicEventSubscriptionsClient_BeginCreateOrUpdate() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/SystemTopicEventSubscriptions_Delete.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/SystemTopicEventSubscriptions_Delete.json func ExampleSystemTopicEventSubscriptionsClient_BeginDelete() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -172,7 +172,7 @@ func ExampleSystemTopicEventSubscriptionsClient_BeginDelete() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/SystemTopicEventSubscriptions_Update.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/SystemTopicEventSubscriptions_Update.json func ExampleSystemTopicEventSubscriptionsClient_BeginUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -208,7 +208,7 @@ func ExampleSystemTopicEventSubscriptionsClient_BeginUpdate() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/SystemTopicEventSubscriptions_GetFullUrl.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/SystemTopicEventSubscriptions_GetFullUrl.json func ExampleSystemTopicEventSubscriptionsClient_GetFullURL() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -231,7 +231,7 @@ func ExampleSystemTopicEventSubscriptionsClient_GetFullURL() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/SystemTopicEventSubscriptions_ListBySystemTopic.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/SystemTopicEventSubscriptions_ListBySystemTopic.json func ExampleSystemTopicEventSubscriptionsClient_NewListBySystemTopicPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/systemtopics_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/systemtopics_client.go index d2a9a34fed86..1d49b94d057d 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/systemtopics_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/systemtopics_client.go @@ -48,7 +48,7 @@ func NewSystemTopicsClient(subscriptionID string, credential azcore.TokenCredent // BeginCreateOrUpdate - Asynchronously creates a new system topic with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - systemTopicName - Name of the system topic. // - systemTopicInfo - System Topic information. @@ -74,7 +74,7 @@ func (client *SystemTopicsClient) BeginCreateOrUpdate(ctx context.Context, resou // CreateOrUpdate - Asynchronously creates a new system topic with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *SystemTopicsClient) createOrUpdate(ctx context.Context, resourceGroupName string, systemTopicName string, systemTopicInfo SystemTopic, options *SystemTopicsClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "SystemTopicsClient.BeginCreateOrUpdate" @@ -116,7 +116,7 @@ func (client *SystemTopicsClient) createOrUpdateCreateRequest(ctx context.Contex return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, systemTopicInfo); err != nil { @@ -128,7 +128,7 @@ func (client *SystemTopicsClient) createOrUpdateCreateRequest(ctx context.Contex // BeginDelete - Delete existing system topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - systemTopicName - Name of the system topic. // - options - SystemTopicsClientBeginDeleteOptions contains the optional parameters for the SystemTopicsClient.BeginDelete @@ -153,7 +153,7 @@ func (client *SystemTopicsClient) BeginDelete(ctx context.Context, resourceGroup // Delete - Delete existing system topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *SystemTopicsClient) deleteOperation(ctx context.Context, resourceGroupName string, systemTopicName string, options *SystemTopicsClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "SystemTopicsClient.BeginDelete" @@ -195,7 +195,7 @@ func (client *SystemTopicsClient) deleteCreateRequest(ctx context.Context, resou return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() return req, nil } @@ -203,7 +203,7 @@ func (client *SystemTopicsClient) deleteCreateRequest(ctx context.Context, resou // Get - Get properties of a system topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - systemTopicName - Name of the system topic. // - options - SystemTopicsClientGetOptions contains the optional parameters for the SystemTopicsClient.Get method. @@ -249,7 +249,7 @@ func (client *SystemTopicsClient) getCreateRequest(ctx context.Context, resource return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -266,7 +266,7 @@ func (client *SystemTopicsClient) getHandleResponse(resp *http.Response) (System // NewListByResourceGroupPager - List all the system topics under a resource group. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - options - SystemTopicsClientListByResourceGroupOptions contains the optional parameters for the SystemTopicsClient.NewListByResourceGroupPager // method. @@ -309,13 +309,13 @@ func (client *SystemTopicsClient) listByResourceGroupCreateRequest(ctx context.C return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -332,7 +332,7 @@ func (client *SystemTopicsClient) listByResourceGroupHandleResponse(resp *http.R // NewListBySubscriptionPager - List all the system topics under an Azure subscription. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - options - SystemTopicsClientListBySubscriptionOptions contains the optional parameters for the SystemTopicsClient.NewListBySubscriptionPager // method. func (client *SystemTopicsClient) NewListBySubscriptionPager(options *SystemTopicsClientListBySubscriptionOptions) *runtime.Pager[SystemTopicsClientListBySubscriptionResponse] { @@ -370,13 +370,13 @@ func (client *SystemTopicsClient) listBySubscriptionCreateRequest(ctx context.Co return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -394,7 +394,7 @@ func (client *SystemTopicsClient) listBySubscriptionHandleResponse(resp *http.Re // BeginUpdate - Asynchronously updates a system topic with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - systemTopicName - Name of the system topic. // - systemTopicUpdateParameters - SystemTopic update information. @@ -420,7 +420,7 @@ func (client *SystemTopicsClient) BeginUpdate(ctx context.Context, resourceGroup // Update - Asynchronously updates a system topic with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *SystemTopicsClient) update(ctx context.Context, resourceGroupName string, systemTopicName string, systemTopicUpdateParameters SystemTopicUpdateParameters, options *SystemTopicsClientBeginUpdateOptions) (*http.Response, error) { var err error const operationName = "SystemTopicsClient.BeginUpdate" @@ -462,7 +462,7 @@ func (client *SystemTopicsClient) updateCreateRequest(ctx context.Context, resou return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, systemTopicUpdateParameters); err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/systemtopics_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/systemtopics_client_example_test.go index e1815bcdad73..6d8b43f43a05 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/systemtopics_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/systemtopics_client_example_test.go @@ -18,7 +18,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/SystemTopics_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/SystemTopics_Get.json func ExampleSystemTopicsClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -50,7 +50,7 @@ func ExampleSystemTopicsClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/SystemTopics_CreateOrUpdate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/SystemTopics_CreateOrUpdate.json func ExampleSystemTopicsClient_BeginCreateOrUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -96,7 +96,7 @@ func ExampleSystemTopicsClient_BeginCreateOrUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/SystemTopics_Delete.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/SystemTopics_Delete.json func ExampleSystemTopicsClient_BeginDelete() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -117,7 +117,7 @@ func ExampleSystemTopicsClient_BeginDelete() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/SystemTopics_Update.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/SystemTopics_Update.json func ExampleSystemTopicsClient_BeginUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -158,7 +158,7 @@ func ExampleSystemTopicsClient_BeginUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/SystemTopics_ListBySubscription.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/SystemTopics_ListBySubscription.json func ExampleSystemTopicsClient_NewListBySubscriptionPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -200,7 +200,7 @@ func ExampleSystemTopicsClient_NewListBySubscriptionPager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/SystemTopics_ListByResourceGroup.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/SystemTopics_ListByResourceGroup.json func ExampleSystemTopicsClient_NewListByResourceGroupPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/time_rfc3339.go b/sdk/resourcemanager/eventgrid/armeventgrid/time_rfc3339.go index 6a078860d343..2b68f07c9f11 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/time_rfc3339.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/time_rfc3339.go @@ -19,12 +19,16 @@ import ( ) // Azure reports time in UTC but it doesn't include the 'Z' time zone suffix in some cases. -var tzOffsetRegex = regexp.MustCompile(`(Z|z|\+|-)(\d+:\d+)*"*$`) +var tzOffsetRegex = regexp.MustCompile(`(?:Z|z|\+|-)(?:\d+:\d+)*"*$`) const ( - utcDateTimeJSON = `"2006-01-02T15:04:05.999999999"` - utcDateTime = "2006-01-02T15:04:05.999999999" - dateTimeJSON = `"` + time.RFC3339Nano + `"` + utcDateTime = "2006-01-02T15:04:05.999999999" + utcDateTimeJSON = `"` + utcDateTime + `"` + utcDateTimeNoT = "2006-01-02 15:04:05.999999999" + utcDateTimeJSONNoT = `"` + utcDateTimeNoT + `"` + dateTimeNoT = `2006-01-02 15:04:05.999999999Z07:00` + dateTimeJSON = `"` + time.RFC3339Nano + `"` + dateTimeJSONNoT = `"` + dateTimeNoT + `"` ) type dateTimeRFC3339 time.Time @@ -40,17 +44,33 @@ func (t dateTimeRFC3339) MarshalText() ([]byte, error) { } func (t *dateTimeRFC3339) UnmarshalJSON(data []byte) error { - layout := utcDateTimeJSON - if tzOffsetRegex.Match(data) { + tzOffset := tzOffsetRegex.Match(data) + hasT := strings.Contains(string(data), "T") || strings.Contains(string(data), "t") + var layout string + if tzOffset && hasT { layout = dateTimeJSON + } else if tzOffset { + layout = dateTimeJSONNoT + } else if hasT { + layout = utcDateTimeJSON + } else { + layout = utcDateTimeJSONNoT } return t.Parse(layout, string(data)) } func (t *dateTimeRFC3339) UnmarshalText(data []byte) error { - layout := utcDateTime - if tzOffsetRegex.Match(data) { + tzOffset := tzOffsetRegex.Match(data) + hasT := strings.Contains(string(data), "T") || strings.Contains(string(data), "t") + var layout string + if tzOffset && hasT { layout = time.RFC3339Nano + } else if tzOffset { + layout = dateTimeNoT + } else if hasT { + layout = utcDateTime + } else { + layout = utcDateTimeNoT } return t.Parse(layout, string(data)) } @@ -61,6 +81,10 @@ func (t *dateTimeRFC3339) Parse(layout, value string) error { return err } +func (t dateTimeRFC3339) String() string { + return time.Time(t).Format(time.RFC3339Nano) +} + func populateDateTimeRFC3339(m map[string]any, k string, t *time.Time) { if t == nil { return @@ -74,7 +98,7 @@ func populateDateTimeRFC3339(m map[string]any, k string, t *time.Time) { } func unpopulateDateTimeRFC3339(data json.RawMessage, fn string, t **time.Time) error { - if data == nil || strings.EqualFold(string(data), "null") { + if data == nil || string(data) == "null" { return nil } var aux dateTimeRFC3339 diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/topiceventsubscriptions_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/topiceventsubscriptions_client.go index 3513f3f65054..ca7d152afc81 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/topiceventsubscriptions_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/topiceventsubscriptions_client.go @@ -48,10 +48,10 @@ func NewTopicEventSubscriptionsClient(subscriptionID string, credential azcore.T // BeginCreateOrUpdate - Asynchronously creates a new event subscription or updates an existing event subscription. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - topicName - Name of the domain topic. -// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 100 +// - eventSubscriptionName - Name of the event subscription to be created. Event subscription names must be between 3 and 64 // characters in length and use alphanumeric letters only. // - eventSubscriptionInfo - Event subscription properties containing the destination and filter information. // - options - TopicEventSubscriptionsClientBeginCreateOrUpdateOptions contains the optional parameters for the TopicEventSubscriptionsClient.BeginCreateOrUpdate @@ -76,7 +76,7 @@ func (client *TopicEventSubscriptionsClient) BeginCreateOrUpdate(ctx context.Con // CreateOrUpdate - Asynchronously creates a new event subscription or updates an existing event subscription. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *TopicEventSubscriptionsClient) createOrUpdate(ctx context.Context, resourceGroupName string, topicName string, eventSubscriptionName string, eventSubscriptionInfo EventSubscription, options *TopicEventSubscriptionsClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "TopicEventSubscriptionsClient.BeginCreateOrUpdate" @@ -122,7 +122,7 @@ func (client *TopicEventSubscriptionsClient) createOrUpdateCreateRequest(ctx con return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, eventSubscriptionInfo); err != nil { @@ -134,11 +134,10 @@ func (client *TopicEventSubscriptionsClient) createOrUpdateCreateRequest(ctx con // BeginDelete - Delete an existing event subscription for a topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - topicName - Name of the topic. -// - eventSubscriptionName - Name of the event subscription to be deleted. Event subscription names must be between 3 and 100 -// characters in length and use alphanumeric letters only. +// - eventSubscriptionName - Name of the event subscription to be deleted. // - options - TopicEventSubscriptionsClientBeginDeleteOptions contains the optional parameters for the TopicEventSubscriptionsClient.BeginDelete // method. func (client *TopicEventSubscriptionsClient) BeginDelete(ctx context.Context, resourceGroupName string, topicName string, eventSubscriptionName string, options *TopicEventSubscriptionsClientBeginDeleteOptions) (*runtime.Poller[TopicEventSubscriptionsClientDeleteResponse], error) { @@ -161,7 +160,7 @@ func (client *TopicEventSubscriptionsClient) BeginDelete(ctx context.Context, re // Delete - Delete an existing event subscription for a topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *TopicEventSubscriptionsClient) deleteOperation(ctx context.Context, resourceGroupName string, topicName string, eventSubscriptionName string, options *TopicEventSubscriptionsClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "TopicEventSubscriptionsClient.BeginDelete" @@ -207,7 +206,7 @@ func (client *TopicEventSubscriptionsClient) deleteCreateRequest(ctx context.Con return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() return req, nil } @@ -215,11 +214,10 @@ func (client *TopicEventSubscriptionsClient) deleteCreateRequest(ctx context.Con // Get - Get properties of an event subscription of a topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - topicName - Name of the topic. -// - eventSubscriptionName - Name of the event subscription to be found. Event subscription names must be between 3 and 100 -// characters in length and use alphanumeric letters only. +// - eventSubscriptionName - Name of the event subscription to be found. // - options - TopicEventSubscriptionsClientGetOptions contains the optional parameters for the TopicEventSubscriptionsClient.Get // method. func (client *TopicEventSubscriptionsClient) Get(ctx context.Context, resourceGroupName string, topicName string, eventSubscriptionName string, options *TopicEventSubscriptionsClientGetOptions) (TopicEventSubscriptionsClientGetResponse, error) { @@ -268,7 +266,7 @@ func (client *TopicEventSubscriptionsClient) getCreateRequest(ctx context.Contex return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -286,7 +284,7 @@ func (client *TopicEventSubscriptionsClient) getHandleResponse(resp *http.Respon // GetDeliveryAttributes - Get all delivery attributes for an event subscription for topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - topicName - Name of the topic. // - eventSubscriptionName - Name of the event subscription. @@ -338,7 +336,7 @@ func (client *TopicEventSubscriptionsClient) getDeliveryAttributesCreateRequest( return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -356,7 +354,7 @@ func (client *TopicEventSubscriptionsClient) getDeliveryAttributesHandleResponse // GetFullURL - Get the full endpoint URL for an event subscription for topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - topicName - Name of the domain topic. // - eventSubscriptionName - Name of the event subscription. @@ -408,7 +406,7 @@ func (client *TopicEventSubscriptionsClient) getFullURLCreateRequest(ctx context return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -425,7 +423,7 @@ func (client *TopicEventSubscriptionsClient) getFullURLHandleResponse(resp *http // NewListPager - List all event subscriptions that have been created for a specific topic. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - topicName - Name of the topic. // - options - TopicEventSubscriptionsClientListOptions contains the optional parameters for the TopicEventSubscriptionsClient.NewListPager @@ -473,13 +471,13 @@ func (client *TopicEventSubscriptionsClient) listCreateRequest(ctx context.Conte return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -497,7 +495,7 @@ func (client *TopicEventSubscriptionsClient) listHandleResponse(resp *http.Respo // BeginUpdate - Update an existing event subscription for a topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - topicName - Name of the domain. // - eventSubscriptionName - Name of the event subscription to be updated. @@ -524,7 +522,7 @@ func (client *TopicEventSubscriptionsClient) BeginUpdate(ctx context.Context, re // Update - Update an existing event subscription for a topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *TopicEventSubscriptionsClient) update(ctx context.Context, resourceGroupName string, topicName string, eventSubscriptionName string, eventSubscriptionUpdateParameters EventSubscriptionUpdateParameters, options *TopicEventSubscriptionsClientBeginUpdateOptions) (*http.Response, error) { var err error const operationName = "TopicEventSubscriptionsClient.BeginUpdate" @@ -570,7 +568,7 @@ func (client *TopicEventSubscriptionsClient) updateCreateRequest(ctx context.Con return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, eventSubscriptionUpdateParameters); err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/topiceventsubscriptions_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/topiceventsubscriptions_client_example_test.go index f3a0e42dd8bd..e60ca91bc248 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/topiceventsubscriptions_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/topiceventsubscriptions_client_example_test.go @@ -18,7 +18,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/TopicEventSubscriptions_GetDeliveryAttributes.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/TopicEventSubscriptions_GetDeliveryAttributes.json func ExampleTopicEventSubscriptionsClient_GetDeliveryAttributes() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -64,7 +64,7 @@ func ExampleTopicEventSubscriptionsClient_GetDeliveryAttributes() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/TopicEventSubscriptions_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/TopicEventSubscriptions_Get.json func ExampleTopicEventSubscriptionsClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -116,7 +116,7 @@ func ExampleTopicEventSubscriptionsClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/TopicEventSubscriptions_CreateOrUpdate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/TopicEventSubscriptions_CreateOrUpdate.json func ExampleTopicEventSubscriptionsClient_BeginCreateOrUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -179,7 +179,7 @@ func ExampleTopicEventSubscriptionsClient_BeginCreateOrUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/TopicEventSubscriptions_Delete.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/TopicEventSubscriptions_Delete.json func ExampleTopicEventSubscriptionsClient_BeginDelete() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -200,7 +200,7 @@ func ExampleTopicEventSubscriptionsClient_BeginDelete() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/TopicEventSubscriptions_Update.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/TopicEventSubscriptions_Update.json func ExampleTopicEventSubscriptionsClient_BeginUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -236,7 +236,7 @@ func ExampleTopicEventSubscriptionsClient_BeginUpdate() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/TopicEventSubscriptions_GetFullUrl.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/TopicEventSubscriptions_GetFullUrl.json func ExampleTopicEventSubscriptionsClient_GetFullURL() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -259,7 +259,7 @@ func ExampleTopicEventSubscriptionsClient_GetFullURL() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/TopicEventSubscriptions_List.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/TopicEventSubscriptions_List.json func ExampleTopicEventSubscriptionsClient_NewListPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/topics_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/topics_client.go index 686f36fd0570..3279a2cd3a64 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/topics_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/topics_client.go @@ -48,7 +48,7 @@ func NewTopicsClient(subscriptionID string, credential azcore.TokenCredential, o // BeginCreateOrUpdate - Asynchronously creates a new topic with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - topicName - Name of the topic. // - topicInfo - Topic information. @@ -74,7 +74,7 @@ func (client *TopicsClient) BeginCreateOrUpdate(ctx context.Context, resourceGro // CreateOrUpdate - Asynchronously creates a new topic with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *TopicsClient) createOrUpdate(ctx context.Context, resourceGroupName string, topicName string, topicInfo Topic, options *TopicsClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "TopicsClient.BeginCreateOrUpdate" @@ -116,7 +116,7 @@ func (client *TopicsClient) createOrUpdateCreateRequest(ctx context.Context, res return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, topicInfo); err != nil { @@ -128,7 +128,7 @@ func (client *TopicsClient) createOrUpdateCreateRequest(ctx context.Context, res // BeginDelete - Delete existing topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - topicName - Name of the topic. // - options - TopicsClientBeginDeleteOptions contains the optional parameters for the TopicsClient.BeginDelete method. @@ -152,7 +152,7 @@ func (client *TopicsClient) BeginDelete(ctx context.Context, resourceGroupName s // Delete - Delete existing topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *TopicsClient) deleteOperation(ctx context.Context, resourceGroupName string, topicName string, options *TopicsClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "TopicsClient.BeginDelete" @@ -194,7 +194,7 @@ func (client *TopicsClient) deleteCreateRequest(ctx context.Context, resourceGro return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() return req, nil } @@ -202,7 +202,7 @@ func (client *TopicsClient) deleteCreateRequest(ctx context.Context, resourceGro // Get - Get properties of a topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - topicName - Name of the topic. // - options - TopicsClientGetOptions contains the optional parameters for the TopicsClient.Get method. @@ -248,7 +248,7 @@ func (client *TopicsClient) getCreateRequest(ctx context.Context, resourceGroupN return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -265,7 +265,7 @@ func (client *TopicsClient) getHandleResponse(resp *http.Response) (TopicsClient // NewListByResourceGroupPager - List all the topics under a resource group. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - options - TopicsClientListByResourceGroupOptions contains the optional parameters for the TopicsClient.NewListByResourceGroupPager // method. @@ -308,13 +308,13 @@ func (client *TopicsClient) listByResourceGroupCreateRequest(ctx context.Context return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -331,7 +331,7 @@ func (client *TopicsClient) listByResourceGroupHandleResponse(resp *http.Respons // NewListBySubscriptionPager - List all the topics under an Azure subscription. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - options - TopicsClientListBySubscriptionOptions contains the optional parameters for the TopicsClient.NewListBySubscriptionPager // method. func (client *TopicsClient) NewListBySubscriptionPager(options *TopicsClientListBySubscriptionOptions) *runtime.Pager[TopicsClientListBySubscriptionResponse] { @@ -369,13 +369,13 @@ func (client *TopicsClient) listBySubscriptionCreateRequest(ctx context.Context, return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -392,7 +392,7 @@ func (client *TopicsClient) listBySubscriptionHandleResponse(resp *http.Response // NewListEventTypesPager - List event types for a topic. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - providerNamespace - Namespace of the provider of the topic. // - resourceTypeName - Name of the topic type. @@ -451,7 +451,7 @@ func (client *TopicsClient) listEventTypesCreateRequest(ctx context.Context, res return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -469,7 +469,7 @@ func (client *TopicsClient) listEventTypesHandleResponse(resp *http.Response) (T // ListSharedAccessKeys - List the two keys used to publish to a topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - topicName - Name of the topic. // - options - TopicsClientListSharedAccessKeysOptions contains the optional parameters for the TopicsClient.ListSharedAccessKeys @@ -516,7 +516,7 @@ func (client *TopicsClient) listSharedAccessKeysCreateRequest(ctx context.Contex return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -534,7 +534,7 @@ func (client *TopicsClient) listSharedAccessKeysHandleResponse(resp *http.Respon // BeginRegenerateKey - Regenerate a shared access key for a topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - topicName - Name of the topic. // - regenerateKeyRequest - Request body to regenerate key. @@ -560,7 +560,7 @@ func (client *TopicsClient) BeginRegenerateKey(ctx context.Context, resourceGrou // RegenerateKey - Regenerate a shared access key for a topic. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *TopicsClient) regenerateKey(ctx context.Context, resourceGroupName string, topicName string, regenerateKeyRequest TopicRegenerateKeyRequest, options *TopicsClientBeginRegenerateKeyOptions) (*http.Response, error) { var err error const operationName = "TopicsClient.BeginRegenerateKey" @@ -602,7 +602,7 @@ func (client *TopicsClient) regenerateKeyCreateRequest(ctx context.Context, reso return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, regenerateKeyRequest); err != nil { @@ -614,7 +614,7 @@ func (client *TopicsClient) regenerateKeyCreateRequest(ctx context.Context, reso // BeginUpdate - Asynchronously updates a topic with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - topicName - Name of the topic. // - topicUpdateParameters - Topic update information. @@ -639,7 +639,7 @@ func (client *TopicsClient) BeginUpdate(ctx context.Context, resourceGroupName s // Update - Asynchronously updates a topic with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *TopicsClient) update(ctx context.Context, resourceGroupName string, topicName string, topicUpdateParameters TopicUpdateParameters, options *TopicsClientBeginUpdateOptions) (*http.Response, error) { var err error const operationName = "TopicsClient.BeginUpdate" @@ -681,7 +681,7 @@ func (client *TopicsClient) updateCreateRequest(ctx context.Context, resourceGro return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, topicUpdateParameters); err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/topics_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/topics_client_example_test.go index 104dad6577e4..f00e30aa3299 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/topics_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/topics_client_example_test.go @@ -18,7 +18,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Topics_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Topics_Get.json func ExampleTopicsClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -52,7 +52,7 @@ func ExampleTopicsClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Topics_CreateOrUpdate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Topics_CreateOrUpdate.json func ExampleTopicsClient_BeginCreateOrUpdate_topicsCreateOrUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -91,7 +91,7 @@ func ExampleTopicsClient_BeginCreateOrUpdate_topicsCreateOrUpdate() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Topics_CreateOrUpdateForAzureArc.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Topics_CreateOrUpdateForAzureArc.json func ExampleTopicsClient_BeginCreateOrUpdate_topicsCreateOrUpdateForAzureArc() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -126,7 +126,7 @@ func ExampleTopicsClient_BeginCreateOrUpdate_topicsCreateOrUpdateForAzureArc() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Topics_Delete.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Topics_Delete.json func ExampleTopicsClient_BeginDelete() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -147,7 +147,7 @@ func ExampleTopicsClient_BeginDelete() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Topics_Update.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Topics_Update.json func ExampleTopicsClient_BeginUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -185,7 +185,7 @@ func ExampleTopicsClient_BeginUpdate() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Topics_ListBySubscription.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Topics_ListBySubscription.json func ExampleTopicsClient_NewListBySubscriptionPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -243,7 +243,7 @@ func ExampleTopicsClient_NewListBySubscriptionPager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Topics_ListByResourceGroup.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Topics_ListByResourceGroup.json func ExampleTopicsClient_NewListByResourceGroupPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -301,7 +301,7 @@ func ExampleTopicsClient_NewListByResourceGroupPager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Topics_ListSharedAccessKeys.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Topics_ListSharedAccessKeys.json func ExampleTopicsClient_ListSharedAccessKeys() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -325,7 +325,7 @@ func ExampleTopicsClient_ListSharedAccessKeys() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Topics_RegenerateKey.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Topics_RegenerateKey.json func ExampleTopicsClient_BeginRegenerateKey() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -355,7 +355,7 @@ func ExampleTopicsClient_BeginRegenerateKey() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/Topics_ListEventTypes.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/Topics_ListEventTypes.json func ExampleTopicsClient_NewListEventTypesPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/topicspaces_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/topicspaces_client.go index 08cf301e333c..2e4f43d3e93e 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/topicspaces_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/topicspaces_client.go @@ -48,7 +48,7 @@ func NewTopicSpacesClient(subscriptionID string, credential azcore.TokenCredenti // BeginCreateOrUpdate - Create or update a topic space with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - topicSpaceName - The topic space name. @@ -76,7 +76,7 @@ func (client *TopicSpacesClient) BeginCreateOrUpdate(ctx context.Context, resour // CreateOrUpdate - Create or update a topic space with the specified parameters. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *TopicSpacesClient) createOrUpdate(ctx context.Context, resourceGroupName string, namespaceName string, topicSpaceName string, topicSpaceInfo TopicSpace, options *TopicSpacesClientBeginCreateOrUpdateOptions) (*http.Response, error) { var err error const operationName = "TopicSpacesClient.BeginCreateOrUpdate" @@ -122,7 +122,7 @@ func (client *TopicSpacesClient) createOrUpdateCreateRequest(ctx context.Context return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} if err := runtime.MarshalAsJSON(req, topicSpaceInfo); err != nil { @@ -134,7 +134,7 @@ func (client *TopicSpacesClient) createOrUpdateCreateRequest(ctx context.Context // BeginDelete - Delete an existing topic space. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - topicSpaceName - Name of the Topic space. @@ -160,7 +160,7 @@ func (client *TopicSpacesClient) BeginDelete(ctx context.Context, resourceGroupN // Delete - Delete an existing topic space. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview func (client *TopicSpacesClient) deleteOperation(ctx context.Context, resourceGroupName string, namespaceName string, topicSpaceName string, options *TopicSpacesClientBeginDeleteOptions) (*http.Response, error) { var err error const operationName = "TopicSpacesClient.BeginDelete" @@ -206,7 +206,7 @@ func (client *TopicSpacesClient) deleteCreateRequest(ctx context.Context, resour return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -215,7 +215,7 @@ func (client *TopicSpacesClient) deleteCreateRequest(ctx context.Context, resour // Get - Get properties of a topic space. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - topicSpaceName - Name of the Topic space. @@ -266,7 +266,7 @@ func (client *TopicSpacesClient) getCreateRequest(ctx context.Context, resourceG return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -283,7 +283,7 @@ func (client *TopicSpacesClient) getHandleResponse(resp *http.Response) (TopicSp // NewListByNamespacePager - Get all the topic spaces under a namespace. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - resourceGroupName - The name of the resource group within the user's subscription. // - namespaceName - Name of the namespace. // - options - TopicSpacesClientListByNamespaceOptions contains the optional parameters for the TopicSpacesClient.NewListByNamespacePager @@ -331,13 +331,13 @@ func (client *TopicSpacesClient) listByNamespaceCreateRequest(ctx context.Contex return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/topicspaces_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/topicspaces_client_example_test.go index 9aee79268514..dd3f41e5f66a 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/topicspaces_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/topicspaces_client_example_test.go @@ -18,7 +18,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/TopicSpaces_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/TopicSpaces_Get.json func ExampleTopicSpacesClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -49,7 +49,7 @@ func ExampleTopicSpacesClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/TopicSpaces_CreateOrUpdate.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/TopicSpaces_CreateOrUpdate.json func ExampleTopicSpacesClient_BeginCreateOrUpdate() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -90,7 +90,7 @@ func ExampleTopicSpacesClient_BeginCreateOrUpdate() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/TopicSpaces_Delete.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/TopicSpaces_Delete.json func ExampleTopicSpacesClient_BeginDelete() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -111,7 +111,7 @@ func ExampleTopicSpacesClient_BeginDelete() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/TopicSpaces_ListByNamespace.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/TopicSpaces_ListByNamespace.json func ExampleTopicSpacesClient_NewListByNamespacePager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/topictypes_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/topictypes_client.go index f7976cf3425f..4e3bc5daa994 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/topictypes_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/topictypes_client.go @@ -43,7 +43,7 @@ func NewTopicTypesClient(credential azcore.TokenCredential, options *arm.ClientO // Get - Get information about a topic type. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - topicTypeName - Name of the topic type. // - options - TopicTypesClientGetOptions contains the optional parameters for the TopicTypesClient.Get method. func (client *TopicTypesClient) Get(ctx context.Context, topicTypeName string, options *TopicTypesClientGetOptions) (TopicTypesClientGetResponse, error) { @@ -80,7 +80,7 @@ func (client *TopicTypesClient) getCreateRequest(ctx context.Context, topicTypeN return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -97,7 +97,7 @@ func (client *TopicTypesClient) getHandleResponse(resp *http.Response) (TopicTyp // NewListPager - List all registered topic types. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - options - TopicTypesClientListOptions contains the optional parameters for the TopicTypesClient.NewListPager method. func (client *TopicTypesClient) NewListPager(options *TopicTypesClientListOptions) *runtime.Pager[TopicTypesClientListResponse] { return runtime.NewPager(runtime.PagingHandler[TopicTypesClientListResponse]{ @@ -131,7 +131,7 @@ func (client *TopicTypesClient) listCreateRequest(ctx context.Context, options * return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -148,7 +148,7 @@ func (client *TopicTypesClient) listHandleResponse(resp *http.Response) (TopicTy // NewListEventTypesPager - List event types for a topic type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - topicTypeName - Name of the topic type. // - options - TopicTypesClientListEventTypesOptions contains the optional parameters for the TopicTypesClient.NewListEventTypesPager // method. @@ -188,7 +188,7 @@ func (client *TopicTypesClient) listEventTypesCreateRequest(ctx context.Context, return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/topictypes_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/topictypes_client_example_test.go index f7c2438817ea..c7ecfa80dacd 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/topictypes_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/topictypes_client_example_test.go @@ -17,7 +17,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/TopicTypes_List.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/TopicTypes_List.json func ExampleTopicTypesClient_NewListPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -69,7 +69,7 @@ func ExampleTopicTypesClient_NewListPager() { } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/TopicTypes_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/TopicTypes_Get.json func ExampleTopicTypesClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -101,7 +101,7 @@ func ExampleTopicTypesClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/TopicTypes_ListEventTypes.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/TopicTypes_ListEventTypes.json func ExampleTopicTypesClient_NewListEventTypesPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/verifiedpartners_client.go b/sdk/resourcemanager/eventgrid/armeventgrid/verifiedpartners_client.go index 114af6176e0c..be9274ad991b 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/verifiedpartners_client.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/verifiedpartners_client.go @@ -44,7 +44,7 @@ func NewVerifiedPartnersClient(credential azcore.TokenCredential, options *arm.C // Get - Get properties of a verified partner. // If the operation fails it returns an *azcore.ResponseError type. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - verifiedPartnerName - Name of the verified partner. // - options - VerifiedPartnersClientGetOptions contains the optional parameters for the VerifiedPartnersClient.Get method. func (client *VerifiedPartnersClient) Get(ctx context.Context, verifiedPartnerName string, options *VerifiedPartnersClientGetOptions) (VerifiedPartnersClientGetResponse, error) { @@ -81,7 +81,7 @@ func (client *VerifiedPartnersClient) getCreateRequest(ctx context.Context, veri return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil @@ -98,7 +98,7 @@ func (client *VerifiedPartnersClient) getHandleResponse(resp *http.Response) (Ve // NewListPager - Get a list of all verified partners. // -// Generated from API version 2023-12-15-preview +// Generated from API version 2024-06-01-preview // - options - VerifiedPartnersClientListOptions contains the optional parameters for the VerifiedPartnersClient.NewListPager // method. func (client *VerifiedPartnersClient) NewListPager(options *VerifiedPartnersClientListOptions) *runtime.Pager[VerifiedPartnersClientListResponse] { @@ -132,13 +132,13 @@ func (client *VerifiedPartnersClient) listCreateRequest(ctx context.Context, opt return nil, err } reqQP := req.Raw().URL.Query() - reqQP.Set("api-version", "2023-12-15-preview") if options != nil && options.Filter != nil { reqQP.Set("$filter", *options.Filter) } if options != nil && options.Top != nil { reqQP.Set("$top", strconv.FormatInt(int64(*options.Top), 10)) } + reqQP.Set("api-version", "2024-06-01-preview") req.Raw().URL.RawQuery = reqQP.Encode() req.Raw().Header["Accept"] = []string{"application/json"} return req, nil diff --git a/sdk/resourcemanager/eventgrid/armeventgrid/verifiedpartners_client_example_test.go b/sdk/resourcemanager/eventgrid/armeventgrid/verifiedpartners_client_example_test.go index 2bd6f612aea4..58c583bfa512 100644 --- a/sdk/resourcemanager/eventgrid/armeventgrid/verifiedpartners_client_example_test.go +++ b/sdk/resourcemanager/eventgrid/armeventgrid/verifiedpartners_client_example_test.go @@ -17,7 +17,7 @@ import ( "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/eventgrid/armeventgrid/v2" ) -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/VerifiedPartners_Get.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/VerifiedPartners_Get.json func ExampleVerifiedPartnersClient_Get() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { @@ -57,7 +57,7 @@ func ExampleVerifiedPartnersClient_Get() { // } } -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/bf204aab860f2eb58a9d346b00d44760f2a9b0a2/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2023-12-15-preview/examples/VerifiedPartners_List.json +// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/b8691fbfca8fcdc5a241a0b501c32fd4a76bb0cd/specification/eventgrid/resource-manager/Microsoft.EventGrid/preview/2024-06-01-preview/examples/VerifiedPartners_List.json func ExampleVerifiedPartnersClient_NewListPager() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil {