webclient icon indicating copy to clipboard operation
webclient copied to clipboard

module named variables

Open nitzantomer opened this issue 6 years ago • 0 comments

The ability to declare and describe variables in a module scope. Something like:

{
	"name": "aRemoteTest",
	"title": "A (remote) Test!",
	"remote": {
		"origin": "string"
		"base": "$BASE"
	},
	"prompt": [
		{
			"property": "remote.origin",
			"message": "Enter the base url for the service"
		},
		{
			"variable": "$BASE",
			"message": "Enter the base url for the service"
		},
		{
			"variable": "$Y",
			"message": "Enter the Y param"
		}
	],
	"variables": {
		"BASE": "string",
		"Y": "number"
	},
	"commands": {
		"doit": {
			"returns": "number",
			"syntax": [
				"do it (x number)",
				"do it (x number) for (Y number)"
			],
			"endpoint": "/{ Y }/it/x"
		},
		"dothat": {
			"returns": "number",
			"syntax": [
				"do that (x number)",
				"do that (x number) for (Y number)"
			],
			"endpoint": "/{ Y }/that/x"
		}
	}
}

nitzantomer avatar Nov 09 '17 22:11 nitzantomer