373 lines
12 KiB
JSON
373 lines
12 KiB
JSON
{
|
|
"swagger": "2.0",
|
|
"info": {
|
|
"title": "nCov Tracker",
|
|
"contact": {},
|
|
"version": "1.0"
|
|
},
|
|
"paths": {
|
|
"/statistics/china": {
|
|
"get": {
|
|
"produces": [
|
|
"application/json"
|
|
],
|
|
"tags": [
|
|
"Statistics"
|
|
],
|
|
"summary": "china data",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"schema": {
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/definitions/models.GinResponse"
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"data": {
|
|
"$ref": "#/definitions/models.ChinaData"
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/statistics/city/{sort}": {
|
|
"get": {
|
|
"produces": [
|
|
"application/json"
|
|
],
|
|
"tags": [
|
|
"Statistics"
|
|
],
|
|
"summary": "city statistics",
|
|
"parameters": [
|
|
{
|
|
"enum": [
|
|
"today",
|
|
"total",
|
|
"now",
|
|
"default"
|
|
],
|
|
"type": "string",
|
|
"description": "data sorted by",
|
|
"name": "sort",
|
|
"in": "path"
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"schema": {
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/definitions/models.GinResponse"
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"data": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/definitions/models.AreaInfo"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/statistics/country": {
|
|
"get": {
|
|
"produces": [
|
|
"application/json"
|
|
],
|
|
"tags": [
|
|
"Statistics"
|
|
],
|
|
"summary": "country statistics",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"schema": {
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/definitions/models.GinResponse"
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"data": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/definitions/models.AreaInfo"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/statistics/country/child": {
|
|
"get": {
|
|
"produces": [
|
|
"application/json"
|
|
],
|
|
"tags": [
|
|
"Statistics"
|
|
],
|
|
"summary": "country statistics",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"schema": {
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/definitions/models.GinResponse"
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"data": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/definitions/models.AreaInfo"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"/statistics/province/{sort}": {
|
|
"get": {
|
|
"produces": [
|
|
"application/json"
|
|
],
|
|
"tags": [
|
|
"Statistics"
|
|
],
|
|
"summary": "province statistics",
|
|
"parameters": [
|
|
{
|
|
"enum": [
|
|
"today",
|
|
"total",
|
|
"now",
|
|
"default"
|
|
],
|
|
"type": "string",
|
|
"description": "data sorted by",
|
|
"name": "sort",
|
|
"in": "path"
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"schema": {
|
|
"allOf": [
|
|
{
|
|
"$ref": "#/definitions/models.GinResponse"
|
|
},
|
|
{
|
|
"type": "object",
|
|
"properties": {
|
|
"data": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/definitions/models.AreaInfo"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"definitions": {
|
|
"models.AreaInfo": {
|
|
"type": "object",
|
|
"properties": {
|
|
"children": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/definitions/models.AreaInfo"
|
|
}
|
|
},
|
|
"name": {
|
|
"type": "string"
|
|
},
|
|
"today": {
|
|
"$ref": "#/definitions/models.AreaToday"
|
|
},
|
|
"total": {
|
|
"$ref": "#/definitions/models.AreaTotal"
|
|
}
|
|
}
|
|
},
|
|
"models.AreaToday": {
|
|
"type": "object",
|
|
"properties": {
|
|
"confirm": {
|
|
"type": "integer"
|
|
},
|
|
"isUpdate": {
|
|
"type": "boolean"
|
|
}
|
|
}
|
|
},
|
|
"models.AreaTotal": {
|
|
"type": "object",
|
|
"properties": {
|
|
"confirm": {
|
|
"type": "integer"
|
|
},
|
|
"dead": {
|
|
"type": "integer"
|
|
},
|
|
"heal": {
|
|
"type": "integer"
|
|
},
|
|
"nowConfirm": {
|
|
"type": "integer"
|
|
},
|
|
"provinceLocalConfirm": {
|
|
"type": "integer"
|
|
},
|
|
"showHeal": {
|
|
"type": "boolean"
|
|
},
|
|
"showRate": {
|
|
"type": "boolean"
|
|
},
|
|
"wzz": {
|
|
"type": "integer"
|
|
}
|
|
}
|
|
},
|
|
"models.ChinaAdd": {
|
|
"type": "object",
|
|
"properties": {
|
|
"confirm": {
|
|
"type": "integer"
|
|
},
|
|
"dead": {
|
|
"type": "integer"
|
|
},
|
|
"heal": {
|
|
"type": "integer"
|
|
},
|
|
"importedCase": {
|
|
"type": "integer"
|
|
},
|
|
"localConfirm": {
|
|
"type": "integer"
|
|
},
|
|
"localConfirmH5": {
|
|
"type": "integer"
|
|
},
|
|
"noInfect": {
|
|
"type": "integer"
|
|
},
|
|
"noInfectH5": {
|
|
"type": "integer"
|
|
},
|
|
"nowConfirm": {
|
|
"type": "integer"
|
|
},
|
|
"nowSevere": {
|
|
"type": "integer"
|
|
},
|
|
"suspect": {
|
|
"type": "integer"
|
|
}
|
|
}
|
|
},
|
|
"models.ChinaData": {
|
|
"type": "object",
|
|
"properties": {
|
|
"chinaAdd": {
|
|
"$ref": "#/definitions/models.ChinaAdd"
|
|
},
|
|
"chinaTotal": {
|
|
"$ref": "#/definitions/models.ChinaTotal"
|
|
}
|
|
}
|
|
},
|
|
"models.ChinaTotal": {
|
|
"type": "object",
|
|
"properties": {
|
|
"confirm": {
|
|
"type": "integer"
|
|
},
|
|
"dead": {
|
|
"type": "integer"
|
|
},
|
|
"heal": {
|
|
"type": "integer"
|
|
},
|
|
"importedCase": {
|
|
"type": "integer"
|
|
},
|
|
"localConfirm": {
|
|
"type": "integer"
|
|
},
|
|
"localConfirmH5": {
|
|
"type": "integer"
|
|
},
|
|
"local_acc_confirm": {
|
|
"type": "integer"
|
|
},
|
|
"noInfect": {
|
|
"type": "integer"
|
|
},
|
|
"noInfectH5": {
|
|
"type": "integer"
|
|
},
|
|
"nowConfirm": {
|
|
"type": "integer"
|
|
},
|
|
"nowSevere": {
|
|
"type": "integer"
|
|
},
|
|
"showLocalConfirm": {
|
|
"type": "integer"
|
|
},
|
|
"showlocalinfeciton": {
|
|
"type": "integer"
|
|
},
|
|
"suspect": {
|
|
"type": "integer"
|
|
}
|
|
}
|
|
},
|
|
"models.GinResponse": {
|
|
"type": "object",
|
|
"properties": {
|
|
"code": {
|
|
"type": "integer"
|
|
},
|
|
"data": {},
|
|
"msg": {}
|
|
}
|
|
}
|
|
}
|
|
} |