Coder Social home page Coder Social logo

line-icon-switch-python's Introduction

LINE Icon Switch API sample

LINE new API - Icon Switch: this API can change icon and display name in same LINE BOT

Trigger text

This bot will catch trigger text to change name and avatar !!๐ŸŽ‰

  • Sally
  • Brown
  • Cony

Developer Side

LINE account

  • Got A LINE Bot API devloper account Make sure you already registered, if you need use LINE Bot.

  • Go to LINE Developer Console

    • Close auto-reply setting on "Messaging API" Tab.
    • Setup your basic account information. Here is some info you will need to know.
      • Callback URL: https://{NGROK_URL}/webhooks/line
      • Verify your webhook.
  • You will get following info, need fill back to .env file.

    • Channel Secret
    • Channel Access Token (You need to issue one here)

Normal testing

  1. first terminal window
pip install -r requirements.txt --user
python api.py

[2020/03/28] LINE just not already release tag in SDK, so I use git method to install NEW feature package(icon switch).

  1. Create a provisional Https:
ngrok http 5000

or maybe you have npm enviroment:

npx ngrok http 5000

  1. Copy url to LINE Developer Console

If you have AWS account

  1. Install serverless via npm:
$ npm install -g serverless
  1. Setup your AWS ceritficate
export AWS_ACCESS_KEY_ID=<your-key-here>
export AWS_SECRET_ACCESS_KEY=<your-secret-key-here>
  1. Deploy the example:
npm install
pip install -r requirements.txt --user
serverless wsgi serve # local testing
serverless deploy     # deploy to AWS
  1. If deploy, copy the url to LINE Developer Console

License

MIT License

line-icon-switch-python's People

Contributors

louis70109 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.