{
    "openapi": "3.0.0",
    "info": {
        "title": "古代情诗 - API文档",
        "version": "1.0.0",
        "description": "愿得一心人，白头不相离。随机返回中国古代那些浪漫唯美的情诗。"
    },
    "servers": [
        {
            "url": "https:\/\/apis.tianapi.com"
        }
    ],
    "paths": {
        "\/qingshi\/index": {
            "get": {
                "summary": "古代情诗查询",
                "tags": [
                    "古代情诗"
                ],
                "description": "随机查询返回一句古代情诗",
                "parameters": [
                    {
                        "name": "key",
                        "in": "query",
                        "description": "API密钥",
                        "required": true,
                        "schema": {
                            "type": "string",
                            "description": "API密钥"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "成功响应",
                        "content": {
                            "application\/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "author": {
                                            "type": "string",
                                            "example": "卓文君",
                                            "description": "作者"
                                        },
                                        "source": {
                                            "type": "string",
                                            "example": "白头吟",
                                            "description": "来源"
                                        },
                                        "content": {
                                            "type": "string",
                                            "example": "愿得一心人，白头不相离。",
                                            "description": "情诗"
                                        }
                                    }
                                },
                                "example": {
                                    "msg": "success",
                                    "code": 200,
                                    "result": {
                                        "author": "卓文君",
                                        "source": "白头吟",
                                        "content": "愿得一心人，白头不相离。"
                                    }
                                }
                            }
                        }
                    }
                }
            },
            "post": {
                "summary": "古代情诗查询",
                "tags": [
                    "古代情诗"
                ],
                "description": "随机查询返回一句古代情诗",
                "requestBody": {
                    "content": {
                        "application\/x-www-form-urlencoded": {
                            "schema": {
                                "type": "object",
                                "properties": {
                                    "key": {
                                        "type": "string",
                                        "description": "API密钥"
                                    }
                                },
                                "required": [
                                    "key"
                                ]
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "成功响应",
                        "content": {
                            "application\/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "author": {
                                            "type": "string",
                                            "example": "卓文君",
                                            "description": "作者"
                                        },
                                        "source": {
                                            "type": "string",
                                            "example": "白头吟",
                                            "description": "来源"
                                        },
                                        "content": {
                                            "type": "string",
                                            "example": "愿得一心人，白头不相离。",
                                            "description": "情诗"
                                        }
                                    }
                                },
                                "example": {
                                    "msg": "success",
                                    "code": 200,
                                    "result": {
                                        "author": "卓文君",
                                        "source": "白头吟",
                                        "content": "愿得一心人，白头不相离。"
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}