Description
https://github.com/enisdenjo/graphql-ws/blob/master/PROTOCOL.md#complete
Direction: bidirectional
Server -> Client indicates that the requested operation execution has completed. If the server dispatched the Error message relative to the original Subscribe message, no Complete message will be emitted.
Client -> Server indicates that the client has stopped listening and wants to complete the subscription. No further events, relevant to the original subscription, should be sent through. Even if the client sent a Complete message for a single-result-operation before it resolved, the result should not be sent through once it does.
Note: The asynchronous nature of the full-duplex connection means that a client can send a Complete message to the server even when messages are in-flight to the client, or when the server has itself completed the operation (via a Error or Complete message). Both client and server must therefore be prepared to receive (and ignore) messages for operations that they consider already completed.
interface CompleteMessage {
id: '<unique-operation-id>';
type: 'complete';
}