public function body() {
        $event = [];
        if (!empty($this->replyToken)) {
            $event['replyToken'] = $this->replyToken;
        }
        $event['type'] = $this->eventType();
        $event['timestamp'] = time();
        $event['source'] = $this->source;
        $event['message'] = $this->message;
        $result = ['events' => [$event]];
        return json_encode($result);
    }
public function body() {
        $event = [];
        if (!empty($this->replyToken)) {
            $event['replyToken'] = $this->replyToken;
        }
        $event['type'] = $this->eventType();
        $event['timestamp'] = time();
        $event['source'] = $this->source;
        $event['message'] = $this->message;
        $result = ['events' => [$event]];
        return json_encode($result);
    }
public function body ( ) { $ event = [ ] ; if ( ! empty ( $ this -> replyToken ) ) { $ event [ 'replyToken' ] = $ this -> replyToken ; } $ event [ 'type' ] = $ this -> eventType ( ) ; $ event [ 'timestamp' ] = time ( ) ; $ event [ 'source' ] = $ this -> source ; $ event [ 'message' ] = $ this -> message ; $ result = [ 'events' => [ $ event ] ] ; return json_encode ( $ result ) ; }
Build webhook event and return body.
Original webhook request body has this signature.

@return String json encoded body.
Build webhook event and return body . Original webhook request body has this signature .