Skip to content

Instantly share code, notes, and snippets.

@chromatic
Created July 31, 2023 00:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save chromatic/44bbf2812982b9d4ea8ddc66a3106c8a to your computer and use it in GitHub Desktop.
Save chromatic/44bbf2812982b9d4ea8ddc66a3106c8a to your computer and use it in GitHub Desktop.
Draft of NIP for Bounties

NOT A NIP (YET)

Nostr bounties

draft optional author:chromatic

Terms

  • bounty an offer to pay a reward for fulfilling a condition
  • pledge a specific amount of currency promised to the person fulfilling the condition
  • status a description of the state of the bounty, especially distinguishing between proposed, claimed, and rewarded, etc

Event ...: Create or update a bounty

Event Content:

{
    ".content": <String, a description of what is being requested, including the conditions for awarding the bounty upon completion>,
    ".pubkey":  <public key of the party creating the bounty>,

    "id": <String, UUID generated by the merchant. Random UUID encouraged.>,
    "title": <String, a title for the bounty>,
    "amount": <Array in the format ["amount", "<number>", "<currency>"]>
    [
        "amount" <String, the literal name of the tag
        "number" <String, the amount in numeric format, included in the tag as as string>,
        "currency" <String, the currency unit in ISO 4217 format or similar format ("btc", "usd", "cad", "doge")>
    ],
    "published_at": <Integer, timestamp in Unix seconds of when the bounty was first published>,
    "images": <Array of Strings, image URLs to include in content>,
    "status": <String, the status of the bounty (`proposed`, `active`, `claimed`, `rewarded`, `withdrawn`)>
}

Event ...: Pledge to bounty

Add a pledge to an existing bounty.

Event ... Apply for Bounty

Apply for the reward for completing a bounty.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment