Skip to main content

Nostr protocol implementation

Project description

Nostr - Python Package

Description

Python bindings of nostr library.

If you're writing a typical Nostr client or bot, you may be interested in nostr-sdk.

Getting started

pip install nostr-protocol
from nostr_protocol import Keys, EventBuilder

keys = Keys.generate()
print(keys.secret_key().to_bech32())
print(keys.public_key().to_bech32())

print("Mining a POW text note...")
event = EventBuilder.text_note("Hello from Rust Nostr Python bindings!", []).to_pow_event(keys, 20)
print(event.as_json())

More examples can be found in the examples/ directory.

Supported NIPs

Look at https://github.com/rust-nostr/nostr/tree/master/crates/nostr#supported-nips

Book

Learn more about rust-nostr at https://rust-nostr.org.

State

This library is in an ALPHA state, things that are implemented generally work but the API will change in breaking ways.

Donations

rust-nostr is free and open-source. This means we do not earn any revenue by selling it. Instead, we rely on your financial support. If you actively use any of the rust-nostr libs/software/services, then please donate.

License

This project is distributed under the MIT software license - see the LICENSE file for details

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

nostr_protocol-0.35.0-cp312-cp312-win_amd64.whl (3.2 MB view details)

Uploaded CPython 3.12 Windows x86-64

nostr_protocol-0.35.0-cp312-cp312-manylinux_2_31_aarch64.whl (3.6 MB view details)

Uploaded CPython 3.12 manylinux: glibc 2.31+ ARM64

nostr_protocol-0.35.0-cp312-cp312-manylinux_2_28_x86_64.whl (3.7 MB view details)

Uploaded CPython 3.12 manylinux: glibc 2.28+ x86-64

nostr_protocol-0.35.0-cp312-cp312-macosx_11_0_x86_64.whl (3.6 MB view details)

Uploaded CPython 3.12 macOS 11.0+ x86-64

nostr_protocol-0.35.0-cp312-cp312-macosx_11_0_arm64.whl (3.4 MB view details)

Uploaded CPython 3.12 macOS 11.0+ ARM64

nostr_protocol-0.35.0-cp311-cp311-win_amd64.whl (3.2 MB view details)

Uploaded CPython 3.11 Windows x86-64

nostr_protocol-0.35.0-cp311-cp311-manylinux_2_31_aarch64.whl (3.6 MB view details)

Uploaded CPython 3.11 manylinux: glibc 2.31+ ARM64

nostr_protocol-0.35.0-cp311-cp311-manylinux_2_28_x86_64.whl (3.7 MB view details)

Uploaded CPython 3.11 manylinux: glibc 2.28+ x86-64

nostr_protocol-0.35.0-cp311-cp311-macosx_11_0_x86_64.whl (3.6 MB view details)

Uploaded CPython 3.11 macOS 11.0+ x86-64

nostr_protocol-0.35.0-cp311-cp311-macosx_11_0_arm64.whl (3.4 MB view details)

Uploaded CPython 3.11 macOS 11.0+ ARM64

nostr_protocol-0.35.0-cp310-cp310-win_amd64.whl (3.2 MB view details)

Uploaded CPython 3.10 Windows x86-64

nostr_protocol-0.35.0-cp310-cp310-manylinux_2_31_aarch64.whl (3.6 MB view details)

Uploaded CPython 3.10 manylinux: glibc 2.31+ ARM64

nostr_protocol-0.35.0-cp310-cp310-manylinux_2_28_x86_64.whl (3.7 MB view details)

Uploaded CPython 3.10 manylinux: glibc 2.28+ x86-64

nostr_protocol-0.35.0-cp310-cp310-macosx_11_0_x86_64.whl (3.6 MB view details)

Uploaded CPython 3.10 macOS 11.0+ x86-64

nostr_protocol-0.35.0-cp310-cp310-macosx_11_0_arm64.whl (3.4 MB view details)

Uploaded CPython 3.10 macOS 11.0+ ARM64

nostr_protocol-0.35.0-cp39-cp39-win_amd64.whl (3.2 MB view details)

Uploaded CPython 3.9 Windows x86-64

nostr_protocol-0.35.0-cp39-cp39-manylinux_2_31_aarch64.whl (3.6 MB view details)

Uploaded CPython 3.9 manylinux: glibc 2.31+ ARM64

nostr_protocol-0.35.0-cp39-cp39-manylinux_2_28_x86_64.whl (3.7 MB view details)

Uploaded CPython 3.9 manylinux: glibc 2.28+ x86-64

nostr_protocol-0.35.0-cp39-cp39-macosx_11_0_x86_64.whl (3.6 MB view details)

Uploaded CPython 3.9 macOS 11.0+ x86-64

nostr_protocol-0.35.0-cp39-cp39-macosx_11_0_arm64.whl (3.4 MB view details)

Uploaded CPython 3.9 macOS 11.0+ ARM64

File details

Details for the file nostr_protocol-0.35.0-cp312-cp312-win_amd64.whl.

File metadata

File hashes

