API Keychain
Purpose
The API Keychain is designed to be a single management tool for developers to easily create, maintain, and use their various API keys. Many developers work on a variety of projects, many of which require an API key to one service or another. After dealing with even just a few of these keys, it can get frustrating or even overwhelming to manage them, hence this tool.
Usage
Console Commands
api-keychain init
$ api-keychain init <filename>
The init command creates a new database with the given filename. If a file already exists, it will stop the program and alert you, to avoid overwriting existing keys.
versionadded: 0.4.0
api-keychain store
$ api-keychain store <filename> <application> <key> [expiration] [userdata]
Use api-keychain store to save a given key to the database. The database name, application name, and key are required, however an expiration date or custom data are optional. Custom data must be provided in a {key: item} dictionary format.
versionadded: 0.2.0
api-keychain retrieve
$ api-keychain retrieve <filename> <application>
Retrieve a key from the keychain and output it in plaintext. Useful for recovering a key to view/verify.
versionadded: 0.2.0
Accessing the keychain programamtically
The API Keychain is primarily designed for easy access to your keys within other software.
api-keychain.api-retrieve
The most common use for programmatic access will be to automatically retrieve your key from the keychain using a single command.
- Import api-retrieve using:
from api-keychain import api-retrieve as your-own-name-here
- Call the command in your module
key = api-retrieve(application, password, filename)
# application: name of the application the key is stored under
# password: the keychain password which will be verified
# filename: name of the keychain file
- The keychain will return your key in plaintext, for use as you see fit.
'versionadded: 0.1.0'
Reference
api-keychain keeps a detailed changelog, as well as an in-depth API Reference for reference.
License
This software is licensed under the GNU GPL 3.0 license
Contributions
Contributions are welcome for the project, whether it be code contributions, corrections, or bug/issue/suggestion reports. See our contribution guidelines!
Metadata
Release files for api-keychain 0.6.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| api_keychain-0.6.1-py3-none-any.whl | Python 3 | none | any | Details for api_keychain-0.6.1-py3-none-any.whl |
Release files / api_keychain-0.6.1-py3-none-any.whl
| Download URL | api_keychain-0.6.1-py3-none-any.whl |
|---|---|
| Size | 6.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
ecb2bdca7314d9d826c7291f7dc6fcd6349894fab07283113f17ebf21df4e93b
|
|
BLAKE2b-256 checksum How to use checksums |
c61055c6b816c7ec4e789e96a9ed87a6288907b0f0bee81c524ffe354b409047
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.1.7 CPython/3.9.5 Linux/5.8.0-1039-azure
|
Security for api-keychain 0.6.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.