Skip to main content

Python CLI for Nostr

Project description

nostrpy

CI/CD codecov CircleCI

CLI for Nostr

Installation

 pip install nostrpy

Usage

Show nostr version

 nostr --version
nostr, version 0.3.1

Generate a key pair

 nostr key create
Private key: nsec18ty...2xz6
Public key: npub1rak...58cm

Transform a public key to hex format

 nostr key npub-to-hex --pub-key npub1rak...58cm
npub: npub1rak...58cm
hex: 1f6cada4...449d

Publish a message

 nostr message publish -s <the sender nsec key> -m "Hello, publishing a message through nostr CLI."

Send an encryped direct message

 nostr message send -s <the sender nsec key> -m "Hello, sending an encryped direct message" -p <the receiver npub key>

Receive message(s)

❯ nostr message receive -p <the npub key to receive the messages>
Hello, publishing a message through nostr CLI.
...

Development & Test

See the Test Suite README

Feel free to add issues, add PRs, or provide any feedback!

Credits

Repositories:

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

nostrpy-0.3.1.tar.gz (29.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

nostrpy-0.3.1-py3-none-any.whl (21.1 kB view details)

Uploaded Python 3

File details

Details for the file nostrpy-0.3.1.tar.gz.

File metadata

  • Download URL: nostrpy-0.3.1.tar.gz
  • Upload date:
  • Size: 29.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.16

File hashes

Hashes for nostrpy-0.3.1.tar.gz
Algorithm Hash digest
SHA256 a8628544db2f255c942e4952fd996a1d17fc7d5946eb395285e0d80e7be71803
MD5 9e0c7af07244ae5db4dd9fd6cafd0377
BLAKE2b-256 f5948f231e5f9fbd75b16dba4fd361fb93b9842f7a7c5d5154ae684eccf5f3fd

See more details on using hashes here.

File details

Details for the file nostrpy-0.3.1-py3-none-any.whl.

File metadata

  • Download URL: nostrpy-0.3.1-py3-none-any.whl
  • Upload date:
  • Size: 21.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.16

File hashes

Hashes for nostrpy-0.3.1-py3-none-any.whl
Algorithm Hash digest
SHA256 a1df5f1e9196926f99982cbdf78c7c48970111f333a8deec2ab2c704b25688d3
MD5 a12c5edca1107a59d4bd1a791db3f164
BLAKE2b-256 5359e63dcbb5cc96f302612a0295be4927563d00e5228d23f64286592af2350a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page