Method DeleteMessageAsync
DeleteMessageAsync(string, StreamMsgDeleteRequest, CancellationToken)
Deletes a message from a stream.
ValueTask<StreamMsgDeleteResponse> DeleteMessageAsync(string stream, StreamMsgDeleteRequest request, CancellationToken cancellationToken = default)
Parameters
stream
stringStream name to delete message from.
request
StreamMsgDeleteRequestDelete message request.
cancellationToken
CancellationTokenA CancellationToken used to cancel the API call.
Returns
- ValueTask<StreamMsgDeleteResponse>
Delete message response
Exceptions
- NatsJSException
There was an issue retrieving the response.
- NatsJSApiException
Server responded with an error.