corpusops / bitwardentools

bitwarden python api client and additional tools like for migrating from vaultier to bitwarden (bitwarden_rs)
Other
35 stars 15 forks source link

Edit the cipher username and password. Is it possible? #24

Open maciej-rek opened 9 months ago

maciej-rek commented 9 months ago

Hi, I'm trying to edit the username but I have no idea what I'm doing wrong. I looked at the test_client.py code and I read a closed issue on this topic. Successfully edited the note, but I can't edit the username and password. I've been struggling with it for 2 days.

WORKING GREAT

secitem = client.search_objects({"name": 'sv_admin'}, sync=True)[0]
client.edit_item(secitem, notes="its test only")

DON'T WORK

secitem = client.search_objects({"name": 'sv_admin'}, sync=True)[0]
client.edit_login(secitem, username="svroot")
client.edit_login(secitem, password="qwe321")

Additionally, could you tell me how I can delete the collection? Removing ciphers works great, but when I want to delete the collection, the script does not show any error, but the collection is not deleted. I tried to do it the same way as deleting the cipher.

secitem = client.search_objects({"name": 'COLLECTION2'}, sync=True)[0]
client.delete(secitem)

Thank you! :)