UMA Auth CLI tool for Client Apps.
Project description
UMA Auth CLI
A simple CLI tool for working with UMA auth. Can help with generating new nostr keys and publishing client app info events.
Installation
To run the CLI from source, you can clone this repository and run:
pipenv install --dev
pipenv run python -m build
pip install dist/*.whl
You can then run the CLI from anywhere:
uma-auth-cli --help
To install the CLI as a package from pypi instead, you can run:
# Note: This is not yet published to pypi.
pip install uma-auth-cli
Usage
Key Generation
To generate a new nostr keypair, run:
uma-auth-cli generate-key
It will create and print a new keypair in hex and bech32 format:
nsec1e792rulwmsjanw783x39r8vcm23c2hwcandwahaw6wh39rfydshqxhfm7x
npub13msd7fakpaqerq036kk0c6pf9effz5nn5yk6nqj4gtwtzr5l6fxq64z8x5
sec hex: cf8aa1f3eedc25d9bbc789a2519d98daa3855dd8ecdaeedfaed3af128d246c2e
pub hex: 8ee0df27b60f419181f1d5acfc68292e52915273a12da9825542dcb10e9fd24c
Publishing client app info
You can publish a client app info (kind 13195 and optionally kind 0) using the CLI. The CLI can publish these events in interactive prompt mode:
$ uma-auth-cli publish \
--nsec nsec1mqxnulkqkcv0gc0dfrxz5kz7d3h665ve2dhjkrj8jmmxwm4st2zsjv2n5l \
--relay wss://nos.lol --relay wss://relay.primal.net \
--redirect-uri https://foo.test \
--image https://foo.com/image.png \
--nip05 _@foo.com \
--include-0 \
--name "Test CLI" \
--description "A test client app"
Looking up client app info
You can look up client app info using the CLI:
$ uma-auth-cli lookup \
--npub npub13msd7fakpaqerq036kk0c6pf9effz5nn5yk6nqj4gtwtzr5l6fxq64z8x5 \
--relay wss://nos.lol
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file uma_auth_cli-0.1.1.tar.gz
.
File metadata
- Download URL: uma_auth_cli-0.1.1.tar.gz
- Upload date:
- Size: 8.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.9.16
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 85c283d5483a8d45c1cd3741157c18bfa7b14b0aa73c6ac3cf4eb65848552f70 |
|
MD5 | 8607e5c4255417403cfb8d571d3e3639 |
|
BLAKE2b-256 | 8f50e0bfbc5e18d4687682b0dc99c0032e691c8f012ef50b02eff5f1245d976e |
File details
Details for the file uma_auth_cli-0.1.1-py3-none-any.whl
.
File metadata
- Download URL: uma_auth_cli-0.1.1-py3-none-any.whl
- Upload date:
- Size: 8.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.9.16
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6b3a83456533f0ddb4405349265d2ba3dbeba252c1e43074cf227d92a8f197fa |
|
MD5 | fea5586bf4cadc37afb83af1ddc8c73a |
|
BLAKE2b-256 | 5a5de15104c0185509a34df16e39aeddee794d5f33259b390e9e476a0c17c1d9 |