Requests (opcode=0x8) the server to terminate the connection.

Unlike Efl.Io.Closer.close, this won't abruptly close the connection, rather it'll queue a message requesting the server to gracefully close it.

After this method is called you should consider the object in "closing" state. No more messages can be sent (Efl.Net.Dialer.Websocket.text_send, Efl.Net.Dialer.Websocket.binary_send and will fail).

The object will be automatically closed with Efl.Io.Closer.close once the server replies with his own close message, which will be reported as "closed,reason".

Since 1.19


close_request {
    params {
        @in reason: Efl.Net.Dialer.Websocket.Close_Reason;
        @in message: free(string, free) @optional;

C signature

void efl_net_dialer_websocket_close_request(Eo *obj, Efl_Net_Dialer_Websocket_Close_Reason reason, const char *message);


  • reason (in) - Reason for closing
  • message (in) - Additional closing message

Implemented by

  • Efl.Net.Dialer.Websocket.close_request