-
Notifications
You must be signed in to change notification settings - Fork 21
/
script-connector.json
163 lines (163 loc) · 4.26 KB
/
script-connector.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
{
"$schema" : "https://unpkg.com/@camunda/zeebe-element-templates-json-schema/resources/schema.json",
"name" : "Script Connector",
"id" : "io.camunda.community:script-connector",
"description" : "A connector to execute a script",
"version" : 1,
"category" : {
"id" : "connectors",
"name" : "Connectors"
},
"appliesTo" : [ "bpmn:Task" ],
"elementType" : {
"value" : "bpmn:ServiceTask"
},
"groups" : [ {
"id" : "default",
"label" : "Properties"
}, {
"id" : "output",
"label" : "Output mapping"
}, {
"id" : "error",
"label" : "Error handling"
}, {
"id" : "retries",
"label" : "Retries"
} ],
"properties" : [ {
"value" : "io.camunda.community:script-connector",
"binding" : {
"type" : "zeebe:taskDefinition:type"
},
"type" : "Hidden"
}, {
"id" : "script.type",
"label" : "Type",
"group" : "default",
"binding" : {
"name" : "script.type",
"type" : "zeebe:input"
},
"type" : "Dropdown",
"choices" : [ {
"name" : "Embedded",
"value" : "embedded"
}, {
"name" : "Resource",
"value" : "resource"
} ]
}, {
"id" : "script.embedded",
"label" : "Script",
"description" : "The script to be executed",
"optional" : false,
"constraints" : {
"notEmpty" : true
},
"feel" : "optional",
"group" : "default",
"binding" : {
"name" : "script.embedded",
"type" : "zeebe:input"
},
"condition" : {
"property" : "script.type",
"equals" : "embedded"
},
"type" : "String"
}, {
"id" : "script.language",
"label" : "Script Language",
"description" : "The language the script uses. By default, the ones available are: javascript, groovy, kotlin, mustache",
"optional" : false,
"constraints" : {
"notEmpty" : true
},
"feel" : "optional",
"group" : "default",
"binding" : {
"name" : "script.language",
"type" : "zeebe:input"
},
"condition" : {
"property" : "script.type",
"equals" : "embedded"
},
"type" : "String"
}, {
"id" : "script.resource",
"label" : "Script resource",
"description" : "The resource that should be executed. Should be prefixed with 'classpath:' for a classpath resource, 'file:' for a file system resource. If none of these prefixes matches, it will attempt to load the provided resource as URL.",
"optional" : false,
"constraints" : {
"notEmpty" : true
},
"feel" : "optional",
"group" : "default",
"binding" : {
"name" : "script.resource",
"type" : "zeebe:input"
},
"condition" : {
"property" : "script.type",
"equals" : "resource"
},
"type" : "String"
}, {
"id" : "context",
"label" : "Script context",
"description" : "The context that is available to the script",
"optional" : false,
"feel" : "required",
"group" : "default",
"binding" : {
"name" : "context",
"type" : "zeebe:input"
},
"type" : "String"
}, {
"id" : "resultVariable",
"label" : "Result variable",
"description" : "Name of variable to store the response in",
"group" : "output",
"binding" : {
"key" : "resultVariable",
"type" : "zeebe:taskHeader"
},
"type" : "String"
}, {
"id" : "resultExpression",
"label" : "Result expression",
"description" : "Expression to map the response into process variables",
"feel" : "required",
"group" : "output",
"binding" : {
"key" : "resultExpression",
"type" : "zeebe:taskHeader"
},
"type" : "Text"
}, {
"id" : "errorExpression",
"label" : "Error expression",
"description" : "Expression to handle errors. Details in the <a href=\"https://docs.camunda.io/docs/components/connectors/use-connectors/\" target=\"_blank\">documentation</a>.",
"feel" : "required",
"group" : "error",
"binding" : {
"key" : "errorExpression",
"type" : "zeebe:taskHeader"
},
"type" : "Text"
}, {
"id" : "retryBackoff",
"label" : "Retry backoff",
"description" : "ISO-8601 duration to wait between retries",
"value" : "PT0S",
"group" : "retries",
"binding" : {
"key" : "retryBackoff",
"type" : "zeebe:taskHeader"
},
"type" : "Hidden"
} ]
}