vmware-archive / pyvcloud

Python SDK for VMware vCloud Director
https://vmware.github.io/pyvcloud
Other
170 stars 189 forks source link

How to use bearer token to login to the Client? #802

Open marcusnh opened 1 year ago

marcusnh commented 1 year ago

Is your feature request related to a problem? Please describe.

I want to use an access token for the pyvcloud.vcd.client when I connect to VCD. Is this possible?

Describe the solution you'd like

client = Client(secrets['sc2_url'], verify_ssl_certs=True, log_file='pyvcloud.log', log_requests=True, log_headers=True, log_bodies=True) client.set_highest_supported_version() client.set_credentials(AccesTokenLogin(secrets['sc2_username'], secrets['sc2_org'], secrets['sc2_api_token']))

Describe alternatives you've considered

No response

Additional context

No response