__author__ = "byStarTW"
import telepot # pip install telepot
bot = telepot.Bot('(bot_token)') # bot token
def sendMessage(chat_id, message):
bot.sendMessage(chat_id, message)
def sendMessage_markdown(chat_id, message):
bot.sendMessage(chat_id, message, 'markdown')
chat_id = str('(chat_id)') # chat_id
# Main Menu
print ("\n\n")
msgMode = input("請輸入輸出文字模式 (一般文字 [請輸入: default] / Markdown): ")
if msgMode == "default":
msgMode = "False"
elif msgMode == "Markdown":
msgMode = "True"
else:
exit()
msgText = input("請輸入輸出的文字: ")
if msgMode == "False":
sendMessage(chat_id, msgText)
elif msgMode == "True":
sendMessage_markdown(chatid, msgText)
else:
exit()