Skip to content

Getting started

moznion edited this page Feb 18, 2017 · 3 revisions

How to create an API client of bot

$bot = new \LINE\LINEBot(new CurlHTTPClient('your-channel-token'), [
    'channelSecret' => 'your-channel-secret'
]);

Simple replying

$textMessageBuilder = new \LINE\LINEBot\MessageBuilder\TextMessageBuilder('hello');
$response = $bot->replyMessage('your-reply-token', $textMessageBuilder);

Documents

See the official API documentation for more information.

Sample projects

A sample echo bot implementation.

A full-stack LINE Messaging API sample implementation. This sample shows you a practical use of the LINE Messaging API.