> ## Documentation Index
> Fetch the complete documentation index at: https://docs.kraken.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Ping

> Verify the WebSocket connection is alive with a ping/pong request

<div className="api-banner">
  <span className="api-protocol ws">WSS</span>
  <span className="api-detail">ws.kraken.com/v2</span>
  <span className="api-tag">ping</span>
</div>

Clients can ping the server to verify connection is alive and the server will respond with a `pong`.

This is an application level ping, distinct from the protocol-level ping in the WebSockets standard.

<Tabs>
  <Tab title="Request">
    <ResponseField name="method" type="string" required>
      Value: `ping`
    </ResponseField>

    <ResponseField name="req_id" type="integer">
      Optional client originated request identifier sent as acknowledgment in the response.
    </ResponseField>
  </Tab>

  <Tab title="Response">
    <ResponseField name="method" type="string">
      Value: `pong`
    </ResponseField>

    <ResponseField name="error" type="string">
      Error message. Condition: if `success` is `false`.
    </ResponseField>

    <ResponseField name="success" type="boolean">
      Indicates if the request was successfully processed by the engine. One of: `true`, `false`
    </ResponseField>

    <ResponseField name="req_id" type="integer">
      Optional client originated request identifier sent as acknowledgment in the response.
    </ResponseField>

    <ResponseField name="time_in" type="string">
      The timestamp when the request was received on the wire, just prior to parsing data. Format: RFC3339. Example: `2022-12-25T09:30:59.123456Z`
    </ResponseField>

    <ResponseField name="time_out" type="string">
      The timestamp when the response was sent on the wire, just prior to transmitting data. Format: RFC3339. Example: `2022-12-25T09:30:59.123456Z`
    </ResponseField>
  </Tab>
</Tabs>

<Panel>
  <CodeGroup>
    ```json Request theme={null}
    {
        "method": "ping",
        "req_id": 101
    }
    ```

    ```json Response theme={null}
    {
        "method": "pong",
        "req_id": 101,
        "time_in": "2023-09-24T14:10:23.799685Z",
        "time_out": "2023-09-24T14:10:23.799703Z"
    }
    ```
  </CodeGroup>
</Panel>
