-
Notifications
You must be signed in to change notification settings - Fork 371
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
PiperOrigin-RevId: 716133197 Source-Link: googleapis/googleapis@d27e7a1 Source-Link: googleapis/googleapis-gen@1839ebd Copy-Tag: eyJwIjoiYXBpcy9Hb29nbGUuQ2xvdWQuU2VjcmV0TWFuYWdlci5WMUJldGEyLy5Pd2xCb3QueWFtbCIsImgiOiIxODM5ZWJkOTdlNDI5ZGYxZTkzZjAxYmZiYmM5NWFiM2Q0ZDc0YzNjIn0=
- Loading branch information
1 parent
20f810b
commit a621df0
Showing
94 changed files
with
24,706 additions
and
0 deletions.
There are no files selected for viewing
15 changes: 15 additions & 0 deletions
15
...ger.V1Beta2.GeneratedSnippets/Google.Cloud.SecretManager.V1Beta2.GeneratedSnippets.csproj
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
|
||
<PropertyGroup> | ||
<TargetFrameworks>net6.0;net462</TargetFrameworks> | ||
<LangVersion>latest</LangVersion> | ||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
<ProjectReference Include="../Google.Cloud.SecretManager.V1Beta2/Google.Cloud.SecretManager.V1Beta2.csproj" /> | ||
<PackageReference Include="System.Linq.Async" Version="6.0.1" /> | ||
<PackageReference Include="Microsoft.NETFramework.ReferenceAssemblies" Version="1.0.3" PrivateAssets="All" /> | ||
</ItemGroup> | ||
|
||
</Project> |
44 changes: 44 additions & 0 deletions
44
...V1Beta2.GeneratedSnippets/SecretManagerServiceClient.AccessSecretVersionAsyncSnippet.g.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
// Copyright 2025 Google LLC | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// https://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
// Generated code. DO NOT EDIT! | ||
|
||
namespace GoogleCSharpSnippets | ||
{ | ||
// [START secretmanager_v1beta2_generated_SecretManagerService_AccessSecretVersion_async_flattened] | ||
using Google.Cloud.SecretManager.V1Beta2; | ||
using System.Threading.Tasks; | ||
|
||
public sealed partial class GeneratedSecretManagerServiceClientSnippets | ||
{ | ||
/// <summary>Snippet for AccessSecretVersionAsync</summary> | ||
/// <remarks> | ||
/// This snippet has been automatically generated and should be regarded as a code template only. | ||
/// It will require modifications to work: | ||
/// - It may require correct/in-range values for request initialization. | ||
/// - It may require specifying regional endpoints when creating the service client as shown in | ||
/// https://cloud.google.com/dotnet/docs/reference/help/client-configuration#endpoint. | ||
/// </remarks> | ||
public async Task AccessSecretVersionAsync() | ||
{ | ||
// Create client | ||
SecretManagerServiceClient secretManagerServiceClient = await SecretManagerServiceClient.CreateAsync(); | ||
// Initialize request argument(s) | ||
string name = "projects/[PROJECT]/secrets/[SECRET]/versions/[SECRET_VERSION]"; | ||
// Make the request | ||
AccessSecretVersionResponse response = await secretManagerServiceClient.AccessSecretVersionAsync(name); | ||
} | ||
} | ||
// [END secretmanager_v1beta2_generated_SecretManagerService_AccessSecretVersion_async_flattened] | ||
} |
47 changes: 47 additions & 0 deletions
47
...atedSnippets/SecretManagerServiceClient.AccessSecretVersionRequestObjectAsyncSnippet.g.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
// Copyright 2025 Google LLC | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// https://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
// Generated code. DO NOT EDIT! | ||
|
||
namespace GoogleCSharpSnippets | ||
{ | ||
// [START secretmanager_v1beta2_generated_SecretManagerService_AccessSecretVersion_async] | ||
using Google.Cloud.SecretManager.V1Beta2; | ||
using System.Threading.Tasks; | ||
|
||
public sealed partial class GeneratedSecretManagerServiceClientSnippets | ||
{ | ||
/// <summary>Snippet for AccessSecretVersionAsync</summary> | ||
/// <remarks> | ||
/// This snippet has been automatically generated and should be regarded as a code template only. | ||
/// It will require modifications to work: | ||
/// - It may require correct/in-range values for request initialization. | ||
/// - It may require specifying regional endpoints when creating the service client as shown in | ||
/// https://cloud.google.com/dotnet/docs/reference/help/client-configuration#endpoint. | ||
/// </remarks> | ||
public async Task AccessSecretVersionRequestObjectAsync() | ||
{ | ||
// Create client | ||
SecretManagerServiceClient secretManagerServiceClient = await SecretManagerServiceClient.CreateAsync(); | ||
// Initialize request argument(s) | ||
AccessSecretVersionRequest request = new AccessSecretVersionRequest | ||
{ | ||
SecretVersionName = SecretVersionName.FromProjectSecretSecretVersion("[PROJECT]", "[SECRET]", "[SECRET_VERSION]"), | ||
}; | ||
// Make the request | ||
AccessSecretVersionResponse response = await secretManagerServiceClient.AccessSecretVersionAsync(request); | ||
} | ||
} | ||
// [END secretmanager_v1beta2_generated_SecretManagerService_AccessSecretVersion_async] | ||
} |
46 changes: 46 additions & 0 deletions
46
...GeneratedSnippets/SecretManagerServiceClient.AccessSecretVersionRequestObjectSnippet.g.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
// Copyright 2025 Google LLC | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// https://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
// Generated code. DO NOT EDIT! | ||
|
||
namespace GoogleCSharpSnippets | ||
{ | ||
// [START secretmanager_v1beta2_generated_SecretManagerService_AccessSecretVersion_sync] | ||
using Google.Cloud.SecretManager.V1Beta2; | ||
|
||
public sealed partial class GeneratedSecretManagerServiceClientSnippets | ||
{ | ||
/// <summary>Snippet for AccessSecretVersion</summary> | ||
/// <remarks> | ||
/// This snippet has been automatically generated and should be regarded as a code template only. | ||
/// It will require modifications to work: | ||
/// - It may require correct/in-range values for request initialization. | ||
/// - It may require specifying regional endpoints when creating the service client as shown in | ||
/// https://cloud.google.com/dotnet/docs/reference/help/client-configuration#endpoint. | ||
/// </remarks> | ||
public void AccessSecretVersionRequestObject() | ||
{ | ||
// Create client | ||
SecretManagerServiceClient secretManagerServiceClient = SecretManagerServiceClient.Create(); | ||
// Initialize request argument(s) | ||
AccessSecretVersionRequest request = new AccessSecretVersionRequest | ||
{ | ||
SecretVersionName = SecretVersionName.FromProjectSecretSecretVersion("[PROJECT]", "[SECRET]", "[SECRET_VERSION]"), | ||
}; | ||
// Make the request | ||
AccessSecretVersionResponse response = secretManagerServiceClient.AccessSecretVersion(request); | ||
} | ||
} | ||
// [END secretmanager_v1beta2_generated_SecretManagerService_AccessSecretVersion_sync] | ||
} |
44 changes: 44 additions & 0 deletions
44
...atedSnippets/SecretManagerServiceClient.AccessSecretVersionResourceNamesAsyncSnippet.g.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
// Copyright 2025 Google LLC | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// https://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
// Generated code. DO NOT EDIT! | ||
|
||
namespace GoogleCSharpSnippets | ||
{ | ||
// [START secretmanager_v1beta2_generated_SecretManagerService_AccessSecretVersion_async_flattened_resourceNames] | ||
using Google.Cloud.SecretManager.V1Beta2; | ||
using System.Threading.Tasks; | ||
|
||
public sealed partial class GeneratedSecretManagerServiceClientSnippets | ||
{ | ||
/// <summary>Snippet for AccessSecretVersionAsync</summary> | ||
/// <remarks> | ||
/// This snippet has been automatically generated and should be regarded as a code template only. | ||
/// It will require modifications to work: | ||
/// - It may require correct/in-range values for request initialization. | ||
/// - It may require specifying regional endpoints when creating the service client as shown in | ||
/// https://cloud.google.com/dotnet/docs/reference/help/client-configuration#endpoint. | ||
/// </remarks> | ||
public async Task AccessSecretVersionResourceNamesAsync() | ||
{ | ||
// Create client | ||
SecretManagerServiceClient secretManagerServiceClient = await SecretManagerServiceClient.CreateAsync(); | ||
// Initialize request argument(s) | ||
SecretVersionName name = SecretVersionName.FromProjectSecretSecretVersion("[PROJECT]", "[SECRET]", "[SECRET_VERSION]"); | ||
// Make the request | ||
AccessSecretVersionResponse response = await secretManagerServiceClient.AccessSecretVersionAsync(name); | ||
} | ||
} | ||
// [END secretmanager_v1beta2_generated_SecretManagerService_AccessSecretVersion_async_flattened_resourceNames] | ||
} |
43 changes: 43 additions & 0 deletions
43
...GeneratedSnippets/SecretManagerServiceClient.AccessSecretVersionResourceNamesSnippet.g.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
// Copyright 2025 Google LLC | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// https://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
// Generated code. DO NOT EDIT! | ||
|
||
namespace GoogleCSharpSnippets | ||
{ | ||
// [START secretmanager_v1beta2_generated_SecretManagerService_AccessSecretVersion_sync_flattened_resourceNames] | ||
using Google.Cloud.SecretManager.V1Beta2; | ||
|
||
public sealed partial class GeneratedSecretManagerServiceClientSnippets | ||
{ | ||
/// <summary>Snippet for AccessSecretVersion</summary> | ||
/// <remarks> | ||
/// This snippet has been automatically generated and should be regarded as a code template only. | ||
/// It will require modifications to work: | ||
/// - It may require correct/in-range values for request initialization. | ||
/// - It may require specifying regional endpoints when creating the service client as shown in | ||
/// https://cloud.google.com/dotnet/docs/reference/help/client-configuration#endpoint. | ||
/// </remarks> | ||
public void AccessSecretVersionResourceNames() | ||
{ | ||
// Create client | ||
SecretManagerServiceClient secretManagerServiceClient = SecretManagerServiceClient.Create(); | ||
// Initialize request argument(s) | ||
SecretVersionName name = SecretVersionName.FromProjectSecretSecretVersion("[PROJECT]", "[SECRET]", "[SECRET_VERSION]"); | ||
// Make the request | ||
AccessSecretVersionResponse response = secretManagerServiceClient.AccessSecretVersion(name); | ||
} | ||
} | ||
// [END secretmanager_v1beta2_generated_SecretManagerService_AccessSecretVersion_sync_flattened_resourceNames] | ||
} |
43 changes: 43 additions & 0 deletions
43
...ager.V1Beta2.GeneratedSnippets/SecretManagerServiceClient.AccessSecretVersionSnippet.g.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
// Copyright 2025 Google LLC | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// https://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
// Generated code. DO NOT EDIT! | ||
|
||
namespace GoogleCSharpSnippets | ||
{ | ||
// [START secretmanager_v1beta2_generated_SecretManagerService_AccessSecretVersion_sync_flattened] | ||
using Google.Cloud.SecretManager.V1Beta2; | ||
|
||
public sealed partial class GeneratedSecretManagerServiceClientSnippets | ||
{ | ||
/// <summary>Snippet for AccessSecretVersion</summary> | ||
/// <remarks> | ||
/// This snippet has been automatically generated and should be regarded as a code template only. | ||
/// It will require modifications to work: | ||
/// - It may require correct/in-range values for request initialization. | ||
/// - It may require specifying regional endpoints when creating the service client as shown in | ||
/// https://cloud.google.com/dotnet/docs/reference/help/client-configuration#endpoint. | ||
/// </remarks> | ||
public void AccessSecretVersion() | ||
{ | ||
// Create client | ||
SecretManagerServiceClient secretManagerServiceClient = SecretManagerServiceClient.Create(); | ||
// Initialize request argument(s) | ||
string name = "projects/[PROJECT]/secrets/[SECRET]/versions/[SECRET_VERSION]"; | ||
// Make the request | ||
AccessSecretVersionResponse response = secretManagerServiceClient.AccessSecretVersion(name); | ||
} | ||
} | ||
// [END secretmanager_v1beta2_generated_SecretManagerService_AccessSecretVersion_sync_flattened] | ||
} |
45 changes: 45 additions & 0 deletions
45
...er.V1Beta2.GeneratedSnippets/SecretManagerServiceClient.AddSecretVersionAsyncSnippet.g.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
// Copyright 2025 Google LLC | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// https://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
// Generated code. DO NOT EDIT! | ||
|
||
namespace GoogleCSharpSnippets | ||
{ | ||
// [START secretmanager_v1beta2_generated_SecretManagerService_AddSecretVersion_async_flattened] | ||
using Google.Cloud.SecretManager.V1Beta2; | ||
using System.Threading.Tasks; | ||
|
||
public sealed partial class GeneratedSecretManagerServiceClientSnippets | ||
{ | ||
/// <summary>Snippet for AddSecretVersionAsync</summary> | ||
/// <remarks> | ||
/// This snippet has been automatically generated and should be regarded as a code template only. | ||
/// It will require modifications to work: | ||
/// - It may require correct/in-range values for request initialization. | ||
/// - It may require specifying regional endpoints when creating the service client as shown in | ||
/// https://cloud.google.com/dotnet/docs/reference/help/client-configuration#endpoint. | ||
/// </remarks> | ||
public async Task AddSecretVersionAsync() | ||
{ | ||
// Create client | ||
SecretManagerServiceClient secretManagerServiceClient = await SecretManagerServiceClient.CreateAsync(); | ||
// Initialize request argument(s) | ||
string parent = "projects/[PROJECT]/secrets/[SECRET]"; | ||
SecretPayload payload = new SecretPayload(); | ||
// Make the request | ||
SecretVersion response = await secretManagerServiceClient.AddSecretVersionAsync(parent, payload); | ||
} | ||
} | ||
// [END secretmanager_v1beta2_generated_SecretManagerService_AddSecretVersion_async_flattened] | ||
} |
48 changes: 48 additions & 0 deletions
48
...neratedSnippets/SecretManagerServiceClient.AddSecretVersionRequestObjectAsyncSnippet.g.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
// Copyright 2025 Google LLC | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// https://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
// Generated code. DO NOT EDIT! | ||
|
||
namespace GoogleCSharpSnippets | ||
{ | ||
// [START secretmanager_v1beta2_generated_SecretManagerService_AddSecretVersion_async] | ||
using Google.Cloud.SecretManager.V1Beta2; | ||
using System.Threading.Tasks; | ||
|
||
public sealed partial class GeneratedSecretManagerServiceClientSnippets | ||
{ | ||
/// <summary>Snippet for AddSecretVersionAsync</summary> | ||
/// <remarks> | ||
/// This snippet has been automatically generated and should be regarded as a code template only. | ||
/// It will require modifications to work: | ||
/// - It may require correct/in-range values for request initialization. | ||
/// - It may require specifying regional endpoints when creating the service client as shown in | ||
/// https://cloud.google.com/dotnet/docs/reference/help/client-configuration#endpoint. | ||
/// </remarks> | ||
public async Task AddSecretVersionRequestObjectAsync() | ||
{ | ||
// Create client | ||
SecretManagerServiceClient secretManagerServiceClient = await SecretManagerServiceClient.CreateAsync(); | ||
// Initialize request argument(s) | ||
AddSecretVersionRequest request = new AddSecretVersionRequest | ||
{ | ||
ParentAsSecretName = SecretName.FromProjectSecret("[PROJECT]", "[SECRET]"), | ||
Payload = new SecretPayload(), | ||
}; | ||
// Make the request | ||
SecretVersion response = await secretManagerServiceClient.AddSecretVersionAsync(request); | ||
} | ||
} | ||
// [END secretmanager_v1beta2_generated_SecretManagerService_AddSecretVersion_async] | ||
} |
Oops, something went wrong.