Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/renovate.json
Original file line number Diff line number Diff line change
Expand Up @@ -306,6 +306,7 @@
"apis/Google.Cloud.WorkloadManager.V1/Google.Cloud.WorkloadManager.V1/**",
"apis/Google.Cloud.Workstations.V1/Google.Cloud.Workstations.V1/**",
"apis/Google.Developers.Knowledge.V1/Google.Developers.Knowledge.V1/**",
"apis/Google.DevicesAndServices.Health.V4/Google.DevicesAndServices.Health.V4/**",
"apis/Google.Geo.Type/Google.Geo.Type/**",
"apis/Google.Identity.AccessContextManager.Type/Google.Identity.AccessContextManager.Type/**",
"apis/Google.Identity.AccessContextManager.V1/Google.Identity.AccessContextManager.V1/**",
Expand Down

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"distribution_name": "Google.DevicesAndServices.Health.V4",
"release_level": "unreleased",
"client_documentation": "https://googleapis.dev/dotnet/Google.DevicesAndServices.Health.V4/latest",
"library_type": "GAPIC_AUTO",
"language": "dotnet",
"api_shortname": "health"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
// Copyright 2026 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 health_v4_generated_DataPointsService_BatchDeleteDataPoints_async]
using Google.DevicesAndServices.Health.V4;
using Google.LongRunning;
using System.Threading.Tasks;

public sealed partial class GeneratedDataPointsServiceClientSnippets
{
/// <summary>Snippet for BatchDeleteDataPointsAsync</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 BatchDeleteDataPointsRequestObjectAsync()
{
// Create client
DataPointsServiceClient dataPointsServiceClient = await DataPointsServiceClient.CreateAsync();
// Initialize request argument(s)
BatchDeleteDataPointsRequest request = new BatchDeleteDataPointsRequest
{
ParentAsDataTypeName = DataTypeName.FromUserDataType("[USER]", "[DATA_TYPE]"),
DataPointNames =
{
DataPointName.FromUserDataTypeDataPoint("[USER]", "[DATA_TYPE]", "[DATA_POINT]"),
},
};
// Make the request
Operation<BatchDeleteDataPointsResponse, BatchDeleteDataPointsOperationMetadata> response = await dataPointsServiceClient.BatchDeleteDataPointsAsync(request);

// Poll until the returned long-running operation is complete
Operation<BatchDeleteDataPointsResponse, BatchDeleteDataPointsOperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
BatchDeleteDataPointsResponse result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BatchDeleteDataPointsResponse, BatchDeleteDataPointsOperationMetadata> retrievedResponse = await dataPointsServiceClient.PollOnceBatchDeleteDataPointsAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
BatchDeleteDataPointsResponse retrievedResult = retrievedResponse.Result;
}
}
}
// [END health_v4_generated_DataPointsService_BatchDeleteDataPoints_async]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
// Copyright 2026 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 health_v4_generated_DataPointsService_BatchDeleteDataPoints_sync]
using Google.DevicesAndServices.Health.V4;
using Google.LongRunning;

public sealed partial class GeneratedDataPointsServiceClientSnippets
{
/// <summary>Snippet for BatchDeleteDataPoints</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 BatchDeleteDataPointsRequestObject()
{
// Create client
DataPointsServiceClient dataPointsServiceClient = DataPointsServiceClient.Create();
// Initialize request argument(s)
BatchDeleteDataPointsRequest request = new BatchDeleteDataPointsRequest
{
ParentAsDataTypeName = DataTypeName.FromUserDataType("[USER]", "[DATA_TYPE]"),
DataPointNames =
{
DataPointName.FromUserDataTypeDataPoint("[USER]", "[DATA_TYPE]", "[DATA_POINT]"),
},
};
// Make the request
Operation<BatchDeleteDataPointsResponse, BatchDeleteDataPointsOperationMetadata> response = dataPointsServiceClient.BatchDeleteDataPoints(request);

// Poll until the returned long-running operation is complete
Operation<BatchDeleteDataPointsResponse, BatchDeleteDataPointsOperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
BatchDeleteDataPointsResponse result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<BatchDeleteDataPointsResponse, BatchDeleteDataPointsOperationMetadata> retrievedResponse = dataPointsServiceClient.PollOnceBatchDeleteDataPoints(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
BatchDeleteDataPointsResponse retrievedResult = retrievedResponse.Result;
}
}
}
// [END health_v4_generated_DataPointsService_BatchDeleteDataPoints_sync]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
// Copyright 2026 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 health_v4_generated_DataPointsService_CreateDataPoint_async_flattened]
using Google.DevicesAndServices.Health.V4;
using Google.LongRunning;
using System.Threading.Tasks;

