{
  "openapi": "3.0.3",
  "info": {
    "title": "情书诗匠",
    "description": "根据您输入的爱人姓名和情景描述，智能生成符合场景和情感表达的诗句，让您轻松表达爱意，增进彼此情感。每一字每一句都流露出浪漫与深情，让彼此的情感更加深厚，如同细水长流的诗篇，流淌在你们甜蜜的岁月里。",
    "termsOfService": "https://www.showapi.com/helpcenter/view#/4019/2",
    "version": "1.0.0"
  },
  "servers": [
    {
      "url": "https://route.showapi.com"
    }
  ],
  "paths": {
    "/3217-1": {
      "x-pointCode": 1,
      "x-mode": "mapping",
      "x-read-timeout": 10,
      "x-connect-timeout": 5,
      "post": {
        "summary": "创作情诗",
        "description": "用您爱人的名字，定制专属情诗",
        "responses": {
          "200": {
            "description": "成功响应",
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ShowapiResEnvelope"
                    },
                    {
                      "type": "object",
                      "properties": {
                        "showapi_res_body": {
                          "type": "object",
                          "properties": {
                            "ret_code": {
                              "type": "number"
                            },
                            "remark": {
                              "type": "string"
                            },
                            "whole_poem": {
                              "type": "string"
                            },
                            "poem_list": {
                              "type": "array",
                              "items": {
                                "type": "string"
                              }
                            },
                            "meaning": {
                              "type": "string"
                            },
                            "lover_name": {
                              "type": "string"
                            },
                            "poem_name": {
                              "type": "string"
                            }
                          },
                          "description": "业务返回体"
                        }
                      }
                    }
                  ]
                }
              }
            }
          }
        },
        "operationId": "3217_1_POST",
        "parameters": [],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "type": "object",
                "properties": {
                  "lover_name": {
                    "type": "string",
                    "minLength": 6,
                    "maxLength": 32,
                    "description": "爱人名字"
                  },
                  "word_num": {
                    "type": "number",
                    "description": "生成的诗每句字数，5或7"
                  },
                  "sentence_num": {
                    "type": "number",
                    "description": "创作诗句诗 4表示全诗4句话为绝句，8表示全诗八句话为律诗"
                  },
                  "description": {
                    "type": "string",
                    "minLength": 0,
                    "maxLength": 310,
                    "description": "您还可以简要叙述您和您爱人的爱情故事，让情诗更加贴近你们的故事，建议全文长度在90个字以内"
                  },
                  "acrostic_poem": {
                    "type": "number",
                    "description": "是否用爱人名字写藏头诗，默认为是，1表示为是，0表示不用"
                  }
                },
                "required": [
                  "lover_name"
                ]
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "AppKeyAuth": {
        "type": "apiKey",
        "in": "query",
        "name": "appKey",
        "description": "从 ShowAPI 控制台获取的 appKey，管理地址：https://www.showapi.com/console#/myApp"
      }
    },
    "schemas": {
      "ShowapiResEnvelope": {
        "type": "object",
        "description": "ShowAPI 统一返回包裹（业务数据位于 showapi_res_body）",
        "properties": {
          "showapi_res_code": {
            "type": "integer",
            "description": "API 返回的状态码"
          },
          "showapi_res_error": {
            "type": "string",
            "description": "API 返回的错误信息"
          },
          "showapi_res_id": {
            "type": "string",
            "description": "API 请求的唯一标识"
          },
          "showapi_fee_num": {
            "type": "integer",
            "description": "API 调用计费次数"
          }
        }
      }
    }
  },
  "security": [
    {
      "AppKeyAuth": []
    }
  ],
  "externalDocs": {
    "url": "https://www.showapi.com/apiGateway/view/3217?tab=book"
  },
  "x-apiCode": "3217",
  "x-is-own": false,
  "x-is-op": false
}