{
    "openapi": "3.0.0",
    "info": {
        "title": "名言警句 - API文档",
        "version": "1.0.0",
        "description": "随机跳出一句名人格言，是不是很有格调？"
    },
    "servers": [
        {
            "url": "https:\/\/apis.tianapi.com"
        }
    ],
    "paths": {
        "\/dictum\/index": {
            "get": {
                "summary": "名言警句查询",
                "tags": [
                    "名言警句"
                ],
                "description": "随机返回指定数量的名言警句",
                "parameters": [
                    {
                        "name": "key",
                        "in": "query",
                        "description": "API密钥",
                        "required": true,
                        "schema": {
                            "type": "string",
                            "description": "API密钥"
                        }
                    },
                    {
                        "name": "num",
                        "in": "query",
                        "description": "返回数量",
                        "required": true,
                        "schema": {
                            "type": "int",
                            "example": 10,
                            "description": "返回数量"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "成功响应",
                        "content": {
                            "application\/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "id": {
                                            "type": "int",
                                            "example": 9583,
                                            "description": "数据ID"
                                        },
                                        "mrname": {
                                            "type": "string",
                                            "example": "爱献生",
                                            "description": "名人姓名"
                                        },
                                        "content": {
                                            "type": "string",
                                            "example": "仅是天才不能成为作家，因为书的背后极需要作家失格",
                                            "description": "内容"
                                        }
                                    }
                                },
                                "example": {
                                    "msg": "success",
                                    "code": 200,
                                    "result": {
                                        "list": [
                                            {
                                                "id": 9583,
                                                "mrname": "爱献生",
                                                "content": "仅是天才不能成为作家，因为书的背后极需要作家失格"
                                            },
                                            {
                                                "id": 9583,
                                                "mrname": "莎士比亚",
                                                "content": "微贱往往是非野心的阶梯，凭借着它一步步爬上了高处；当他一旦登上了最高的一级之后，他便不再回顾那梯子；他的眼光彩夺目仰望云宵，瞧不起他从前所恃为凭借的低下的阶梯。"
                                            },
                                            {
                                                "id": 9583,
                                                "mrname": "罗曼·罗兰",
                                                "content": "以思想和力量来胜过别人的人，我并不称他们为英雄，只有以心灵使自己更伟大的人们，我才称为英雄。"
                                            }
                                        ]
                                    }
                                }
                            }
                        }
                    }
                }
            },
            "post": {
                "summary": "名言警句查询",
                "tags": [
                    "名言警句"
                ],
                "description": "随机返回指定数量的名言警句",
                "requestBody": {
                    "content": {
                        "application\/x-www-form-urlencoded": {
                            "schema": {
                                "type": "object",
                                "properties": {
                                    "key": {
                                        "type": "string",
                                        "description": "API密钥"
                                    },
                                    "num": {
                                        "type": "int",
                                        "example": 10,
                                        "description": "返回数量"
                                    }
                                },
                                "required": [
                                    "key",
                                    "num"
                                ]
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "成功响应",
                        "content": {
                            "application\/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "id": {
                                            "type": "int",
                                            "example": 9583,
                                            "description": "数据ID"
                                        },
                                        "mrname": {
                                            "type": "string",
                                            "example": "爱献生",
                                            "description": "名人姓名"
                                        },
                                        "content": {
                                            "type": "string",
                                            "example": "仅是天才不能成为作家，因为书的背后极需要作家失格",
                                            "description": "内容"
                                        }
                                    }
                                },
                                "example": {
                                    "msg": "success",
                                    "code": 200,
                                    "result": {
                                        "list": [
                                            {
                                                "id": 9583,
                                                "mrname": "爱献生",
                                                "content": "仅是天才不能成为作家，因为书的背后极需要作家失格"
                                            },
                                            {
                                                "id": 9583,
                                                "mrname": "莎士比亚",
                                                "content": "微贱往往是非野心的阶梯，凭借着它一步步爬上了高处；当他一旦登上了最高的一级之后，他便不再回顾那梯子；他的眼光彩夺目仰望云宵，瞧不起他从前所恃为凭借的低下的阶梯。"
                                            },
                                            {
                                                "id": 9583,
                                                "mrname": "罗曼·罗兰",
                                                "content": "以思想和力量来胜过别人的人，我并不称他们为英雄，只有以心灵使自己更伟大的人们，我才称为英雄。"
                                            }
                                        ]
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}