added interactive generation
parent
2d0708493f
commit
6bb0f6ad05
|
@ -34,6 +34,7 @@ module.exports.start = function(schema, cb) {
|
||||||
if(!line && currentQuestion.default) {
|
if(!line && currentQuestion.default) {
|
||||||
line = currentQuestion.default(results)
|
line = currentQuestion.default(results)
|
||||||
}
|
}
|
||||||
|
line = line.length && line || undefined
|
||||||
results[currentQuestion.name] = line;
|
results[currentQuestion.name] = line;
|
||||||
idx++;
|
idx++;
|
||||||
if(idx >= schema.length) {
|
if(idx >= schema.length) {
|
||||||
|
|
|
@ -0,0 +1,45 @@
|
||||||
|
{
|
||||||
|
"name": "test",
|
||||||
|
"description": "Hadasd.",
|
||||||
|
"info": {
|
||||||
|
"contact": {
|
||||||
|
"name": "Niclas Thobaben",
|
||||||
|
"email": "info@nclazz.de",
|
||||||
|
"url": "nclazz.de"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"imports": [],
|
||||||
|
"headers": [],
|
||||||
|
"enums": {},
|
||||||
|
"interfaces": {},
|
||||||
|
"models": {
|
||||||
|
"healthcheck": {
|
||||||
|
"description": "A simple response indicating the health status of a service.",
|
||||||
|
"fields": [
|
||||||
|
{
|
||||||
|
"name": "status",
|
||||||
|
"type": "string"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"unions": {},
|
||||||
|
"resources": {
|
||||||
|
"healthcheck": {
|
||||||
|
"path": "/_internal_/healthcheck",
|
||||||
|
"operations": {
|
||||||
|
"method": "GET",
|
||||||
|
"path": "/healthcheck",
|
||||||
|
"description": "Simple healthcheck endpoint to test the status of the service.",
|
||||||
|
"responses": {
|
||||||
|
"200": {
|
||||||
|
"type": "healthcheck",
|
||||||
|
"description": "Get the current health status of the service."
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"attributes": {},
|
||||||
|
"annotations": {}
|
||||||
|
}
|
Loading…
Reference in New Issue