2023-06-27 11:11:06 -04:00
|
|
|
NIP-34seen
|
|
|
|
==========
|
|
|
|
|
|
|
|
Seen At
|
|
|
|
-------
|
|
|
|
|
|
|
|
`draft` `optional` `author:arthurfranca` `author:mikedilger`
|
|
|
|
|
|
|
|
Events are desc sorted by first seen at timestamp.
|
|
|
|
|
|
|
|
## Motivation
|
|
|
|
|
|
|
|
Some `clients` may want to check if `relay` has recently received old events
|
|
|
|
created before last time they checked.
|
|
|
|
|
|
|
|
## Implementation
|
|
|
|
|
|
|
|
`Relay` computes `nip34seen` field once upon receiving the event.
|
|
|
|
|
|
|
|
The event field is set with the timestamp of the moment the `relay` first became aware of it.
|
|
|
|
|
|
|
|
### Javascript
|
|
|
|
|
|
|
|
```js
|
2023-07-18 15:03:44 -04:00
|
|
|
event.nip34seen = Math.floor(Date.now() / 1000)
|
2023-06-27 11:11:06 -04:00
|
|
|
```
|