API 參考
Blog tags
Management API: GET /sites/{id}/blog/tags, POST /sites/{id}/blog/tags
List this website's blog tags (id, slug, name, counts.posts). Use the ids in posts.create / posts.update tagIds. Errors: FORBIDDEN, INVALID_CURSOR.
Parameters
idstring · pathrequiredWebsite id. Get it from sites.list or from sites.create.
limitinteger · queryMaximum number of items to return, 1–100. Defaults to 20.
cursorstring · queryOpaque cursor from the previous page's nextCursor. Omit for the first page.
Response 200
dataobject[]requireddata[].idstringrequireddata[].slugstringrequireddata[].namestringrequireddata[].countsobjectrequiredPublished post count.
data[].counts.postsintegerrequiredNumber of published posts in this taxonomy.
hasMorebooleanrequiredTrue when another page exists; pass nextCursor to fetch it.
nextCursorstring | nullrequiredCursor for the next page, or null on the last page.
Errors
FORBIDDEN403INVALID_CURSOR400
MCP tool blog_tags_list
curl -X GET "https://app.kanorio.com/api/v1/sites/{id}/blog/tags" \
-H "Authorization: Bearer $KANORIO_TOKEN"{
"data": [
{
"id": "tag_example01",
"slug": "sourdough",
"name": "Sourdough",
"counts": {
"posts": 3
}
}
],
"hasMore": false,
"nextCursor": null
}Create a blog tag (name, optional slug). Returns the created tag with its id for use in posts.create / posts.update tagIds. Errors: FORBIDDEN, VALIDATION, SLUG_TAKEN.
Parameters
idstring · pathrequiredWebsite id. Get it from sites.list or from sites.create.
Request body
namestringrequiredDisplay name of the tag.
slugstringURL slug; generated automatically from name when omitted.
Response 201
tagobjectrequiredtag.idstringrequiredtag.slugstringrequiredtag.namestringrequiredtag.countsobjectrequiredPublished post count.
tag.counts.postsintegerrequiredNumber of published posts in this taxonomy.
Errors
FORBIDDEN403VALIDATION400SLUG_TAKEN409
MCP tool blog_tags_create
curl -X POST "https://app.kanorio.com/api/v1/sites/{id}/blog/tags" \
-H "Authorization: Bearer $KANORIO_TOKEN" \
-H "Content-Type: application/json" \
-d '{"name":"Sourdough"}'{
"tag": {
"id": "tag_example01",
"slug": "sourdough",
"name": "Sourdough",
"counts": {
"posts": 0
}
}
}