Set callbacks for server

Set callbacks for the server