Event: onEcho

Event is calling two times - when response data is preparing for send and after sender cluster receives response.
Depends on these two situations an argument with context is passed.

In first situation, when response is preparing to be send, receiver will call code below:
/src/SkynetUser/MyListener.php
public function onEcho($context)
{
if($context == "beforeSend")
{
/* code executes in responder when response is preparing to be send */
}
}

Everything you assign to response object above will NOT be send.
Response in echo mode is not returned. You can send data from here via only from SkynetPeer.

In second situation, when response is received by sender code below is executed:
/src/SkynetUser/MyListener.php
public function onEcho($context)
{
if($context == "afterReceive")
{
/* code executes in sender when sender receives response */
}
}

In code above response will be empty.
Full API Documentation is included in Skynet packages available on GitHub.