Method SendAsync
| Improve this Doc View SourceSendAsync<TResponse>(IForm, CancellationToken)
Sends an asynchronous HTTP request and returns the deserialized response.
Avoid calling directly unless the Lemmy instance requires non-standard API calls.
Declaration
public Task<TResponse> SendAsync<TResponse>(IForm form, CancellationToken cancellationToken = default) where TResponse : Response, new()
Parameters
| Type | Name | Description |
|---|---|---|
| IForm | form | The form data to be sent, inherits IForm |
| CancellationToken | cancellationToken | Optional cancellation token to pass through to HttpClient |
Returns
| Type | Description |
|---|---|
| Task<TResponse> | The deserialized response format |
Type Parameters
| Name | Description |
|---|---|
| TResponse | Deserialized response format, inherits Response |