pycontribs / jenkinsapi

A Python API for accessing resources and configuring Hudson & Jenkins continuous-integration servers
http://pypi.python.org/pypi/jenkinsapi
MIT License
858 stars 485 forks source link

Cannot add credentials #729

Closed piyushpriyam closed 5 years ago

piyushpriyam commented 5 years ago

Got response [403] in post_and_confirm_status

while

credJson = { 'description' : description, 'username' : username, 'password' : password, 'credential_id':credential_id, 'typeName': typeName }

server.credentials.__setitem__(description,server.credentials._make_credential(credJson))

Please also provide an working example.

lechat commented 5 years ago

Examples are here: https://github.com/pycontribs/jenkinsapi/blob/master/jenkinsapi_tests/systests/test_credentials.py

piyushpriyam commented 5 years ago

Thanks man, I used crumb, it solve the issue