Skip to main content
drupalreleases

Use direct release data with your AI assistant.

Learn more

Nostr Simple Publish

No security coverage Under active development 1 sites

This module allows you to publish content from your Drupal site to the Nostr network. It adds a publishing option to node forms, requiring your Nostr private and public keys and a relay URL for signing and sending posts.

Very simple and opinionated module to publish content to the Nostr network.
More info about Nostr: https://github.com/nostr-protocol/nostr

In case you missed it, when the founder of Drupal Dries Buytaert discovered Nostr it was love on first sight.

Currently only works for a single Drupal user.

Requirements

How it works

Adds a 'Publish to Nostr' fieldset to node forms, protected by the
'publish to nostr network' permission. It currently assumes the content of
your post is stored in the 'body' field, but this can be overridden by a
setting.

Once the node has been sent, you can't publish it anymore. The event id is
stored in the nostr_simple_publish table.

There's an extra permission to view debug information after trying to post to
the network.

Configuration

Posts to the network need to be signed, so we need the public and private key
of your Nostr account and one relay.

// Path to Nostr public and private key files.
// Put these files somewhere outside your webroot!
// The values of the keys are the hex encoded versions, not bech32 (which
// either start with npub or nsec).
// Use https://damus.io/key/ or https://github.com/rot13maxi/key-convertr
// to convert.
$settings['nostr_public_key_file'] = '/path/to/public-key-file';
$settings['nostr_private_key_file'] = '/path/to/private-key-file';

// Nostr relay - find other relays at https://nostr.watch/relays/find.
// This relay seems to work fine. In case you are not connected with this one,
// add it to your relays so posts show up in your client as well.
$settings['nostr_relay'] = 'wss://nostr.pleb.network';

```
// Content fields - defaults to 'body'.
$settings['nostr_content_fields'] = ['field_description'];
```

Roadmap

Generally, it's not the purpose of this module to become a relay or a fully
featured nostr client, hence the name.

Nostr on Drupal Slack

Join the #nostr channel on Drupal Slack to talk to other Drupalists discussing Nostr.
drupal.org/slack

Ask your assistant about Nostr Simple Publish

Check compatibility with your Drupal and PHP version, maintenance and security coverage, from current release data. How it works

Depends on

Dependencies of the latest stable release

No dependencies recorded for this project.

Required by

Tracked projects that depend on this one

No tracked projects depend on this one yet.

Activity

Tracked releases
7
Tracked since
Feb 2023
Latest release
2 years ago
Releases (12 mo)
0
Maintenance
Dormant

Release Timeline

Releases

Version Type Core PHP Release date
1.1.0-alpha1 Pre-release 10–11 Sep 17, 2024
1.0.0-alpha5 Pre-release 9–10 Oct 6, 2023
1.0.0-alpha4 Pre-release 9–10 Mar 6, 2023
1.0.0-alpha3 Pre-release 9–10 Mar 1, 2023
1.0.0-alpha2 Pre-release 9–10 Mar 1, 2023
1.0.0-alpha1 Pre-release 9–10 Feb 26, 2023
1.0.x-dev Dev 10–11 Feb 25, 2023