-
8 年前
Python requests 模块快速上手
Shell/Python requests
参考文档 模块安装 pip install request 快速上手,首先要 import requests 发送无参数的get请求 s_ipv4_api = 'http://myops.imdst.com/api/public_ipv4' r = requests.get(s_ipv4_api) print r.text 发送带参数的get请求 test_url = "http://…
参考文档 模块安装 pip install request 快速上手,首先要 import requests 发送无参数的get请求 s_ipv4_api = 'http://myops.imdst.com/api/public_ipv4' r = requests.get(s_ipv4_api) print r.text 发送带参数的get请求 test_url = "http://…