Parameters

A parameter is a variable assigned to a value. In other words, the parameter name is the container and the parameter value is the information contained in it. So, parameters usually exist as key-value pairs. They allow you to build a logical script into which actual input data can be passed during an automation.

Type=JSONArray

Parameters are used to store inputs from the user.

We can give multiple Parameters to a particular extension.

KeyTypeDescriptionValue
nameStringName for the parameterName of the parameter. It should be a unique value.
defaultStringDefault value for the parameterValue of the parameter
typeStringData type of the parametertext, text_area, checkbox, hidden
is_mandatoryBooleanConfiguration mandatory or not. default value: falsetrue or false
is_secureBooleanSetting this to "true" prevents user from seeing sensitive information in the parameter when making HTTP request. default value: falsetrue or false
scopestringIt is use for the parameters to allow access to all members of the workspace or specific members alone."org", "user"

Example

If you're using functions in your extension, you can store your function UUID and Version. Now you can call the function every time by the parameters name and version.

SNIPPET

Storing Associated function uuid and version

{
	"modules": {
		"parameters": [{
			"default": "5a748580-7987-4ec5-8545-2101b8e3efcc",
			"name": "add_attachment_function_uuid",
			"is_mandatory": false,
			"type": "hidden"
		}, {
			"default": "1.0",
			"name": "add_attachment_function_version",
			"is_mandatory": false,
			"type": "hidden"
		}]
	}
}

HTTP request SNIPPET to depict usage of parameter value injection:

SNIPPET

URL construction:

/zsapi/team/784663487/extensions/6774743767436743/functions?functionUuid={{parameters.add_attachment_function_uuid}}&version={{parameters.add_attachment_function_version}}

In the function uuid parameter, you can use the parameters value by providing parameters name as in the above API.

Same for the Version also.

parameters – is the default prefix.

add_attachment_function_uuid – parameter name.

add_attachment_function_version – parameter name.

Note: Parameters value will be replaced by Zoho Sprints.