@hyperone/cli-core
Advanced tools
Comparing version 1.0.7 to 1.0.8
@@ -63,9 +63,17 @@ import fetch from 'node-fetch'; | ||
getTitle: () => spec.info.title, | ||
getDetail: prefix => Object | ||
.entries(spec.paths) | ||
.filter(([path]) => path.match(new RegExp(`${prefix}/\{[A-Za-z_]+\}$`))) | ||
.map(([path, endpoint]) => ({ | ||
endpoint, | ||
path, | ||
})), | ||
getActions: (prefix) => Object | ||
.entries(spec.paths) | ||
.filter(([path]) => path.match(new RegExp(`${prefix}/actions/(.+?)`))) | ||
.map(([path]) => ({ | ||
.map(([path, endpoint]) => ({ | ||
name: path.split('/').pop(), | ||
endpoint, | ||
path, | ||
})), | ||
}; |
{ | ||
"name": "@hyperone/cli-core", | ||
"version": "1.0.7", | ||
"version": "1.0.8", | ||
"description": "", | ||
@@ -8,3 +8,3 @@ "main": "index.js", | ||
"@apidevtools/json-schema-ref-parser": "^9.0.3", | ||
"@hyperone/cli-framework": "^1.0.6", | ||
"@hyperone/cli-framework": "^1.0.8", | ||
"camel-case": "^4.1.1", | ||
@@ -30,3 +30,3 @@ "command-line-args": "^5.1.1", | ||
"license": "MIT", | ||
"gitHead": "b51a930fcf67d351fb8243c40b64e8e17d80c10b" | ||
"gitHead": "a3a4d4cf6ce542757ec9adbc129f9b93bea9380e" | ||
} |
24736
622