Issues Starting Out With Onepassword Connect & Python
Good evening all,
I hope this post reaches you in good health!
I am currently working on automating onepassword secrets via Python. I have the onepassword connector up & running & I can successfully pull information from it via curl as shown on this page. I also have the onepasswordconnectsdk installed via pip. However, when I attempt to test out a write to a vault via a copied & pasted section of code from the "Create Item" section present in the Python SDK documentation I receive an error stating:
NameError: name 'onepasswordconnectsdk' is not defined.
I am not sure why this is - everything looks good on my end & I can even pull vault information with this script, but I cannot create items. The following is the code I am using:
client_from_token: Client = new_client("http://local-ip-removed/", "token-removed")
item = onepasswordconnectsdk.models.Item(vault=ItemVault(id="vault-id-removed"),
Sorry for the code formatting, I was going to stick it in as "code" formatted but that made it all wonky.
1Password Version: Not Provided
Extension Version: Not Provided
OS Version: Not Provided