# NIP25

## 反应

`draft` `optional` `author:jb55`

反应是 `kind 7` 用来对其他音符作出反应的音符。

由 `+` 字符串的 `content` 集合表示的一般反应应解释为“喜欢”或“赞成”。

设置为 `-` 的反应 `content` 应解释为“不喜欢”或“投反对票”。它不应该被算作“喜欢”，可以在帖子上显示为反对票或不喜欢。客户还可以选择在类似 Reddit 的投票系统中统计喜欢和不喜欢，或者将它们显示为单独的计数。

这 `content` 可能是一个表情符号，在这种情况下，它可能被解释为“喜欢”或“不喜欢”，或者客户可以在帖子上显示这个表情符号的反应。

## 标签

反应事件应包括 `e` 来自用户正在对其作出反应的注释的和 `p` 标记。这允许用户被通知对他们被提及的帖子的反应。包括 `e` 标签使客户端能够拉出与单个帖子或线程中的所有帖子相关联的所有反应。

最后一个 `e` 标记必须是对其作出反应的便笺的 `id`。

最后一个 `p` 标记必须是正在响应的事件的 `pubkey`。

示例代码

\`\` \`swift func 使 \_ 像 \_ 事件（pubkey：string，privkey：string，like：nostrevent）->nostrevent{ }


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://sherry-pang.gitbook.io/nostr-cn/fu-lu-1-nip-xiang-jie/25.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
