|
115 | 115 | "type": "array", |
116 | 116 | "description": "Arguments for the runtime command (docker, npx, etc.)", |
117 | 117 | "items": { |
118 | | - "oneOf": [ |
119 | | - { |
120 | | - "type": "object", |
121 | | - "required": [ |
122 | | - "type", |
123 | | - "value_hint" |
124 | | - ], |
125 | | - "properties": { |
126 | | - "type": { |
127 | | - "const": "positional" |
128 | | - }, |
129 | | - "value_hint": { |
130 | | - "type": "string", |
131 | | - "description": "An identifier-like hint for the value. This is not part of the command line, but can be used by client configuration and to provide hints to users." |
132 | | - }, |
133 | | - "description": { |
134 | | - "type": "string" |
135 | | - }, |
136 | | - "value": { |
137 | | - "type": "string", |
138 | | - "description": "The default value for the input. If this is not set, the user may be prompted to provide a value.\n\nIdentifiers wrapped in `{curly_braces}` will be replaced with the corresponding properties from the input `variables` map. If an identifier in braces is not found in `variables`, or if `variables` is not provided, the `{curly_braces}` substring should remain unchanged." |
139 | | - }, |
140 | | - "default": { |
141 | | - "type": "string" |
142 | | - }, |
143 | | - "is_required": { |
144 | | - "type": "boolean", |
145 | | - "default": false |
146 | | - }, |
147 | | - "is_repeated": { |
148 | | - "type": "boolean", |
149 | | - "default": false |
150 | | - } |
151 | | - } |
152 | | - }, |
153 | | - { |
154 | | - "type": "object", |
155 | | - "required": [ |
156 | | - "type", |
157 | | - "name" |
158 | | - ], |
159 | | - "properties": { |
160 | | - "type": { |
161 | | - "const": "named" |
162 | | - }, |
163 | | - "name": { |
164 | | - "type": "string", |
165 | | - "description": "Flag name including dashes" |
166 | | - }, |
167 | | - "description": { |
168 | | - "type": "string" |
169 | | - }, |
170 | | - "value": { |
171 | | - "type": "string", |
172 | | - "description": "The default value for the input. If this is not set, the user may be prompted to provide a value.\n\nIdentifiers wrapped in `{curly_braces}` will be replaced with the corresponding properties from the input `variables` map. If an identifier in braces is not found in `variables`, or if `variables` is not provided, the `{curly_braces}` substring should remain unchanged." |
173 | | - }, |
174 | | - "is_required": { |
175 | | - "type": "boolean", |
176 | | - "default": false |
177 | | - }, |
178 | | - "is_repeated": { |
179 | | - "type": "boolean", |
180 | | - "default": false |
181 | | - }, |
182 | | - "variables": { |
183 | | - "type": "object", |
184 | | - "description": "A map of variable names to their values. Keys in the input `value` that are wrapped in `{curly_braces}` will be replaced with the corresponding variable values.", |
185 | | - "additionalProperties": { |
186 | | - "type": "object", |
187 | | - "properties": { |
188 | | - "description": { |
189 | | - "type": "string" |
190 | | - }, |
191 | | - "format": { |
192 | | - "type": "string", |
193 | | - "description": "Specifies the input format. Supported values include `filepath`, which should be interpreted as a file on the user's filesystem.\n\nWhen the input is converted to a string, booleans should be represented by the strings \"true\" and \"false\", and numbers should be represented as decimal values.", |
194 | | - "enum": [ |
195 | | - "string", |
196 | | - "number", |
197 | | - "boolean", |
198 | | - "filepath" |
199 | | - ], |
200 | | - "default": "string" |
201 | | - }, |
202 | | - "is_required": { |
203 | | - "type": "boolean" |
204 | | - }, |
205 | | - "default": { |
206 | | - "type": "string" |
207 | | - } |
208 | | - } |
209 | | - } |
210 | | - } |
211 | | - } |
212 | | - } |
213 | | - ] |
| 118 | + "$ref": "#/$defs/argument" |
214 | 119 | } |
215 | 120 | }, |
216 | 121 | "package_arguments": { |
|
224 | 129 | "type": "array", |
225 | 130 | "description": "Environment variables to set", |
226 | 131 | "items": { |
227 | | - "type": "object", |
228 | | - "required": [ |
229 | | - "name" |
230 | | - ], |
231 | | - "properties": { |
232 | | - "name": { |
233 | | - "type": "string", |
234 | | - "description": "Variable name" |
235 | | - }, |
236 | | - "description": { |
237 | | - "type": "string" |
238 | | - }, |
239 | | - "default": { |
240 | | - "type": "string" |
241 | | - }, |
242 | | - "is_required": { |
243 | | - "type": "boolean", |
244 | | - "default": false |
245 | | - }, |
246 | | - "is_secret": { |
247 | | - "type": "boolean", |
248 | | - "default": false |
249 | | - } |
250 | | - } |
| 132 | + "$ref": "#/$defs/key_value_input" |
251 | 133 | } |
252 | 134 | } |
253 | 135 | } |
|
282 | 164 | "type": "array", |
283 | 165 | "description": "HTTP headers to include", |
284 | 166 | "items": { |
285 | | - "type": "object", |
286 | | - "required": [ |
287 | | - "name" |
288 | | - ], |
289 | | - "properties": { |
290 | | - "name": { |
291 | | - "type": "string" |
292 | | - }, |
293 | | - "value": { |
294 | | - "type": "string" |
295 | | - }, |
296 | | - "description": { |
297 | | - "type": "string" |
298 | | - }, |
299 | | - "is_required": { |
300 | | - "type": "boolean" |
301 | | - }, |
302 | | - "is_secret": { |
303 | | - "type": "boolean" |
304 | | - } |
305 | | - } |
| 167 | + "$ref": "#/$defs/key_value_input" |
306 | 168 | } |
307 | 169 | } |
308 | 170 | } |
309 | 171 | } |
310 | 172 | } |
311 | 173 | }, |
312 | 174 | "$defs": { |
| 175 | + "variable_map": { |
| 176 | + "type": "object", |
| 177 | + "description": "A map of variable names to their values. Keys in the input `value` that are wrapped in `{curly_braces}` will be replaced with the corresponding variable values.", |
| 178 | + "additionalProperties": { |
| 179 | + "type": "object", |
| 180 | + "properties": { |
| 181 | + "description": { |
| 182 | + "type": "string" |
| 183 | + }, |
| 184 | + "format": { |
| 185 | + "type": "string", |
| 186 | + "description": "Specifies the input format. Supported values include `filepath`, which should be interpreted as a file on the user's filesystem.\n\nWhen the input is converted to a string, booleans should be represented by the strings \"true\" and \"false\", and numbers should be represented as decimal values.", |
| 187 | + "enum": [ |
| 188 | + "string", |
| 189 | + "number", |
| 190 | + "boolean", |
| 191 | + "filepath" |
| 192 | + ], |
| 193 | + "default": "string" |
| 194 | + }, |
| 195 | + "is_required": { |
| 196 | + "type": "boolean" |
| 197 | + }, |
| 198 | + "default": { |
| 199 | + "type": "string" |
| 200 | + } |
| 201 | + } |
| 202 | + } |
| 203 | + }, |
| 204 | + "key_value_input": { |
| 205 | + "type": "object", |
| 206 | + "required": [ |
| 207 | + "name" |
| 208 | + ], |
| 209 | + "properties": { |
| 210 | + "name": { |
| 211 | + "type": "string", |
| 212 | + "description": "Variable name" |
| 213 | + }, |
| 214 | + "description": { |
| 215 | + "type": "string" |
| 216 | + }, |
| 217 | + "default": { |
| 218 | + "type": "string" |
| 219 | + }, |
| 220 | + "is_required": { |
| 221 | + "type": "boolean", |
| 222 | + "default": false |
| 223 | + }, |
| 224 | + "is_secret": { |
| 225 | + "type": "boolean", |
| 226 | + "default": false |
| 227 | + } |
| 228 | + } |
| 229 | + }, |
313 | 230 | "argument": { |
314 | 231 | "oneOf": [ |
315 | 232 | { |
|
323 | 240 | "const": "positional" |
324 | 241 | }, |
325 | 242 | "value_hint": { |
326 | | - "type": "string" |
| 243 | + "type": "string", |
| 244 | + "description": "An identifier-like hint for the value. This is not part of the command line, but can be used by client configuration and to provide hints to users." |
327 | 245 | }, |
328 | 246 | "description": { |
329 | 247 | "type": "string" |
330 | 248 | }, |
331 | 249 | "value": { |
332 | | - "type": "string" |
| 250 | + "type": "string", |
| 251 | + "description": "The default value for the input. If this is not set, the user may be prompted to provide a value.\n\nIdentifiers wrapped in `{curly_braces}` will be replaced with the corresponding properties from the input `variables` map. If an identifier in braces is not found in `variables`, or if `variables` is not provided, the `{curly_braces}` substring should remain unchanged." |
333 | 252 | }, |
334 | 253 | "default": { |
335 | 254 | "type": "string" |
336 | 255 | }, |
337 | 256 | "is_required": { |
338 | | - "type": "boolean" |
| 257 | + "type": "boolean", |
| 258 | + "default": false |
339 | 259 | }, |
340 | 260 | "is_repeated": { |
341 | | - "type": "boolean" |
| 261 | + "type": "boolean", |
| 262 | + "default": false |
| 263 | + }, |
| 264 | + "variables": { |
| 265 | + "$ref": "#/$defs/variable_map" |
342 | 266 | } |
343 | 267 | } |
344 | 268 | }, |
|
353 | 277 | "const": "named" |
354 | 278 | }, |
355 | 279 | "name": { |
356 | | - "type": "string" |
| 280 | + "type": "string", |
| 281 | + "description": "Flag name including dashes" |
357 | 282 | }, |
358 | 283 | "description": { |
359 | 284 | "type": "string" |
360 | 285 | }, |
361 | 286 | "value": { |
362 | | - "type": "string" |
| 287 | + "type": "string", |
| 288 | + "description": "The default value for the input. If this is not set, the user may be prompted to provide a value.\n\nIdentifiers wrapped in `{curly_braces}` will be replaced with the corresponding properties from the input `variables` map. If an identifier in braces is not found in `variables`, or if `variables` is not provided, the `{curly_braces}` substring should remain unchanged." |
363 | 289 | }, |
364 | 290 | "is_required": { |
365 | | - "type": "boolean" |
| 291 | + "type": "boolean", |
| 292 | + "default": false |
366 | 293 | }, |
367 | 294 | "is_repeated": { |
368 | | - "type": "boolean" |
| 295 | + "type": "boolean", |
| 296 | + "default": false |
| 297 | + }, |
| 298 | + "variables": { |
| 299 | + "$ref": "#/$defs/variable_map" |
369 | 300 | } |
370 | 301 | } |
371 | 302 | } |
|
0 commit comments