---
title: "Response Schema"
description: "Account、Post、Comment、Group 与 Page——所有 SNS 平台统一返回的类型，逐字段说明。"
---

五种类型覆盖了所有 SNS 操作，同一个字段在每个平台上含义都相同。

可选字段是真正可选的：**缺失表示平台没有给出该信息**。没有 `metrics.likes` 表示点赞数被隐藏，而不是零赞。
时间为 ISO 8601，UTC。每个对象都带有 `platform`，并可能带有 `ext`：只有该平台才有的信息，使用该平台自己的名称。

## Account

个人、创作者、频道或主页。

| 字段 | 类型 | 说明 |
|---|---|---|
| `platform` | string | `reddit` `tiktok` `youtube` `instagram` `threads` `linkedin` `x` |
| `handle` | string | @用户名，或该平台的对应物 |
| `url` | string | 主页地址 |
| `id` | string? | 平台的稳定 id |
| `displayName` `bio` | string? | |
| `avatarUrl` `bannerUrl` | string? | |
| `verified` | boolean? | |
| `createdAt` | string? | 账号创建时间 |
| `counts` | object? | `{followers?, following?, posts?}` |
| `links` | array? | `{url, title?}`——主页上的链接 |
| `private` | boolean? | 私密（受保护）账号：只有获批准的关注者才能看到其帖子 |
| `category` | string? | 账号自选的类别名称，原样返回（`Musician/Band`、`Media & News Company`） |
| `ext` | object? | 平台独有的信息 |

## Post

帖子、视频、Reels、短视频、Threads 帖子或推文。

| 字段 | 类型 | 说明 |
|---|---|---|
| `id` `url` | string | |
| `author` | AccountRef | `{platform, id?, handle?, displayName?, url?, avatarUrl?, verified?, counts?}` |
| `title` | string? | 平台有标题时才有（Reddit、YouTube） |
| `text` | string? | 正文或配文 |
| `createdAt` `editedAt` | string? | |
| `lang` | string? | |
| `media` | Media[] | 图片、GIF、视频和嵌入内容——见下 |
| `metrics` | object? | `{likes?, comments?, shares?, views?, reposts?, quotes?, saves?, liveViewers?}` |
| `entities` | object? | 正文中出现的 `{mentions?, urls?, hashtags?}` |
| `linkPreview` | object? | `{url, title?, description?, thumbnailUrl?, domain?}` |
| `poll` | object? | `{options: [{text, votes?}], totalVotes?, endsAt?}` |
| `place` | object? | `{name, id?, lat?, lng?, address?, city?, region?, postalCode?, country?}` |
| `audio` | object? | `{id?, title?, artist?, url?}`——TikTok 音乐、Reels 的音频 |
| `live` | boolean? | 直播 |
| `broadcast` | object? | `{status, scheduledAt?, startedAt?, endedAt?}`——直播的进行状态；`status` 为 `scheduled`、`live` 或 `ended` |
| `repostOf` `quoteOf` | Post? | 本帖转发或引用的帖子 |
| `inReplyTo` | object? | `{id, url?, author?}`——本帖所回复的帖子 |
| `sponsored` | boolean? | 付费推广或品牌合作内容 |
| `pinned` | boolean? | 作者置顶在主页最上方的帖子 |
| `aiGenerated` | boolean? | 平台标注为 AI 生成的内容 |
| `sensitive` | boolean? | 平台标注为敏感内容（NSFW） |
| `ext` | object? | 平台独有的信息 |

各平台对 `views` 的统计方式不同：TikTok 和 YouTube 报告的是播放次数，X 报告的是曝光次数。
Reddit 的 `score` 不是点赞数，因此放在 `ext` 中，绝不会放进 `metrics.likes`。`shares` 只统计分享和发送；
转发和引用分别计入 `reposts` 和 `quotes`，`saves` 是收藏（书签）数。`liveViewers` 是此刻正在观看直播的人数，
因此只在 `broadcast.status` 为 `live` 时出现。

`true`/`false` 标志（`sponsored`、`pinned`、`aiGenerated`、`sensitive`、`byAuthor` 等）与计数遵循同一规则：
没有该字段，表示平台没有提供。

### Media

| 字段 | 类型 | 说明 |
|---|---|---|
| `type` | `image` \| `gif` \| `video` \| `embed` | |
| `url` | string | |
| `width` `height` | number? | |
| `thumbnailUrl` | string? | |
| `durationSec` | number? | |
| `variants` | array? | 其他版本：`{url, width?, height?, bitrate?, contentType?}` |
| `altText` `caption` | string? | |

## Comment

| 字段 | 类型 | 说明 |
|---|---|---|
| `id` `postId` | string | |
| `parentId` | string? | 本评论所回复的评论 |
| `author` | AccountRef | |
| `text` | string | |
| `createdAt` `editedAt` `lang` | string? | |
| `pinned` | boolean? | |
| `byAuthor` | boolean? | 由帖子作者本人发表的评论 |
| `likedByAuthor` | boolean? | 帖子作者点赞（点亮爱心）的评论 |
| `metrics` | object? | `{likes?, replies?}` |
| `media` | Media[]? | |
| `replies` | Comment[] | 随本评论一并返回的回复 |
| `moreReplies` | object? | `{count?, ids?, cursor?}`——尚未加载的部分；用 `comments` 加载：`comment=` 传 cursor（YouTube）或评论的 `id`（Reddit、TikTok），或 Reddit 的 `ids` |

## Group

帖子聚集于其下的任何事物。

| 字段 | 类型 | 说明 |
|---|---|---|
| `kind` | string | `community` `channel` `company` `hashtag` `sound` `topic` `location` `list` |
| `id` `name` `url` | string | |
| `description` | string? | |
| `avatarUrl` `bannerUrl` | string? | |
| `createdAt` | string? | |
| `counts` | object? | `{members?, posts?}` |
| `sensitive` | boolean? | 平台将该群组标注为敏感（NSFW） |

## Page

所有列表。

```json
{ "platform": "tiktok", "items": [ /* Post, Comment, Account or Group */ ], "cursor": "…", "total": 1640 }
```

获取下一页时，只用 `cursor` 调用同一个操作。没有 `cursor` 表示这是最后一页。

如果有 `total`，它是整个列表的条目总数，与平台给出的数值完全一致；平台没有给出确切数字时则省略。
它并不保证每一条都能取到：各平台对可翻页的深度设有上限，`cursor` 结束时列表即结束。

评论页还可能带有 `ext.post`（评论所在的帖子）和 `ext.more`（平台尚未加载的顶层评论）——Reddit 两者都会返回。
