Merge pull request #889 from nostr-protocol/nip11-restricted-writes

This commit is contained in:
fiatjaf_ 2023-11-19 11:18:19 -03:00 committed by GitHub
commit ea6d277c7c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

7
11.md
View File

@ -79,6 +79,7 @@ are rejected or fail immediately.
"min_pow_difficulty": 30,
"auth_required": true,
"payment_required": true,
"restricted_writes": true,
"created_at_lower_limit": 31536000,
"created_at_upper_limit": 3
},
@ -124,6 +125,12 @@ Even if set to False, authentication may be required for specific actions.
- `payment_required`: this relay requires payment before a new connection may perform any action.
- `restricted_writes`: this relay requires some kind of condition to be fulfilled in order to
accept events (not necessarily, but including `payment_required` and `min_pow_difficulty`).
This should only be set to `true` when users are expected to know the relay policy before trying
to write to it -- like belonging to a special pubkey-based whitelist or writing only events of
a specific niche kind or content. Normal anti-spam heuristics, for example, do not qualify.
- `created_at_lower_limit`: 'created_at' lower limit as defined in [NIP-22](22.md)
- `created_at_upper_limit`: 'created_at' upper limit as defined in [NIP-22](22.md)