This is a Python 3.9+ implementation of a nostr relay.
Features
- Stores data in LMDB, SQLite or Postgresql. See Storage
- Scalable to thousands of concurrent clients
- Dynamic allow/deny lists
- Configurable garbage collector
- Configurable event validators
- Full-text indexing
- Can serve as a NIP-05 identity provider
- Support for NIP-42 authentication
- Support for rate-limiting
- Supports more NIPs than any other relay implementation:
- NIP-01 – basic protocol
- NIP-02 – contact lists
- NIP-05 – verifying identity
- NIP-09 – deletion events
- NIP-11 – relay metadata
- NIP-12 – generic tags
- NIP-15 – EOSE
- NIP-20 – command results
- NIP-26 – delegated events
- NIP-33 – parameterized replaceable events
- NIP-40 – expiration events
- NIP-42 – authentication
- NIP-50 – full-text search
- NIP-65 – Relay lists
- Pluggable features, allowing you to use nostr_relay as a library for your own custom implementation
Installation
pip install nostr-relay
To run:
nostr-relay serve
to change the location of the database and other settings, create a yaml config file that looks like this:
and run with nostr-relay -c /path/to/config.yaml serve
Then add ws://127.0.0.1:6969 to your relay list.
(obviously, in production you should use a TLS certificate)
Visit the nostr-relay fossil repository for more information.
Metadata
Release files for nostr-relay 1.14
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| nostr_relay-1.14.tar.gz | 79.2 kB | Without provenance | Details for nostr_relay-1.14.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| nostr_relay-1.14-py3-none-any.whl | Python 3 | none | any | Details for nostr_relay-1.14-py3-none-any.whl |
Total release size: 140.9 kB
Release files / nostr_relay-1.14.tar.gz
| Download URL | nostr_relay-1.14.tar.gz |
|---|---|
| Size | 79.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
0a0f4b663c510170714b67a8bc6b52a8d685b95549c00ca98f1dfa5d68c53b27
|
|
BLAKE2b-256 checksum How to use checksums |
97ec4edd2e504957337e5ba3e0e73084f95926137e9bbfe0c312cae9e2bb52b2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.11.9
|
Release files / nostr_relay-1.14-py3-none-any.whl
| Download URL | nostr_relay-1.14-py3-none-any.whl |
|---|---|
| Size | 61.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
a4f401a0ae2d794298ec95623961bac6bc78e47dbc7e19a2ea71317ca338e117
|
|
BLAKE2b-256 checksum How to use checksums |
6cc7bad749422840bb5c3287ef19ceb45d83ec4106044abd58476a231e2c83f2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.11.9
|
Security for nostr-relay 1.14
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.