keepassxc-protocol
Interaction protocol for KeePassXC GUI
(Not tested with Linux, but might work.)
Examples
Get logins:
from keepassxc_protocol import Connection
con = Connection()
con.associate() # Associate request for current ACTIVE database
response = con.get_logins("https://example.test") # Get ALL data for example.test. CAN be specified without http\https.
entry = response.entries[0] # First entry for example.test.
print(entry.group) # Output: "group2"
print(entry.login) # Output: "example_test_login"
print(entry.password) # Output: "example_test_password"
print(entry.name) # Output: "example_test"
print(entry.uuid) # Output: "4cbbe6a7efeb46458c5501e7203209e5"
print(entry.totp) # Output: "579423"
print(response.model_dump_json(indent=2))
# Output:
# {
# "count": 1,
# "nonce": "/r+xzDXU77NPZxA1CvHv/XWGFx2sgqXa",
# "success": "true",
# "hash": "8f1b004cbd837de560b9257b61443f9ae21ee24f4561c87b8f2bb3a6fa7627e0",
# "version": "2.7.10",
# "entries": [
# {
# "group": "group2",
# "login": "example_test_login",
# "name": "example_test",
# "password": "example_test_password",
# "uuid": "4cbbe6a7efeb46458c5501e7203209e5",
# "stringFields": [],
# "totp": "579423"
# }
# ]
# }
Save associates
from keepassxc_protocol import Connection
con = Connection()
con.associate() # Associate request for current ACTIVE database
associates = con.dump_associate_json() # Get ALL associates as json string
with open("associates.json", "w") as f:
f.write(associates)
Load associates
from keepassxc_protocol import Connection
con = Connection()
with open("associates.json", "r") as f:
associates = f.read()
con.load_associates_json(associates) # Load associates from json string.
# This REPLACES the current associates if they exist.
response = con.get_logins("https://example.test") # Get ALL data for example.test.
Features
Actions (link):
- ✅associate
- ✅change-public-keys
- ❌create-new-group
- ❌generate-password
- ✅get-database-gropus
- ✅get-databasehash
- ✅get-logins
- ❎get-totp (deprecated? totp is available in get-logins)
- ❌lock-database
- ❌request-autotype
- ❌set-login
- ✅test-associate
- ❌passkey-get
- ❌passkey-register
Metadata
Release files for keepassxc-protocol 1.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| keepassxc_protocol-1.1.1.tar.gz | 12.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| keepassxc_protocol-1.1.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 29.5 kB
Release files / keepassxc_protocol-1.1.1.tar.gz
| Download URL | keepassxc_protocol-1.1.1.tar.gz |
|---|---|
| Size | 12.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ef715cbb079c9914727ea35452f03c1ba3766966ad0bd86d39ca35dd4b740f54
|
|
BLAKE2b-256 checksum How to use checksums |
31ec1fdf9a9e4defdabe85ccbec2476268faba74e872ec648c1a789928d5096e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.9.22 {"installer":{"name":"uv","version":"0.9.22","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / keepassxc_protocol-1.1.1-py3-none-any.whl
| Download URL | keepassxc_protocol-1.1.1-py3-none-any.whl |
|---|---|
| Size | 16.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
dcfdb2ce547ec327a509ed9968f426284b6a1c352d70d3e3a5165aeb8b813944
|
|
BLAKE2b-256 checksum How to use checksums |
5ffa5f8d254e722006a4fa0c65ffd229ac886686221067a2f7c50c0ceb39c8f1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.9.22 {"installer":{"name":"uv","version":"0.9.22","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|