I want to check and process each messages from client, does it have a callback function for this purpose? thanks.