Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/fortran/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Swagger 基于json模式生成招摇过市路由_Swagger_Jsonschema_Swagger 2.0 - Fatal编程技术网

Swagger 基于json模式生成招摇过市路由

Swagger 基于json模式生成招摇过市路由,swagger,jsonschema,swagger-2.0,Swagger,Jsonschema,Swagger 2.0,我只有一个resturlapi(我不能在api中添加swagger文档)和我的json数据模型shcema。 我希望能够基于我的json数据模型schema生成一个客户端,这样我就可以从我的应用程序与我的restfulapi对话 如何基于shema生成swagger客户端路由? 假设我有这么简单的模式: { "$schema": "http://json-schema.org/draft-04/schema#", "type": "object", "properties": {

我只有一个
resturlapi
(我不能在api中添加swagger文档)和我的
json数据模型
shcema。 我希望能够基于我的
json数据模型
schema生成一个客户端,这样我就可以从我的应用程序与我的
restfulapi
对话

如何基于shema生成swagger客户端路由? 假设我有这么简单的模式:

{
  "$schema": "http://json-schema.org/draft-04/schema#",
  "type": "object",
  "properties": {
    "house": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "number"
          },
          "type": {
            "type": "string"
          }
        }
      }
    }
  }
}
如何生成/添加
get/put/delete
swagger路由到我的模式,以便为我的
restfulapi
生成适当的客户端