I have installed Jenkinsapi python module and created below python script.
from jenkinsapi.jenkins import Jenkins
jenkinsSource = 'http://10.52.123.124:8080/'
server = Jenkins(jenkinsSource, username = 'XXXXX', password = 'YYYYY')
myJob=server.get_job("__test")
myConfig=myJob.get_config()
print myConfig
Now I need to parse the XML from the variable myConfig
and fetch the value given for triggers (cron entry) and save it to another variable in python. So that I can replace the cron entry using jenkinsapi module.