feat: 添加小红书标签功能支持 (#65)
* feat: 实现小红书标签输入和自动关联功能 - 在 PublishImageContent 结构体中添加 Tags 字段 - 实现 inputTags 函数处理多个标签输入 - 实现 inputTag 函数自动点击标签联想下拉框 - 通过 #creator-editor-topic-container 选择器定位标签下拉框 - 自动点击第一个 .item 元素完成标签关联 - 添加错误处理和日志记录 * feat: 为 MCP 和 HTTP API 添加标签(tags)支持 - 在 PublishRequest 结构体中添加 Tags 字段 - 更新 MCP handler 处理标签参数 - 更新 MCP 工具定义,添加 tags 参数说明 - HTTP API 自动支持 tags 字段(通过 PublishRequest) - 保持向后兼容,tags 为可选参数
This commit is contained in:
@@ -176,7 +176,7 @@ func (s *AppServer) processToolsList(request *JSONRPCRequest) *JSONRPCResponse {
|
||||
},
|
||||
"content": map[string]interface{}{
|
||||
"type": "string",
|
||||
"description": "正文内容,支持话题标签",
|
||||
"description": "正文内容",
|
||||
},
|
||||
"images": map[string]interface{}{
|
||||
"type": "array",
|
||||
@@ -186,6 +186,13 @@ func (s *AppServer) processToolsList(request *JSONRPCRequest) *JSONRPCResponse {
|
||||
},
|
||||
"minItems": 1,
|
||||
},
|
||||
"tags": map[string]interface{}{
|
||||
"type": "array",
|
||||
"description": "话题标签列表(可选),如 [\"美食\", \"旅行\", \"生活\"]",
|
||||
"items": map[string]interface{}{
|
||||
"type": "string",
|
||||
},
|
||||
},
|
||||
},
|
||||
"required": []string{"title", "content", "images"},
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user