Skip to content

LinYuMingBejing/CONNIX

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Line Bot Message API

Set Up Line Bot configuration

export LINE_BOT_CHANNEL_TOKEN=YOUR_LINE_BOT_CHANNEL_TOKEN
export LINE_BOT_CHANNEL_SECRET=YOUR_LINE_BOT_CHANNEL_SECRET
  • Generate a https endpoint with ngrok
ngrok http 8081

  • Replace webhook settings with the above result

  • Run MongoDB with Docker

docker run --name mongo -d -p 27017:27017 --rm mongo
  • NOW, You can start Spring Boot project

How to test Line Bot Related API?

LINE Bot Account(Scan following QR Code)

Chat with LINE BOT[If you want to reply yourself, you can use the following response API]

  • LINE Bot Reply API:
curl -X POST http://localhot:8080/message  \
     -H "Content-Type: application/json" \
     -d '{"userId":"userId", "text":"Hello"}'
  • Response
{"statusCode":200,"data":null}
  • User Query API:
curl -X POST http://localhot:8080/message/U782sdsdsdea59f9f9f7ecde11cb1a010e
  • Response
{"statusCode":200,"data":["Amy","Eric","Andy","Jolin"]}

TODO

  • Get reply token from API due to expiration policy
  • Support message response with multi-line

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages