我查到的相关API有两套,我主要用的是python-jenkins. https://pypi.python.org/pypi/python-jenkins/ 按语法调用即可... import jenkins server = jenkins.Jenkins('http://1.1.1.1/', username='user', password='pwd') version = server.get_version() # print version def demo(): result =