11 lines
367 B
Python
11 lines
367 B
Python
from app.utils.token_store import ApiKeyStore
|
|
|
|
store = ApiKeyStore("data/api_tokens.yaml")
|
|
# res = store.mint(label="local dev")
|
|
# print("NEW TOKEN (save this now):")
|
|
# print(res) # {"id": "...uuid...", "token": "...plaintext..."}
|
|
|
|
print("List keys (no hashes):")
|
|
print(store.list(include_inactive=True))
|
|
|
|
# print("Verify works?", store.verify(res["token"])) # True |