Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Food Recipe Event Specification #1571

Open
Anderson-Juhasc opened this issue Nov 7, 2024 · 1 comment
Open

Food Recipe Event Specification #1571

Anderson-Juhasc opened this issue Nov 7, 2024 · 1 comment

Comments

@Anderson-Juhasc
Copy link

Anderson-Juhasc commented Nov 7, 2024

Summary

This proposal defines a new event kind for Nostr to represent and share food recipe metadata. It aims to provide a standardized format for storing and transmitting information about food recipe within the Nostr network.

Kind: XXXX

Event Structure

The event structure follows the standard Nostr event format, customized for food recipe using tags to store metadata.

{
  "id": "<event_id>",
  "pubkey": "<author_pubkey>",
  "created_at": <unix_timestamp>,
  "kind": XXXX,
  "tags": [
    ["title", "<recipe_title>"],
    ["summary", "<recipe_summary>"],
    ["author", "<recipe_author>"],
    ["cuisine", "<style_or_region_of_cuisine>"],
    ["category", "<category>"],
    ["ingredients", "<ingredients_description>"],
    ["image", "<image_url>"], // can be used more than one

    // Optional Tags
    ["prep_time", "<prep_time>"],
    ["cook_time", "<cook_time>"],
    ["servings", "<servings_number>"],
    ["difficulty", "<difficulty>"],
    ["nutrition", "<calories_per_serving>"],
    ["tags", "<comma_separated_tags>"],
    ["allergens", "<comma_separated_allergens>"],
    ["content_warning", "<content_warning_description>"],
  ],
  "content": "<description_instructions_and_notes_content>",
  "sig": "<signature>"
}

Tag Descriptions

  • title: The title of the recipe.
  • summary: A brief summary or description of the recipe.
  • author: The name of the recipe's author or creator.
  • cuisine: The type or style of cuisine the recipe belongs to.
  • category: The general category of the recipe (e.g., main course, appetizer, dessert).
  • ingredients: A description or list of ingredients required to make the recipe. Can be provided as a single string or multiple entries, if needed.
  • image: A URL pointing to an image of the prepared dish.
Optional Tags
  • prep_time: The estimated time required to prepare the ingredients and get ready to cook.
  • cook_time: The estimated time needed to cook the recipe.
  • servings: The number of servings the recipe yields.
  • difficulty: The difficulty level of the recipe, indicating how challenging it is to prepare (e.g., easy, medium, hard).
  • nutrition: Nutrition information, such as calories per serving or other relevant metrics.
  • tags: Comma-separated tags for categorization or searchability purposes.
  • allergens: A comma-separated list of potential allergens present in the recipe.
  • content_warning: A description of any content warnings related to the recipe, such as allergen risks.
@Anderson-Juhasc Anderson-Juhasc changed the title Nostr Food Recipe Event Specification Food Recipe Event Specification Nov 7, 2024
@fiatjaf
Copy link
Member

fiatjaf commented Nov 7, 2024

Looks good, but I would remove notes and instructions and leave that for the body of the event, as Markdown probably, to be written in any style or manner is desired. And also take some of these other tags, like nutrition, allergens, cook_time and servings and place them separatedly to make sure they are strictly optional.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants