以下のコードユーザーが送信/クリックしたすべてのものを取得する方法を示します。
// handle bot's anwser
$input = json_decode(file_get_contents('php://input'), true);
$senderId = $input['entry'][0]['messaging'][0]['sender']['id'];
// gets the text the user sent to you
$messageText = $input['entry'][0]['messaging'][0]['message']['text'];
// gets the payload of the button
$buttonPayLoad = $input['entry'][0]['messaging'][0]['postback']['payload'];
// gets the payload of the quick replay
$quickReplyPayLoad = $input['entry'][0]['messaging'][0]['message']['quick_reply']['payload'];