public sealed partial class GeneratedDataPointsServiceClientSnippets
{
/// <summary>Snippet for CreateDataPointAsync</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 CreateDataPointAsync()
{
// Create client
DataPointsServiceClient dataPointsServiceClient = await DataPointsServiceClient.CreateAsync();
// Initialize request argument(s)
string parent = "users/[USER]/dataTypes/[DATA_TYPE]";
DataPoint dataPoint = new DataPoint();
// Make the request
Operation<DataPoint, CreateDataPointOperationMetadata> response = await dataPointsServiceClient.CreateDataPointAsync(parent, dataPoint);

// Poll until the returned long-running operation is complete
Operation<DataPoint, CreateDataPointOperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
DataPoint result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<DataPoint, CreateDataPointOperationMetadata> retrievedResponse = await dataPointsServiceClient.PollOnceCreateDataPointAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
DataPoint retrievedResult = retrievedResponse.Result;
}
}
}
// [END health_v4_generated_DataPointsService_CreateDataPoint_async_flattened]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
// Copyright 2026 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 health_v4_generated_DataPointsService_CreateDataPoint_async]
using Google.DevicesAndServices.Health.V4;
using Google.LongRunning;
using System.Threading.Tasks;

public sealed partial class GeneratedDataPointsServiceClientSnippets
{
/// <summary>Snippet for CreateDataPointAsync</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 CreateDataPointRequestObjectAsync()
{
// Create client
DataPointsServiceClient dataPointsServiceClient = await DataPointsServiceClient.CreateAsync();
// Initialize request argument(s)
CreateDataPointRequest request = new CreateDataPointRequest
{
ParentAsDataTypeName = DataTypeName.FromUserDataType("[USER]", "[DATA_TYPE]"),
DataPoint = new DataPoint(),
};
// Make the request
Operation<DataPoint, CreateDataPointOperationMetadata> response = await dataPointsServiceClient.CreateDataPointAsync(request);

// Poll until the returned long-running operation is complete
Operation<DataPoint, CreateDataPointOperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
DataPoint result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<DataPoint, CreateDataPointOperationMetadata> retrievedResponse = await dataPointsServiceClient.PollOnceCreateDataPointAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
DataPoint retrievedResult = retrievedResponse.Result;
}
}
}
// [END health_v4_generated_DataPointsService_CreateDataPoint_async]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
// Copyright 2026 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 health_v4_generated_DataPointsService_CreateDataPoint_sync]
using Google.DevicesAndServices.Health.V4;
using Google.LongRunning;

public sealed partial class GeneratedDataPointsServiceClientSnippets
{
/// <summary>Snippet for CreateDataPoint</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 CreateDataPointRequestObject()
{
// Create client
DataPointsServiceClient dataPointsServiceClient = DataPointsServiceClient.Create();
// Initialize request argument(s)
CreateDataPointRequest request = new CreateDataPointRequest
{
ParentAsDataTypeName = DataTypeName.FromUserDataType("[USER]", "[DATA_TYPE]"),
DataPoint = new DataPoint(),
};
// Make the request
Operation<DataPoint, CreateDataPointOperationMetadata> response = dataPointsServiceClient.CreateDataPoint(request);

// Poll until the returned long-running operation is complete
Operation<DataPoint, CreateDataPointOperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
DataPoint result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<DataPoint, CreateDataPointOperationMetadata> retrievedResponse = dataPointsServiceClient.PollOnceCreateDataPoint(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
// If it has completed, then access the result
DataPoint retrievedResult = retrievedResponse.Result;
}
}
}
// [END health_v4_generated_DataPointsService_CreateDataPoint_sync]
}
Loading
Loading