Q&A

Set Schedule in line-bot-sdk-python

Now , I am trying to code Line Bot with Python by using line-bot-sdk-python , and now i'm confusing about set time to release the message at 6pm everyday

I want to know how to set schedule.

(Sorry for bad grammar)

  • 0
  • 2
  • 1654
  • twitter facebook

Hi Chinnated, I don't know whether the Python SDK itself has the feature for schedule or not but you can do it with schedule module like below:

schedule.every().day.at("18:00").do(send_messages)

Note that the time the job will be processed depends on the localtime of the runtime environment.

See also https://schedule.readthedocs.io/en/stable/

  • 0

Scheduling feature is not supported in line-bot-sdk-python. but you can implement a scheduled message with pure python library like https://github.com/dbader/schedule.

  • 0
Are you sure? question.vm