@@ -16,7 +16,55 @@ | |||||
"version": "1.0" | "version": "1.0" | ||||
}, | }, | ||||
"host": "xxxxx.adcms.zhiyingos.cn", | "host": "xxxxx.adcms.zhiyingos.cn", | ||||
"paths": {}, | |||||
"paths": { | |||||
"/api/dataCenter/income/data/list": { | |||||
"post": { | |||||
"description": "数据中心-收益报表-列表", | |||||
"consumes": [ | |||||
"application/json" | |||||
], | |||||
"produces": [ | |||||
"application/json" | |||||
], | |||||
"tags": [ | |||||
"数据中心-----OPEN" | |||||
], | |||||
"summary": "收益报表-列表", | |||||
"parameters": [ | |||||
{ | |||||
"type": "string", | |||||
"description": "秘钥内容", | |||||
"name": "AppSecret", | |||||
"in": "header", | |||||
"required": true | |||||
}, | |||||
{ | |||||
"description": "请求参数", | |||||
"name": "args", | |||||
"in": "body", | |||||
"required": true, | |||||
"schema": { | |||||
"$ref": "#/definitions/md.DataCenterGenerateDataReq" | |||||
} | |||||
} | |||||
], | |||||
"responses": { | |||||
"200": { | |||||
"description": "具体看返回内容 这是data里面的数据", | |||||
"schema": { | |||||
"$ref": "#/definitions/md.DataCenterIncomeDataRes" | |||||
} | |||||
}, | |||||
"400": { | |||||
"description": "具体错误", | |||||
"schema": { | |||||
"$ref": "#/definitions/md.Response" | |||||
} | |||||
} | |||||
} | |||||
} | |||||
} | |||||
}, | |||||
"definitions": { | "definitions": { | ||||
"hdl.WxOpenThirdPartyAppList": { | "hdl.WxOpenThirdPartyAppList": { | ||||
"type": "object", | "type": "object", | ||||
@@ -6,10 +6,10 @@ swag init --parseDependency --parseInternal --output ./docs | |||||
# 提取带有 "open" 标签的路径 | # 提取带有 "open" 标签的路径 | ||||
jq '.paths | with_entries( | jq '.paths | with_entries( | ||||
select( | select( | ||||
(.value.post?.tags? | type == "array" and any(. == "数据中心------OPEN")) or | |||||
(.value.get?.tags? | type == "array" and any(. == "数据中心------OPEN")) or | |||||
(.value.put?.tags? | type == "array" and any(. == "数据中心------OPEN")) or | |||||
(.value.delete?.tags? | type == "array" and any(. == "数据中心------OPEN")) | |||||
(.value.post?.tags? | type == "array" and any(. == "数据中心-----OPEN")) or | |||||
(.value.get?.tags? | type == "array" and any(. == "数据中心-----OPEN")) or | |||||
(.value.put?.tags? | type == "array" and any(. == "数据中心-----OPEN")) or | |||||
(.value.delete?.tags? | type == "array" and any(. == "数据中心-----OPEN")) | |||||
) | ) | ||||
) // {} as $filtered_paths | . * { paths: $filtered_paths }' docs/swagger.json > open_paths.json | ) // {} as $filtered_paths | . * { paths: $filtered_paths }' docs/swagger.json > open_paths.json | ||||