30817:key-value-mappings
Key-Value Mappings
covers31994
- signed by
- npub1kg4sd...quw5te
- published
- 2026-03-03
- event
- 0ec49ff327...3765
NIP-XX: Shortener
draft optional
Abstract
This NIP defines a standard for mapping a short string to any string value.
Structure
{
"kind": 31994,
"tags": [
["d", "<key>"],
["type", "<type>"]
],
"content": "<value>"
}
d: the short keytype: how the value should be interpreted (url,text,json)content: the value
URL Format
/{key}/{author}
Author Formats
{author} can be:
- Hex pubkey prefix (recommended): first characters of the pubkey in hex (e.g.
a7b9c2df,a7b9c2dfb9) - NIP-05 identifier:
name@domain(must be URL-encoded, e.g.alice%40nostr.com)
Examples
https://r.so/promo → key only
https://r.so/promo/a7b9c2df → with hex prefix
https://r.so/promo/a7b9c2dfb9 → with longer hex prefix
https://r.so/promo/alice%40nostr.com → with NIP-05
Discussion
Connect a key to comment.