Hashes for nostr_protocol-0.35.0-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 0e50b6384b6b872902e7429d0a76d27994cbd41b649df451d2b100fcfbf7fab0
MD5 c8e5e878d6909c084d6a5b53463c6650
BLAKE2b-256 cbe42d1dcdf5c585dba7a7b59c212d1e0d53e01424ce519cf7691a96aec8d549

See more details on using hashes here.

File details

Details for the file nostr_protocol-0.35.0-cp312-cp312-manylinux_2_31_aarch64.whl.

File metadata

File hashes

Hashes for nostr_protocol-0.35.0-cp312-cp312-manylinux_2_31_aarch64.whl
Algorithm Hash digest
SHA256 5e73c63a9349741f285ce3d7971994dc71a7c4f61588046e23e6ce8905a2b81b
MD5 b1e93a03eb2c9e5b969ce6c858f19a2f
BLAKE2b-256 8547e918339b6f47e6e837da044c497f7aab407c4000ff5b12d5032413ac1533

See more details on using hashes here.

File details

Details for the file nostr_protocol-0.35.0-cp312-cp312-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for nostr_protocol-0.35.0-cp312-cp312-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 228d9ba27999ad79ca5acd4db69e50dbf480172d0a2430ab166876b8084c53a6
MD5 a8f5043a811c362ac2ecbb1bb955d235
BLAKE2b-256 bf8abbc313ff66b6325680f0ed1b9d9e4097dea7a7bd6e3038a53b7b02a54232

See more details on using hashes here.

File details

Details for the file nostr_protocol-0.35.0-cp312-cp312-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for nostr_protocol-0.35.0-cp312-cp312-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 60df92506cda2de6a0649da6c402b9828b54e802bb32c7203acf85906a7d12f1
MD5 412499f05eb60363187cf9f450cf3804
BLAKE2b-256 2cbc7a8321be081e138f79dc20f92cb306c814abbd147786144a741b772855af

See more details on using hashes here.

File details

Details for the file nostr_protocol-0.35.0-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for nostr_protocol-0.35.0-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 2c58915f5ad80c4f32a2a1c49ce5496a7cd30a4c89db74da87d99e3cbdcfa8c9
MD5 d79922e74c6281bc00291218dad1f4fa
BLAKE2b-256 cbbebe8e9f01c84186452dac7dbd85bec26aa8724016c22beb350fa79c38531b

See more details on using hashes here.

File details

Details for the file nostr_protocol-0.35.0-cp311-cp311-win_amd64.whl.

File metadata

File hashes

Hashes for nostr_protocol-0.35.0-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 25adc60812b8dc687f3216e50d9aff9dcd9a50e4d6be2aaed62d6441074644ba
MD5 1b4742457f4e82056a2ddbfdbd7911e1
BLAKE2b-256 23de2b0c0799c4bb3da6e16af5d9b623f4f920aa9d71dbb6b2c622a47772bc26

See more details on using hashes here.

File details

Details for the file nostr_protocol-0.35.0-cp311-cp311-manylinux_2_31_aarch64.whl.

File metadata

File hashes

Hashes for nostr_protocol-0.35.0-cp311-cp311-manylinux_2_31_aarch64.whl
Algorithm Hash digest
SHA256 6f6781463a01689f456da4bfb025c0d9dd6c38b8d961290b62f5c0493d256721
MD5 a3eaf5ba55750789889552918bc81a3e
BLAKE2b-256 162c15be9f1cc23c98b096795fd243138fb3d42edd2ca93fc73bb78438facac9

See more details on using hashes here.

File details

Details for the file nostr_protocol-0.35.0-cp311-cp311-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for nostr_protocol-0.35.0-cp311-cp311-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 b7292272ae4c4a533f4eeea669241d1c18fb46c134253d9a026b274d43060762
MD5 165b3b2e321907adb91563632719a161
BLAKE2b-256 eafa4d2b2437ab7285e9161576ca415f795e46a7b73dbf75db4a9c90ebb58112

See more details on using hashes here.

File details

Details for the file nostr_protocol-0.35.0-cp311-cp311-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for nostr_protocol-0.35.0-cp311-cp311-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 6252c25d4454a38484f28fdcc6f4627074c9d1b95f9373447ccdbdc10fd4edae
MD5 5bd667e47e3c2bfe42ab150afc11957e
BLAKE2b-256 053c6899cd818bc0b1306bcba7a7f19900e9be5a1a68911b5cf6a58a89b22442

See more details on using hashes here.

File details

Details for the file nostr_protocol-0.35.0-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for nostr_protocol-0.35.0-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 0a383fff32bfd57e2f6b62e7c15796b60d503e70963606ac7ac4148a50da772b
MD5 396e4feaa0bb8853018df8c5b74c9c9b
BLAKE2b-256 a812baa7ed8dd89a984c1a6a34e916d1a79298a52dad36fc7df7ff87dc16d348

See more details on using hashes here.

File details

Details for the file nostr_protocol-0.35.0-cp310-cp310-win_amd64.whl.

