RESTCLIENT.NET
Menu
EN
↗ GitHub

RESTCLIENT.NET / API REFERENCE

RestClient.Net.PatchAsync<TSuccess, TError, TRequest>

All API types · RestClient.Net · View source

public delegate Task<Result<TSuccess, HttpError<TError>>> PatchAsync<TSuccess, TError, TRequest>(HttpClient httpClient, TRequest requestBody, CancellationToken cancellationToken = default);

Delegate for executing PATCH requests that return a Result with typed success and error responses.

Parameter Type Default Description
httpClient HttpClient Required The HttpClient to use for the request.
requestBody TRequest Required The request body content.
cancellationToken CancellationToken default Cancellation token to cancel the request.

Type parameter TSuccess: The type of the success response body.

Type parameter TError: The type of the error response body.

Type parameter TRequest: The type of the request body.

Returns: A Result containing either the success response or an HttpError with the error response.