跳到主要内容

获取评论中隐藏的剧透

GET/v1/comments/{id}/spoilers/{spoilerId}

返回评论在句子中隐藏的某一段剧透文本。

请求

Shell
curl -g "https://api.nogitsu.com/v1/comments/{id}/spoilers/{spoilerId}"

参数

  • id

    路径必填

    条目的 ID,为 UUID。

    文本

  • spoilerId

    路径必填

    隐藏剧透的 ID,取自条目的富文本。

    文本

响应

请求成功时返回 200 和以下 JSON:

  • children多种结构之一 列表
    1. 选项 1

      • type文本
        允许的值text
      • text文本
      • marks文本 列表
        允许的值bolditalicstrikecode
    2. 选项 2

      • type文本
        允许的值link
      • href文本 (uri)
      • childrenRichTextInline 列表
    3. 选项 3

      • type文本
        允许的值mention
      • username文本
    4. 选项 4

      • type文本
        允许的值spoiler
      • spoilerId文本
      • childrenRichTextInline 列表可为 null
    5. 选项 5

      • type文本
        允许的值break

错误

与所有操作一样,此操作在参数无效时可能返回 400,找不到内容时返回 404,请求过多时返回 429。所有错误的结构都相同。

了解错误