{
    "openapi": "3.0.0",
    "info": {
        "title": "网络取名 - API文档",
        "version": "1.0.0",
        "description": "每次调用都会返回一个朗朗上口的名字，并不是随机组合。可通过sex参数指定性别，默认每1秒更新一次。"
    },
    "servers": [
        {
            "url": "https:\/\/apis.tianapi.com"
        }
    ],
    "paths": {
        "\/cname\/index": {
            "get": {
                "summary": "网络取名",
                "tags": [
                    "网络取名"
                ],
                "description": "根据参数查询适合的网名可指定适合的性别和字数",
                "parameters": [
                    {
                        "name": "key",
                        "in": "query",
                        "description": "API密钥",
                        "required": true,
                        "schema": {
                            "type": "string",
                            "description": "API密钥"
                        }
                    },
                    {
                        "name": "num",
                        "in": "query",
                        "description": "返回数量，默认1，最大50",
                        "required": false,
                        "schema": {
                            "type": "int",
                            "example": 1,
                            "description": "返回数量，默认1，最大50"
                        }
                    },
                    {
                        "name": "sex",
                        "in": "query",
                        "description": "适合的性别，1男性、2女性、3中性[默认]",
                        "required": false,
                        "schema": {
                            "type": "int",
                            "example": 3,
                            "description": "适合的性别，1男性、2女性、3中性[默认]"
                        }
                    },
                    {
                        "name": "word",
                        "in": "query",
                        "description": "名字中包含的字",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "example": "春",
                            "description": "名字中包含的字"
                        }
                    },
                    {
                        "name": "wordnum",
                        "in": "query",
                        "description": "名字的字数，默认2，最大3",
                        "required": false,
                        "schema": {
                            "type": "int",
                            "example": 2,
                            "description": "名字的字数，默认2，最大3"
                        }
                    }
                ],
                "responses": {
                    "200": {
                        "description": "成功响应",
                        "content": {
                            "application\/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "sex": {
                                            "type": "int",
                                            "example": 3,
                                            "description": "适合性别，1男性，2女性，3中性"
                                        },
                                        "naming": {
                                            "type": "string",
                                            "example": "筠竹",
                                            "description": "名字"
                                        },
                                        "wordnum": {
                                            "type": "int",
                                            "example": 2,
                                            "description": "名字字数"
                                        }
                                    }
                                },
                                "example": {
                                    "msg": "success",
                                    "code": 200,
                                    "result": {
                                        "list": [
                                            {
                                                "sex": 3,
                                                "naming": "筠竹",
                                                "wordnum": 2
                                            }
                                        ]
                                    }
                                }
                            }
                        }
                    }
                }
            },
            "post": {
                "summary": "网络取名",
                "tags": [
                    "网络取名"
                ],
                "description": "根据参数查询适合的网名可指定适合的性别和字数",
                "requestBody": {
                    "content": {
                        "application\/x-www-form-urlencoded": {
                            "schema": {
                                "type": "object",
                                "properties": {
                                    "key": {
                                        "type": "string",
                                        "description": "API密钥"
                                    },
                                    "num": {
                                        "type": "int",
                                        "example": 1,
                                        "description": "返回数量，默认1，最大50"
                                    },
                                    "sex": {
                                        "type": "int",
                                        "example": 3,
                                        "description": "适合的性别，1男性、2女性、3中性[默认]"
                                    },
                                    "word": {
                                        "type": "string",
                                        "example": "春",
                                        "description": "名字中包含的字"
                                    },
                                    "wordnum": {
                                        "type": "int",
                                        "example": 2,
                                        "description": "名字的字数，默认2，最大3"
                                    }
                                },
                                "required": [
                                    "key"
                                ]
                            }
                        }
                    }
                },
                "responses": {
                    "200": {
                        "description": "成功响应",
                        "content": {
                            "application\/json": {
                                "schema": {
                                    "type": "object",
                                    "properties": {
                                        "sex": {
                                            "type": "int",
                                            "example": 3,
                                            "description": "适合性别，1男性，2女性，3中性"
                                        },
                                        "naming": {
                                            "type": "string",
                                            "example": "筠竹",
                                            "description": "名字"
                                        },
                                        "wordnum": {
                                            "type": "int",
                                            "example": 2,
                                            "description": "名字字数"
                                        }
                                    }
                                },
                                "example": {
                                    "msg": "success",
                                    "code": 200,
                                    "result": {
                                        "list": [
                                            {
                                                "sex": 3,
                                                "naming": "筠竹",
                                                "wordnum": 2
                                            }
                                        ]
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}