总之就是762459510
from wxpyimport *
import requests
from datetimeimport datetime
import time
from apscheduler.schedulers.blockingimport BlockingScheduler#定时框架
bot = Bot(cache_path=True)
tuling = Tuling(api_key=你的api’)#机器人api
def send_weather(location):
#准备url地址
path =‘http://api.map.baidu.com/telematics/v3/weather?location=%s&output=json&ak=TueGDhCvwI6fOrQnLM0qmXxY9N0OkOiQ&callback=?’
url = path % location
response = requests.get(url)
result = response.json()
#如果城市错误就按照濮阳发送天气
if result[‘error’] !=0:
location =‘濮阳’
url = path % location
response = requests.get(url)
result = response.json()
str0 = (’ 早上好!这是今天的天气预报!……机器人: