nips/78.md

38 lines
2.1 KiB
Markdown
Raw Normal View History

2023-02-23 16:25:55 -05:00
NIP-78
======
Arbitrary custom app data
-------------------------
2023-11-15 19:42:51 -05:00
`draft` `optional`
2023-02-23 16:25:55 -05:00
2024-01-24 03:28:27 -05:00
This NIP defines some events that do not require interoperability.
The common points are the following two points, and the difference is the kind.
- With a `d` tag containing some reference to the app name and context -- or any other arbitrary string.
- `content` and other `tags` can be anything or in any format.
### Event `30078`: remoteStorage-like event
The goal of this kind is to enable [remoteStorage](https://remotestorage.io/)-like capabilities for custom applications that do not care about interoperability.
2023-02-23 16:25:55 -05:00
2023-04-07 08:08:03 -04:00
Even though interoperability is great, some apps do not want or do not need interoperability, and it wouldn't make sense for them. Yet Nostr can still serve as a generalized data storage for these apps in a "bring your own database" way, for example: a user would open an app and somehow input their preferred relay for storage, which would then enable these apps to store application-specific data there.
2023-02-23 16:25:55 -05:00
2024-01-24 03:28:27 -05:00
**Nostr event**:
2023-02-23 16:25:55 -05:00
This NIP specifies the use of event kind `30078` (parameterized replaceable event) with a `d` tag containing some reference to the app name and context -- or any other arbitrary string. `content` and other `tags` can be anything or in any format.
2024-01-24 03:28:27 -05:00
**Some use cases**:
2023-02-23 16:25:55 -05:00
- User personal settings on Nostr clients (and other apps unrelated to Nostr)
- A way for client developers to propagate dynamic parameters to users without these having to update
- Personal private data generated by apps that have nothing to do with Nostr, but allow users to use Nostr relays as their personal database
2024-01-24 03:28:27 -05:00
### Event `78`: Versatile event
When creating Nostr-based applications, suggesting a new kinds each time can be burdensome for developers. For purposes like testing or for applications that do not require interoperability, it is acceptable to use the defined event here.
**Nostr event**:
This NIP specifies the use of event kind `78` with a `d` tag containing some reference to the app name and context -- or any other arbitrary string. `content` and other `tags` can be anything or in any format.