GEO-博客专辑-保存

接口信息

  • 接口地址: {your-site-url}/api/skill/geo/blog-collection-save
  • 基础 URL: {your-site-url} 需替换为你自己的独立站 URL 地址,如 https://your-domain.com/apimanager666
  • 请求方式: POST
  • Content-Type: application/json
  • 说明: 创建或更新博客专辑 GEO 数据。

认证

请求头中需要携带 skill-access-token:

Header 值
skill-access-token {your-skill-access-token} (请替换为你自己的 token)

请求参数

字段 类型 必填 说明
id int 否 主键 ID。传入则按 ID 保存;不传则按 collection_id 查找,存在则更新、不存在则创建
collection_id int 是 博客专辑 ID
language_code string 否 GEO 内容语言代码,缺省为 en
summary string 否 AI 生成的博客专辑摘要
semantic_content string 否 AI 生成的博客专辑完整语义化内容
blog_type string 否 博客专辑内容类型,如 Educational Guide、Buying Guide、Industry News
topic string 否 博客专辑核心主题
category_path array[string] 否 博客语义分类路径(JSON),建议 2-5 级
key_topics array[string] 否 博客专辑覆盖的核心知识主题(JSON)
key_questions array[string] 否 博客专辑主要回答的用户问题(JSON)
target_users array[string] 否 博客专辑主要面向的读者(JSON)
applications array[string] 否 博客专辑涉及的主要应用领域(JSON)
use_cases array[string] 否 用户访问该博客专辑的主要使用场景(JSON)
content_pillars array[string] 否 博客专辑的核心内容支柱(JSON)
knowledge_relationships array[object] 否 博客专辑内部知识主题之间的关系(JSON)
search_terms array[string] 否 AI 检索语义数据(JSON)
entities array[object] 否 博客专辑涉及的重要实体(JSON)
faq array[object] 否 博客专辑级 FAQ(JSON)
geo_score number 否 GEO 数据完整度评分(0-100)
source_content_hash string 否 生成 GEO 时使用的源数据内容 hash(最大长度 64)

请求示例

cURL

curl --location --request POST '{your-site-url}/api/skill/geo/blog-collection-save' \
--header 'skill-access-token: {your-skill-access-token}' \
--header 'Content-Type: application/json' \
--data-raw '{
    "collection_id": 5001,
    "summary": "An AI-generated summary of the blog collection.",
    "blog_type": "Educational Guide",
    "topic": "Outdoor Camping Equipment Knowledge and Selection Guide",
    "category_path": ["Outdoor Recreation", "Camping Equipment", "Camping Gear Selection"],
    "key_topics": ["Camping equipment selection", "Outdoor gear knowledge"],
    "geo_score": 85.5,
    "source_content_hash": "a8f7d9e6c5b4a3219876543210abcdef"
}'

返回结果

code 为 200 表示调用成功;code 不为 200 表示调用失败。

成功响应

{
    "code": 200,
    "data": {
        "id": 4,
        "shop_id": 359,
        "collection_id": 5001,
        "language_code": "en",
        "summary": "An AI-generated summary of the blog collection.",
        "blog_type": "Educational Guide",
        "topic": "Outdoor Camping Equipment Knowledge and Selection Guide",
        "category_path": ["Outdoor Recreation", "Camping Equipment", "Camping Gear Selection"],
        "key_topics": ["Camping equipment selection", "Outdoor gear knowledge"],
        "geo_score": 85.5,
        "source_content_hash": "a8f7d9e6c5b4a3219876543210abcdef",
        "created_at": "2026-08-20 19:41:17",
        "updated_at": "2026-08-20 19:41:39"
    },
    "message": "success"
}

返回字段说明

字段 类型 说明
code int 状态码,200 表示成功
message string 执行结果的文字描述
data object 保存后的博客专辑 GEO 数据(字段同请求参数,并包含 id、shop_id、created_at、updated_at)

注意事项

  1. 保存逻辑:如果传递了 id 且不为空,则通过 id 保存;如果 id 为空,则通过 collection_id 查询是否已存在数据,存在则更新、不存在则创建
  2. collection_id 为必填,其余字段选填
  3. 一个博客专辑可存在多条不同语言的 GEO 数据

  4. collection_id 缺失时返回错误码 100304008(blog collection geo save fail)

Copyright © fecify.com 2025 all right reserved,powered by Gitbook该文件修订时间: 2026-08-23 16:17:25

results matching ""

    No results matching ""