mirror of
https://github.com/nostr-protocol/nips.git
synced 2024-12-22 08:25:53 -05:00
📝 Updated NIP
This commit is contained in:
parent
1bbae4d66b
commit
a8caa03373
13
40.md
13
40.md
|
@ -6,14 +6,15 @@ Expiration Timestamp
|
|||
|
||||
`draft` `optional` `author:0xtlt`
|
||||
|
||||
The `expiration` tag enables users to specify a timestamp at which the message should be considered expired and deleted by relays. This helps ensure that messages are not retained by the network after they are no longer relevant, which helps maintain the privacy of the messages. This is especially useful in cases where a replacement event is not available or feasible.
|
||||
The `expiration` tag enables users to specify a timestamp at UTC-0 at which the message should be considered expired and deleted by relays (or just ignored by clients). This can be useful for making temporary announcements, making limited-time offers, or sending ephemeral messages but should not be seen as a security solution for the content of your messages.
|
||||
So be careful when sharing confidential information.
|
||||
|
||||
#### Spec
|
||||
|
||||
```
|
||||
tag: expiration
|
||||
options:
|
||||
- [timestamp]: required
|
||||
- [timestamp UTC-0]: required
|
||||
```
|
||||
|
||||
#### Example
|
||||
|
@ -38,9 +39,15 @@ Client Behavior
|
|||
|
||||
Clients SHOULD use the `supported_nips` field to learn if a relay supports this NIP. Clients SHOULD NOT send expiration events to relays that do not support this NIP.
|
||||
|
||||
Clients MUST ignore events that have expired.
|
||||
|
||||
Suggested Use Cases
|
||||
-------------------
|
||||
|
||||
* Temporary announcements - This tag can be used to make temporary announcements that are automatically deleted from the network after a certain amount of time. For example, an event organizer could use this tag to post announcements about an upcoming event, and the announcements will be automatically deleted once the event is over.
|
||||
* Limited-time offers - This tag can be used by businesses to make limited-time offers that expire after a certain amount of time. For example, a business could use this tag to make a special offer that is only available for a limited time, and the offer will be automatically deleted from the network once the time has passed.
|
||||
* Ephemeral messages - This tag can be used by individuals to send ephemeral messages that are automatically deleted from the network after a certain amount of time. For example, someone could use this tag to send a message that is only visible to the recipient for a short time, and the message will be automatically deleted once the time has passed. This can be useful for sending sensitive information that should not be retained on the network indefinitely.
|
||||
* Ephemeral messages - This tag can be used by individuals to send ephemeral messages that are automatically deleted from the network after a certain amount of time. For example, someone could use this tag to send a message that is only visible to the recipient for a short time, and the message will be automatically deleted by relays or/and ignored by clients once the time has passed. This can be useful for sensitive information that should not be retained on the network indefinitely.
|
||||
|
||||
#### One last time, be careful!
|
||||
The events could be downloaded by third parties as they are publicly accessible all the time on the relays.
|
||||
So don't consider ephemeral messages as a security for your conversations or other uses.
|
||||
|
|
Loading…
Reference in New Issue
Block a user