File metadata

File hashes

Hashes for nostr_protocol-0.35.0-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 6b804e5ed702a416d0adef947b41d76c5aadbaa58baba93b3ea3f9bc10bc6965
MD5 d445f05f1955b292321229ec8a981ca8
BLAKE2b-256 96c53372fe8d652fa2ebc64b6e26df60b13ad79356a53803c5d627d14cd4cbce

See more details on using hashes here.

File details

Details for the file nostr_protocol-0.35.0-cp310-cp310-manylinux_2_31_aarch64.whl.

File metadata

File hashes

Hashes for nostr_protocol-0.35.0-cp310-cp310-manylinux_2_31_aarch64.whl
Algorithm Hash digest
SHA256 499f12c4c998877ef0fe09fa3e1fe3c7c22792f9ddb503e70f1780cd34a0f14e
MD5 848dc16cec8fd789077ea20ef57a41fa
BLAKE2b-256 2f26b575908df52ecb43e57e7e714b7492254019bb8693a47ed470e0c40501e5

See more details on using hashes here.

File details

Details for the file nostr_protocol-0.35.0-cp310-cp310-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for nostr_protocol-0.35.0-cp310-cp310-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 7697adf9730cebfdc573493de5a78e5c80d525bcd362f162901700c49ab2b436
MD5 bb5c3dcfa51e60ddaabf3ab9af6c2664
BLAKE2b-256 23fd1aa4dbbf6734dbc6e5cbba9f2e9c8c04523571c8386853c0d0c2b72ac1b7

See more details on using hashes here.

File details

Details for the file nostr_protocol-0.35.0-cp310-cp310-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for nostr_protocol-0.35.0-cp310-cp310-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 8081b37f43fa46a7a149a539527c271c7778887a6125864273879541c20cbb3a
MD5 cebc67a0fbfb876d11dbb59391d164b8
BLAKE2b-256 fb3b7ab6ee191090248bdf3517472507b9274adb24b827dfcb72db1ee7bf192d

See more details on using hashes here.

File details

Details for the file nostr_protocol-0.35.0-cp310-cp310-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for nostr_protocol-0.35.0-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 0cec2e1887e23242f21a6d2cf90f93db4706b8df01e0d3eb8a9fb652cf4f19de
MD5 4b12f7a535c132bdf0a33afbda56ee07
BLAKE2b-256 0732cf34f9585ede4785e0b179cdee5b4293e18349264a550b88d9443486a12e

See more details on using hashes here.

File details

Details for the file nostr_protocol-0.35.0-cp39-cp39-win_amd64.whl.

File metadata

File hashes

Hashes for nostr_protocol-0.35.0-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 99b119d6325d74535aff017025a95423e061c609a5f844b5174ab341d46d84e7
MD5 ef7edfc5f87de2b49c67edcfc433adb0
BLAKE2b-256 92ef7ec9d14e6ee825f55a89c7a9d191cd6b7ab78ef1558022d8c340ad8cc82b

See more details on using hashes here.

File details

Details for the file nostr_protocol-0.35.0-cp39-cp39-manylinux_2_31_aarch64.whl.

File metadata

File hashes

Hashes for nostr_protocol-0.35.0-cp39-cp39-manylinux_2_31_aarch64.whl
Algorithm Hash digest
SHA256 47624c174de3c7580e14b8ad7724b446a21153a24dc6b13ac006a20c9450312a
MD5 9f32afb1d98708910d21e8afba357d48
BLAKE2b-256 4e767d3a83002a5dfadd0a4dcc7afc7532dc2275611cb200fd0d6b0d555e7b49

See more details on using hashes here.

File details

Details for the file nostr_protocol-0.35.0-cp39-cp39-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for nostr_protocol-0.35.0-cp39-cp39-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 5429af26d270cbe632d02fc207c37083a9476a2e5cd90e0df84ce4009680f807
MD5 52379155d252473f1d2599bdb703dad0
BLAKE2b-256 5b8904ba773b136361e1a50b7f37ba361d5811283bf34a4a6b9de127743900da

See more details on using hashes here.

File details

Details for the file nostr_protocol-0.35.0-cp39-cp39-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for nostr_protocol-0.35.0-cp39-cp39-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 4ad8e8fbcfca5d58ce376f00412644b084b7cf6047cd469720ac934686f31a75
MD5 cb6887ac01066af62ef8f23692967437
BLAKE2b-256 77641db9b3943969b9154fb09966d16dfd32572049057da514216a89765715a1

See more details on using hashes here.

File details

Details for the file nostr_protocol-0.35.0-cp39-cp39-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for nostr_protocol-0.35.0-cp39-cp39-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 6ea59c222ff28f5eb138afd8e8b1cfb55dfa5c21360b7c5f26fc6fb2cc3789a2
MD5 17cce321d7129cb31f0711ad4bb3d83f
BLAKE2b-256 20ef2d1ab00f3d179400c512bfff57c69bd8b91b5deb2e419f491b610cdf4a31

See more details on using hashes here.

Supported by

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