{"openapi":"3.0.3","info":{"title":"TheaterAPI 本地存储后端","version":"1.0.0","description":"上游 API Key 由维护者配置，无上游登录接口。本后端通过 /user/temp 申请临时 token，携带 Bearer 调用业务。播放缓存默认一天，refresh=true 可强制刷新。"},"servers":[{"url":"/"}],"security":[{"backendToken":[]}],"paths":{"/drama/search":{"get":{"operationId":"search","summary":"搜索作品并保存作品 ID","tags":["剧场"],"parameters":[{"name":"keyword","in":"query","required":true,"description":"作品搜索词","schema":{"type":"string","minLength":1,"maxLength":200}},{"name":"page","in":"query","required":false,"description":"页码","schema":{"type":"integer","minimum":1,"default":1}},{"name":"refresh","in":"query","required":false,"description":"强制重新请求上游并更新本地文件","schema":{"type":"string","enum":["true","false","1","0"]}}],"responses":{"200":{"description":"code=0；data 原样保留上游结构，仍需检查播放状态","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"400":{"$ref":"#/components/responses/Error"},"401":{"$ref":"#/components/responses/Error"},"403":{"$ref":"#/components/responses/Error"},"429":{"$ref":"#/components/responses/Error"},"500":{"$ref":"#/components/responses/Error"},"502":{"$ref":"#/components/responses/Error"},"503":{"$ref":"#/components/responses/Error"},"504":{"$ref":"#/components/responses/Error"}}}},"/drama/info":{"get":{"operationId":"info","summary":"作品详情","tags":["剧场"],"parameters":[{"name":"comicId","in":"query","required":true,"description":"从搜索 data.dramaCards[].comicId 取得，保留为字符串","schema":{"type":"string","pattern":"^[1-9][0-9]*$"}},{"name":"part_id","in":"query","required":false,"description":"真实季 ID，取 seasons.data.seasons[].partId；多季作品必填，后端映射到该季的真实 comicId","schema":{"type":"string"}},{"name":"refresh","in":"query","required":false,"description":"强制重新请求上游并更新本地文件","schema":{"type":"string","enum":["true","false","1","0"]}}],"responses":{"200":{"description":"code=0；data 原样保留上游结构，仍需检查播放状态","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"400":{"$ref":"#/components/responses/Error"},"401":{"$ref":"#/components/responses/Error"},"403":{"$ref":"#/components/responses/Error"},"429":{"$ref":"#/components/responses/Error"},"500":{"$ref":"#/components/responses/Error"},"502":{"$ref":"#/components/responses/Error"},"503":{"$ref":"#/components/responses/Error"},"504":{"$ref":"#/components/responses/Error"}}}},"/drama/seasons":{"get":{"operationId":"seasons","summary":"季列表和跨季作品映射","tags":["剧场"],"parameters":[{"name":"comicId","in":"query","required":true,"description":"从搜索 data.dramaCards[].comicId 取得，保留为字符串","schema":{"type":"string","pattern":"^[1-9][0-9]*$"}},{"name":"refresh","in":"query","required":false,"description":"强制重新请求上游并更新本地文件","schema":{"type":"string","enum":["true","false","1","0"]}}],"responses":{"200":{"description":"code=0；data 原样保留上游结构，仍需检查播放状态","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"400":{"$ref":"#/components/responses/Error"},"401":{"$ref":"#/components/responses/Error"},"403":{"$ref":"#/components/responses/Error"},"429":{"$ref":"#/components/responses/Error"},"500":{"$ref":"#/components/responses/Error"},"502":{"$ref":"#/components/responses/Error"},"503":{"$ref":"#/components/responses/Error"},"504":{"$ref":"#/components/responses/Error"}}}},"/drama/catalog":{"get":{"operationId":"catalog","summary":"所选季目录","tags":["剧场"],"parameters":[{"name":"comicId","in":"query","required":true,"description":"从搜索 data.dramaCards[].comicId 取得，保留为字符串","schema":{"type":"string","pattern":"^[1-9][0-9]*$"}},{"name":"part_id","in":"query","required":false,"description":"真实季 ID，取 seasons.data.seasons[].partId；多季作品必填，后端映射到该季的真实 comicId","schema":{"type":"string"}},{"name":"episode_id","in":"query","required":false,"description":"真实剧集 ID，取 catalog.data.episodes[].episodeId","schema":{"type":"string"}},{"name":"definition","in":"query","required":false,"description":"上游清晰度档位 ID，与 quality 互斥","schema":{"type":"string"}},{"name":"refresh","in":"query","required":false,"description":"强制重新请求上游并更新本地文件","schema":{"type":"string","enum":["true","false","1","0"]}}],"responses":{"200":{"description":"code=0；data 原样保留上游结构，仍需检查播放状态","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"400":{"$ref":"#/components/responses/Error"},"401":{"$ref":"#/components/responses/Error"},"403":{"$ref":"#/components/responses/Error"},"429":{"$ref":"#/components/responses/Error"},"500":{"$ref":"#/components/responses/Error"},"502":{"$ref":"#/components/responses/Error"},"503":{"$ref":"#/components/responses/Error"},"504":{"$ref":"#/components/responses/Error"}}}},"/drama/qualities":{"get":{"operationId":"qualities","summary":"真实可用清晰度","tags":["剧场"],"parameters":[{"name":"comicId","in":"query","required":true,"description":"从搜索 data.dramaCards[].comicId 取得，保留为字符串","schema":{"type":"string","pattern":"^[1-9][0-9]*$"}},{"name":"part_id","in":"query","required":false,"description":"真实季 ID，取 seasons.data.seasons[].partId；多季作品必填，后端映射到该季的真实 comicId","schema":{"type":"string"}},{"name":"refresh","in":"query","required":false,"description":"强制重新请求上游并更新本地文件","schema":{"type":"string","enum":["true","false","1","0"]}}],"responses":{"200":{"description":"code=0；data 原样保留上游结构，仍需检查播放状态","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"400":{"$ref":"#/components/responses/Error"},"401":{"$ref":"#/components/responses/Error"},"403":{"$ref":"#/components/responses/Error"},"429":{"$ref":"#/components/responses/Error"},"500":{"$ref":"#/components/responses/Error"},"502":{"$ref":"#/components/responses/Error"},"503":{"$ref":"#/components/responses/Error"},"504":{"$ref":"#/components/responses/Error"}}}},"/drama/video":{"get":{"operationId":"video","summary":"单集解析：episode_no 或 episode_id 至少一个","tags":["剧场"],"parameters":[{"name":"comicId","in":"query","required":true,"description":"从搜索 data.dramaCards[].comicId 取得，保留为字符串","schema":{"type":"string","pattern":"^[1-9][0-9]*$"}},{"name":"part_id","in":"query","required":false,"description":"真实季 ID，取 seasons.data.seasons[].partId；多季作品必填，后端映射到该季的真实 comicId","schema":{"type":"string"}},{"name":"episode_id","in":"query","required":false,"description":"真实剧集 ID，取 catalog.data.episodes[].episodeId","schema":{"type":"string"}},{"name":"episode_no","in":"query","required":false,"description":"剧集序号，episode_id 存在时上游优先使用 ID","schema":{"type":"integer","minimum":1}},{"name":"quality","in":"query","required":false,"description":"与 definition 互斥；未指定时有1080P则优先1080P，否则使用上游默认画质","schema":{"type":"integer","enum":[480,720,1080]}},{"name":"definition","in":"query","required":false,"description":"上游清晰度档位 ID，与 quality 互斥","schema":{"type":"string"}},{"name":"refresh","in":"query","required":false,"description":"强制重新请求上游并更新本地文件","schema":{"type":"string","enum":["true","false","1","0"]}}],"responses":{"200":{"description":"code=0；data 原样保留上游结构，仍需检查播放状态","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"400":{"$ref":"#/components/responses/Error"},"401":{"$ref":"#/components/responses/Error"},"403":{"$ref":"#/components/responses/Error"},"429":{"$ref":"#/components/responses/Error"},"500":{"$ref":"#/components/responses/Error"},"502":{"$ref":"#/components/responses/Error"},"503":{"$ref":"#/components/responses/Error"},"504":{"$ref":"#/components/responses/Error"}}}},"/drama/playlist":{"get":{"operationId":"playlist","summary":"整季逐集解析，分别检查每集结果","tags":["剧场"],"parameters":[{"name":"comicId","in":"query","required":true,"description":"从搜索 data.dramaCards[].comicId 取得，保留为字符串","schema":{"type":"string","pattern":"^[1-9][0-9]*$"}},{"name":"part_id","in":"query","required":false,"description":"真实季 ID，取 seasons.data.seasons[].partId；多季作品必填，后端映射到该季的真实 comicId","schema":{"type":"string"}},{"name":"quality","in":"query","required":false,"description":"与 definition 互斥；未指定时有1080P则优先1080P，否则使用上游默认画质","schema":{"type":"integer","enum":[480,720,1080]}},{"name":"definition","in":"query","required":false,"description":"上游清晰度档位 ID，与 quality 互斥","schema":{"type":"string"}},{"name":"refresh","in":"query","required":false,"description":"强制重新请求上游并更新本地文件","schema":{"type":"string","enum":["true","false","1","0"]}}],"responses":{"200":{"description":"code=0；data 原样保留上游结构，仍需检查播放状态","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"400":{"$ref":"#/components/responses/Error"},"401":{"$ref":"#/components/responses/Error"},"403":{"$ref":"#/components/responses/Error"},"429":{"$ref":"#/components/responses/Error"},"500":{"$ref":"#/components/responses/Error"},"502":{"$ref":"#/components/responses/Error"},"503":{"$ref":"#/components/responses/Error"},"504":{"$ref":"#/components/responses/Error"}}}},"/drama/local":{"get":{"operationId":"local","summary":"本地已记录作品列表","tags":["剧场"],"parameters":[{"name":"page","in":"query","required":false,"description":"页码","schema":{"type":"integer","minimum":1,"default":1}},{"name":"size","in":"query","required":false,"description":"每页条数","schema":{"type":"integer","minimum":1,"maximum":100,"default":20}}],"responses":{"200":{"description":"code=0；data 原样保留上游结构，仍需检查播放状态","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"400":{"$ref":"#/components/responses/Error"},"401":{"$ref":"#/components/responses/Error"},"403":{"$ref":"#/components/responses/Error"},"429":{"$ref":"#/components/responses/Error"},"500":{"$ref":"#/components/responses/Error"},"502":{"$ref":"#/components/responses/Error"},"503":{"$ref":"#/components/responses/Error"},"504":{"$ref":"#/components/responses/Error"}}}},"/drama/cache":{"get":{"operationId":"cache","summary":"缓存状态与过期时间，不返回播放地址","tags":["剧场"],"parameters":[{"name":"comicId","in":"query","required":true,"description":"从搜索 data.dramaCards[].comicId 取得，保留为字符串","schema":{"type":"string","pattern":"^[1-9][0-9]*$"}}],"responses":{"200":{"description":"code=0；data 原样保留上游结构，仍需检查播放状态","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"400":{"$ref":"#/components/responses/Error"},"401":{"$ref":"#/components/responses/Error"},"403":{"$ref":"#/components/responses/Error"},"429":{"$ref":"#/components/responses/Error"},"500":{"$ref":"#/components/responses/Error"},"502":{"$ref":"#/components/responses/Error"},"503":{"$ref":"#/components/responses/Error"},"504":{"$ref":"#/components/responses/Error"}}}},"/drama/stats":{"get":{"operationId":"stats","summary":"本地存储统计：去重作品、剧集、目录、已解析及未过期播放链接数量；只扫描当前上游身份的本地文件，不访问上游","tags":["剧场"],"security":[{"statsToken":[]}],"description":"仅允许 STATS_TOKEN_WHITELIST 配置中的固定 token；空数组禁止所有访问。临时 token 和 BACKEND_TOKEN 不自动获准。独立鉴权，不扣临时用户额度，仍受 IP 和统计接口频率限制。","parameters":[],"responses":{"200":{"description":"code=0；data 原样保留上游结构，仍需检查播放状态","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"400":{"$ref":"#/components/responses/Error"},"401":{"$ref":"#/components/responses/Error"},"403":{"$ref":"#/components/responses/Error"},"429":{"$ref":"#/components/responses/Error"},"500":{"$ref":"#/components/responses/Error"},"502":{"$ref":"#/components/responses/Error"},"503":{"$ref":"#/components/responses/Error"},"504":{"$ref":"#/components/responses/Error"}}}},"/system/health":{"get":{"operationId":"health","summary":"本地存活检查","security":[],"responses":{"200":{"description":"本地服务已运行，不代表上游可用"}}}},"/discover/homepage":{"get":{"operationId":"discover_homepage","summary":"发现首页与真实栏目导航","tags":["发现"],"parameters":[{"name":"page","in":"query","required":false,"description":"页码","schema":{"type":"integer","minimum":1,"default":1}},{"name":"page_size","in":"query","required":false,"description":"每页大小","schema":{"type":"integer","minimum":1}},{"name":"refresh","in":"query","required":false,"description":"强制重新请求上游并更新本地文件","schema":{"type":"string","enum":["true","false","1","0"]}}],"responses":{"200":{"description":"code=0，data 保留上游业务结构；chart-new 返回栏目 cards、page、上游顶层 hasMore 及 nextPage（结束时为 null），meta.supports_pagination=true","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"400":{"$ref":"#/components/responses/Error"},"401":{"$ref":"#/components/responses/Error"},"403":{"$ref":"#/components/responses/Error"},"422":{"$ref":"#/components/responses/Error"},"429":{"$ref":"#/components/responses/Error"},"500":{"$ref":"#/components/responses/Error"},"502":{"$ref":"#/components/responses/Error"},"503":{"$ref":"#/components/responses/Error"},"504":{"$ref":"#/components/responses/Error"}}}},"/discover/filter-config":{"get":{"operationId":"discover_filter_config","summary":"分类筛选选项和默认排序；读取 data.filterGroups","tags":["发现"],"parameters":[{"name":"refresh","in":"query","required":false,"description":"强制重新请求上游并更新本地文件","schema":{"type":"string","enum":["true","false","1","0"]}}],"responses":{"200":{"description":"code=0，data 保留上游业务结构；chart-new 返回栏目 cards、page、上游顶层 hasMore 及 nextPage（结束时为 null），meta.supports_pagination=true","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"400":{"$ref":"#/components/responses/Error"},"401":{"$ref":"#/components/responses/Error"},"403":{"$ref":"#/components/responses/Error"},"422":{"$ref":"#/components/responses/Error"},"429":{"$ref":"#/components/responses/Error"},"500":{"$ref":"#/components/responses/Error"},"502":{"$ref":"#/components/responses/Error"},"503":{"$ref":"#/components/responses/Error"},"504":{"$ref":"#/components/responses/Error"}}}},"/discover/ranks":{"get":{"operationId":"discover_ranks","summary":"排行榜，data.rankList；根据 hasMore 翻页","tags":["发现"],"parameters":[{"name":"rank_type","in":"query","required":false,"description":"hot/1 热榜，new/2 新榜","schema":{"type":"string","enum":["hot","new","1","2"],"default":"hot"}},{"name":"page","in":"query","required":false,"description":"页码","schema":{"type":"integer","minimum":1,"default":1}},{"name":"refresh","in":"query","required":false,"description":"强制重新请求上游并更新本地文件","schema":{"type":"string","enum":["true","false","1","0"]}}],"responses":{"200":{"description":"code=0，data 保留上游业务结构；chart-new 返回栏目 cards、page、上游顶层 hasMore 及 nextPage（结束时为 null），meta.supports_pagination=true","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"400":{"$ref":"#/components/responses/Error"},"401":{"$ref":"#/components/responses/Error"},"403":{"$ref":"#/components/responses/Error"},"422":{"$ref":"#/components/responses/Error"},"429":{"$ref":"#/components/responses/Error"},"500":{"$ref":"#/components/responses/Error"},"502":{"$ref":"#/components/responses/Error"},"503":{"$ref":"#/components/responses/Error"},"504":{"$ref":"#/components/responses/Error"}}}},"/discover/section":{"get":{"operationId":"discover_section","summary":"真实分区分页；不支持更多的栏目保留上游 422","tags":["发现"],"parameters":[{"name":"section_id","in":"query","required":true,"description":"取首页导航 sectionId","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"页码","schema":{"type":"integer","minimum":1,"default":1}},{"name":"refresh","in":"query","required":false,"description":"强制重新请求上游并更新本地文件","schema":{"type":"string","enum":["true","false","1","0"]}}],"responses":{"200":{"description":"code=0，data 保留上游业务结构；chart-new 返回栏目 cards、page、上游顶层 hasMore 及 nextPage（结束时为 null），meta.supports_pagination=true","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"400":{"$ref":"#/components/responses/Error"},"401":{"$ref":"#/components/responses/Error"},"403":{"$ref":"#/components/responses/Error"},"422":{"$ref":"#/components/responses/Error"},"429":{"$ref":"#/components/responses/Error"},"500":{"$ref":"#/components/responses/Error"},"502":{"$ref":"#/components/responses/Error"},"503":{"$ref":"#/components/responses/Error"},"504":{"$ref":"#/components/responses/Error"}}}},"/discover/new-arrivals":{"get":{"operationId":"discover_new_arrivals","summary":"上游独立上新接口，需要实际 tab_id","tags":["发现"],"parameters":[{"name":"tab_id","in":"query","required":true,"description":"仅使用上游实际导航返回值，不猜测 ID","schema":{"type":"string"}},{"name":"page","in":"query","required":false,"description":"页码","schema":{"type":"integer","minimum":1,"default":1}},{"name":"filter_tag_id","in":"query","required":false,"description":"","schema":{"type":"string"}},{"name":"refresh","in":"query","required":false,"description":"强制重新请求上游并更新本地文件","schema":{"type":"string","enum":["true","false","1","0"]}}],"responses":{"200":{"description":"code=0，data 保留上游业务结构；chart-new 返回栏目 cards、page、上游顶层 hasMore 及 nextPage（结束时为 null），meta.supports_pagination=true","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"400":{"$ref":"#/components/responses/Error"},"401":{"$ref":"#/components/responses/Error"},"403":{"$ref":"#/components/responses/Error"},"422":{"$ref":"#/components/responses/Error"},"429":{"$ref":"#/components/responses/Error"},"500":{"$ref":"#/components/responses/Error"},"502":{"$ref":"#/components/responses/Error"},"503":{"$ref":"#/components/responses/Error"},"504":{"$ref":"#/components/responses/Error"}}}},"/discover/new-shows":{"get":{"operationId":"discover_new_shows","summary":"好剧上新：自动解析首页导航的真实分区，data.items；hasMore=false 停止翻页","tags":["发现"],"parameters":[{"name":"page","in":"query","required":false,"description":"页码","schema":{"type":"integer","minimum":1,"default":1}},{"name":"refresh","in":"query","required":false,"description":"强制重新请求上游并更新本地文件","schema":{"type":"string","enum":["true","false","1","0"]}}],"responses":{"200":{"description":"code=0，data 保留上游业务结构；chart-new 返回栏目 cards、page、上游顶层 hasMore 及 nextPage（结束时为 null），meta.supports_pagination=true","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"400":{"$ref":"#/components/responses/Error"},"401":{"$ref":"#/components/responses/Error"},"403":{"$ref":"#/components/responses/Error"},"422":{"$ref":"#/components/responses/Error"},"429":{"$ref":"#/components/responses/Error"},"500":{"$ref":"#/components/responses/Error"},"502":{"$ref":"#/components/responses/Error"},"503":{"$ref":"#/components/responses/Error"},"504":{"$ref":"#/components/responses/Error"}}}},"/discover/chart-new":{"get":{"operationId":"discover_chart_new","summary":"打榜新剧：page=1 刷新，hasMore=true 时递增 page 加载下一批；兼容无标题栏目，不复用推荐缓存","tags":["发现"],"parameters":[{"name":"page","in":"query","required":false,"description":"页码","schema":{"type":"integer","minimum":1,"default":1}},{"name":"refresh","in":"query","required":false,"description":"强制重新请求上游并更新本地文件","schema":{"type":"string","enum":["true","false","1","0"]}}],"responses":{"200":{"description":"code=0，data 保留上游业务结构；chart-new 返回栏目 cards、page、上游顶层 hasMore 及 nextPage（结束时为 null），meta.supports_pagination=true","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"400":{"$ref":"#/components/responses/Error"},"401":{"$ref":"#/components/responses/Error"},"403":{"$ref":"#/components/responses/Error"},"422":{"$ref":"#/components/responses/Error"},"429":{"$ref":"#/components/responses/Error"},"500":{"$ref":"#/components/responses/Error"},"502":{"$ref":"#/components/responses/Error"},"503":{"$ref":"#/components/responses/Error"},"504":{"$ref":"#/components/responses/Error"}}}},"/discover/feed":{"get":{"operationId":"discover_feed","summary":"刷刷：每次访问上游；下一批原样回传 nextCursor，首次省略 cursor 或传空字符串","tags":["发现"],"parameters":[{"name":"cursor","in":"query","required":false,"description":"","schema":{"type":"string"}},{"name":"current_comic_id","in":"query","required":false,"description":"当前 feed.list[].comicInfo.comicId","schema":{"type":"string"}},{"name":"refresh","in":"query","required":false,"description":"强制重新请求上游并更新本地文件","schema":{"type":"string","enum":["true","false","1","0"]}}],"responses":{"200":{"description":"code=0，data 保留上游业务结构；chart-new 返回栏目 cards、page、上游顶层 hasMore 及 nextPage（结束时为 null），meta.supports_pagination=true","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"400":{"$ref":"#/components/responses/Error"},"401":{"$ref":"#/components/responses/Error"},"403":{"$ref":"#/components/responses/Error"},"422":{"$ref":"#/components/responses/Error"},"429":{"$ref":"#/components/responses/Error"},"500":{"$ref":"#/components/responses/Error"},"502":{"$ref":"#/components/responses/Error"},"503":{"$ref":"#/components/responses/Error"},"504":{"$ref":"#/components/responses/Error"}}}},"/discover/feed-stats":{"get":{"operationId":"discover_feed_stats","summary":"推荐剧集互动统计","tags":["发现"],"parameters":[{"name":"comic_id","in":"query","required":true,"description":"","schema":{"type":"string"}},{"name":"episode_id","in":"query","required":true,"description":"","schema":{"type":"string"}},{"name":"is_swipe","in":"query","required":false,"description":"滑动上下文","schema":{"type":"boolean"}},{"name":"refresh","in":"query","required":false,"description":"强制重新请求上游并更新本地文件","schema":{"type":"string","enum":["true","false","1","0"]}}],"responses":{"200":{"description":"code=0，data 保留上游业务结构；chart-new 返回栏目 cards、page、上游顶层 hasMore 及 nextPage（结束时为 null），meta.supports_pagination=true","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"400":{"$ref":"#/components/responses/Error"},"401":{"$ref":"#/components/responses/Error"},"403":{"$ref":"#/components/responses/Error"},"422":{"$ref":"#/components/responses/Error"},"429":{"$ref":"#/components/responses/Error"},"500":{"$ref":"#/components/responses/Error"},"502":{"$ref":"#/components/responses/Error"},"503":{"$ref":"#/components/responses/Error"},"504":{"$ref":"#/components/responses/Error"}}}},"/discover/filter-results":{"post":{"operationId":"discover_filter_results","summary":"分类筛选查询，data.cards；按 hasMore 翻页；筛选键和排序来自 filter-config","tags":["发现"],"parameters":[{"name":"refresh","in":"query","required":false,"description":"强制重新请求上游并更新本地文件","schema":{"type":"string","enum":["true","false","1","0"]}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["filters","sort_by"],"properties":{"filters":{"type":"object","additionalProperties":{"type":"string"},"description":"groupKey → optionKey；默认选择 defaultSelected；不含排序组，保留 all/0 字符串"},"sort_by":{"type":"string","description":"排序组 groupKey=sort 中所选 optionKey"},"page":{"type":"integer","minimum":1,"default":1},"page_size":{"type":"integer","minimum":1,"default":20}}}}}},"responses":{"200":{"description":"code=0，data 保留上游业务结构；chart-new 返回栏目 cards、page、上游顶层 hasMore 及 nextPage（结束时为 null），meta.supports_pagination=true","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"400":{"$ref":"#/components/responses/Error"},"401":{"$ref":"#/components/responses/Error"},"403":{"$ref":"#/components/responses/Error"},"422":{"$ref":"#/components/responses/Error"},"429":{"$ref":"#/components/responses/Error"},"500":{"$ref":"#/components/responses/Error"},"502":{"$ref":"#/components/responses/Error"},"503":{"$ref":"#/components/responses/Error"},"504":{"$ref":"#/components/responses/Error"}}}},"/user/temp":{"post":{"operationId":"registerTempToken","summary":"三道口令自助申请临时 token，默认有效期 3 天","tags":["用户"],"security":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["id","pw1","pw2","pw3"],"properties":{"id":{"type":"string","pattern":"^[a-z0-9]{16}$"},"pw1":{"type":"string","format":"password"},"pw2":{"type":"string","format":"password"},"pw3":{"type":"string","format":"password"}}}}}},"responses":{"200":{"description":"data.token 为仅本次返回的本后端临时 token，含 expires_at、limits、remaining","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"400":{"$ref":"#/components/responses/Error"},"403":{"$ref":"#/components/responses/Error"},"409":{"$ref":"#/components/responses/Error"},"429":{"$ref":"#/components/responses/Error"}}},"get":{"operationId":"registerTempTokenLegacy","summary":"兼容 GET 申请；建议使用 POST 避免口令出现在 URL 中","tags":["用户"],"security":[],"parameters":[{"name":"id","in":"query","required":true,"description":"","schema":{"type":"string"}},{"name":"pw1","in":"query","required":true,"description":"","schema":{"type":"string"}},{"name":"pw2","in":"query","required":true,"description":"","schema":{"type":"string"}},{"name":"pw3","in":"query","required":true,"description":"","schema":{"type":"string"}}],"responses":{"200":{"description":"data.token 为仅本次返回的本后端临时 token，含 expires_at、limits、remaining","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"400":{"$ref":"#/components/responses/Error"},"403":{"$ref":"#/components/responses/Error"},"409":{"$ref":"#/components/responses/Error"},"429":{"$ref":"#/components/responses/Error"}}}},"/user/me":{"get":{"operationId":"tokenInfo","summary":"查询 token 到期时间、已用次数和剩余额度，不消耗业务额度","tags":["用户"],"responses":{"200":{"description":"用户信息、usage、limits、remaining","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Success"}}}},"401":{"$ref":"#/components/responses/Error"},"429":{"$ref":"#/components/responses/Error"}}}}},"components":{"securitySchemes":{"backendToken":{"type":"http","scheme":"bearer","description":"/user/temp 返回的 tht_ 临时 token，或维护者配置的 BACKEND_TOKEN；不是上游 API Key，不自动获准调用 /drama/stats"},"statsToken":{"type":"http","scheme":"bearer","description":"STATS_TOKEN_WHITELIST 中的固定 token，仅用于 /drama/stats；修改配置后重启生效，空数组拒绝所有访问"}},"schemas":{"Success":{"type":"object","required":["code","msg","data","request_id"],"properties":{"code":{"type":"integer","enum":[0]},"msg":{"type":"string"},"data":{"description":"上游 data，或本地列表/缓存状态"},"meta":{"type":"object","properties":{"cache_hit":{"type":"boolean"},"fetched_at":{"type":"string","format":"date-time"},"expires_at":{"type":"string","format":"date-time"},"upstream_request_id":{"type":"string"}}},"request_id":{"type":"string"}}},"Error":{"type":"object","properties":{"code":{"type":"integer"},"msg":{"type":"string"},"request_id":{"type":"string"},"details":{"type":"object","properties":{"upstream_code":{"type":"string"},"upstream_request_id":{"type":"string"}}}}}},"responses":{"Error":{"description":"失败；HTTP 状态对应 code。保留 request_id 以便排查。","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}