代码贼大略,一起来看下:
from time import sleepimport requestss = input(\"大众请主人输入话题:\"大众)while True: resp = requests.post(\公众http://www.tuling123.com/openapi/api\"大众,data={\"大众key\公众: \"大众4fede3c4384846b9a7d0456a5e1e2943\"大众, \公众info\公众: s, }) resp = resp.json() sleep(1) print('小鱼:', resp['text']) s = resp['text'] resp = requests.get(\"大众http://api.qingyunke.com/api.php\"大众, {'key': 'free', 'appid': 0, 'msg': s}) resp.encoding = 'utf8' resp = resp.json() sleep(1) print('菲菲:', resp['content'])
这次代码比较少,没截图了,大家赶紧试试吧!
如果你是正在学习Python或者准备学的话,都可以私信我领取一套Python的入门系统教程哈!
(私信的方法是关注后就可以私信了,向我发送资料二字就可以自动回答大家了,比较快捷!
)
