I'd like to know if there is a way, in python to create a keypass file (.kdbx). With this, I want to fill it with passwords and export it. I tried to juste create a file and use the pykeepass module to fill it but I met errors :
f = open("test.kdbx", "w")
kp = PyKeePass("test.kdbx", "test")
group = kp.add_group(kp.root_group, "test")
kp.add_entry(group, "coucou", "username", "password")
kp.save()
f.close()
(the file is empty)
Do you know a way to fill this file correctly ?

Follow the example in PyKeepass:
Instead of
kp = PyKeePass('db.kdbx', password='somePassw0rd')to load an existing database, usecreate_database()to create a new one: