### Method

# Soup WebsocketConnection get_close_data

#### Declaration [src]

    const char*
    soup_websocket_connection_get_close_data (
      SoupWebsocketConnection* self
    )

#### Description [src]

Get the close data received from the WebSocket peer.

This only becomes valid once the WebSocket is in the `SOUP_WEBSOCKET_STATE_CLOSED` state. The data may be freed once the main loop is run, so copy it if you need to keep it around.

#### Return value

Type: `const char*`

The close data or `NULL`.

The data is owned by the instance.
The value is a NUL terminated UTF-8 string.