输入文字,即可生成有趣的藏头诗,体验不一样的诗词文化,精准生成平仄诗句。
| 参数名 | 类型 | 必填 | 说明 | 示例 |
|---|---|---|---|---|
| key | string | 是 | 接口调用密钥 | |
| q | string | 是 | 藏头字串(1-12 个字,如「慕名而来」) | 慕名而来 |
| lines | string | 否 | 每句字数:5(五言)或 7(七言),默认 7 | 7 |
| pingze | string | 否 | 平仄优化开关:1 开(默认)/ 0 关 | 1 |
[
{
"name": "key",
"type": "string",
"required": true,
"description": "接口调用密钥",
"example": ""
},
{
"name": "q",
"type": "string",
"required": true,
"description": "藏头字串(1-12 个字,如「慕名而来」)",
"example": "慕名而来"
},
{
"name": "lines",
"type": "string",
"required": false,
"description": "每句字数:5(五言)或 7(七言),默认 7",
"example": "7"
},
{
"name": "pingze",
"type": "string",
"required": false,
"description": "平仄优化开关:1 开(默认)/ 0 关",
"example": "1"
}
]
{
"openapi": "3.1.1",
"info": {
"title": "藏头诗",
"description": "输入文字,即可生成有趣的藏头诗,体验不一样的诗词文化,精准生成平仄诗句。",
"version": "1.0.0"
},
"paths": {
"/v1/hidden_poem.php": {
"get": {
"summary": "藏头诗",
"description": "输入文字,即可生成有趣的藏头诗,体验不一样的诗词文化,精准生成平仄诗句。",
"parameters": [
{
"name": "key",
"in": "query",
"required": true,
"schema": {
"type": "string"
},
"description": "接口调用密钥"
},
{
"name": "q",
"in": "query",
"required": true,
"schema": {
"type": "string",
"example": "慕名而来"
},
"description": "藏头字串(1-12 个字,如「慕名而来」)"
},
{
"name": "lines",
"in": "query",
"required": false,
"schema": {
"type": "string",
"example": "7"
},
"description": "每句字数:5(五言)或 7(七言),默认 7"
},
{
"name": "pingze",
"in": "query",
"required": false,
"schema": {
"type": "string",
"example": "1"
},
"description": "平仄优化开关:1 开(默认)/ 0 关"
}
],
"responses": {
"200": {
"description": "成功",
"content": {
"application/json": {
"schema": {
"type": "object"
}
}
}
}
}
},
"post": {
"summary": "藏头诗",
"description": "输入文字,即可生成有趣的藏头诗,体验不一样的诗词文化,精准生成平仄诗句。",
"parameters": [
{
"name": "key",
"in": "query",
"required": true,
"schema": {
"type": "string"
},
"description": "接口调用密钥"
},
{
"name": "q",
"in": "query",
"required": true,
"schema": {
"type": "string",
"example": "慕名而来"
},
"description": "藏头字串(1-12 个字,如「慕名而来」)"
},
{
"name": "lines",
"in": "query",
"required": false,
"schema": {
"type": "string",
"example": "7"
},
"description": "每句字数:5(五言)或 7(七言),默认 7"
},
{
"name": "pingze",
"in": "query",
"required": false,
"schema": {
"type": "string",
"example": "1"
},
"description": "平仄优化开关:1 开(默认)/ 0 关"
}
],
"responses": {
"200": {
"description": "成功",
"content": {
"application/json": {
"schema": {
"type": "object"
}
}
}
}
}
}
}
},
"servers": [
{
"url": "https://xiaoapi.cn",
"description": "当前访问入口(https)"
}
]
}
{
"code": 0,
"q": "慕名而来",
"lines": 7,
"pingze": 1,
"message": "藏头诗生成成功",
"poem": [
"慕白云盛世吉祥",
"名碧波薄雾明月",
"而今迈步从头越",
"来是空言去绝踪"
],
"poem_txt": "慕白云盛世吉祥\n名碧波薄雾明月\n而今迈步从头越\n来是空言去绝踪",
"data": {
"lines": [
{
"char": "慕",
"phrase": "慕白云盛世吉祥",
"type": "chain",
"pingze": "仄平平仄仄平平",
"note": "由常用意象词缀合而成",
"words": [
"白云",
"盛世",
"吉祥"
]
},
{
"char": "名",
"phrase": "名碧波薄雾明月",
"type": "chain",
"pingze": "平仄平平仄平仄",
"note": "由常用意象词缀合而成",
"words": [
"碧波",
"薄雾",
"明月"
]
},
{
"char": "而",
"phrase": "而今迈步从头越",
"type": "poem",
"pingze": "平平仄仄平平仄",
"note": "毛泽东《忆秦娥·娄山关》"
},
{
"char": "来",
"phrase": "来是空言去绝踪",
"type": "poem",
"pingze": "平仄平平仄平平",
"note": "李商隐《无题》"
}
]
}
}
暂无详细文档
暂无代码示例。管理员可在后台用 AI 生成或手动编写。
// 结果将在此处显示
生效日期:2026年7月22日
欢迎使用 xiaoapi.cn(以下简称"本平台")。在使用本平台提供的 API 服务(以下简称"本服务")前,请务必仔细阅读并充分理解本免责声明。您以任何方式调用、访问或使用本服务,即视为您已阅读、理解并同意接受本声明的全部内容。
本平台作为 API 技术服务的提供方,仅提供技术接口与数据分发服务。本声明的目的在于明确平台与用户之间的责任边界,督促用户合法、合规地使用本服务,防范违法违规行为的发生。
用户在使用本服务时,明确禁止从事以下行为:
在法律法规允许的最大范围内,本平台对以下情形不承担责任:
因用户违反本声明或相关法律法规,导致本平台及其关联方、合作方遭受任何损失(包括但不限于赔偿款、罚款、律师费、诉讼费等),用户同意向本平台及相关方承担全部赔偿责任。
本平台有权根据法律法规变化、业务调整或监管要求,随时修改本声明。修改后的声明将在本页面公布,自公布之日起生效。您继续使用本服务,即视为接受更新后的声明。
如您对本声明有任何疑问,或发现他人存在违规使用本服务的行为,欢迎通过本平台公示的联系方式与我们联系,我们将及时处理。