conductor/examples/project-definitions/invalid-template-malformed.json
2026-07-18 10:23:13 -04:00

105 lines
3.0 KiB
JSON

{
"$schema": "../../shared/schemas/conductor-project.schema.json",
"schemaVersion": "0.1.0",
"project": {
"id": "proj_invalid_template_malformed",
"name": "Broken Template — Malformed Syntax",
"description": "Step 16.5 diagnostic example: the REST action contains a malformed template {{components.hostnameInput.value (missing closing braces). The Actions & Bindings inspector should warn. Executing the action in Preview should fail cleanly.",
"pages": [
{
"id": "page_main",
"name": "Main Page",
"order": 0,
"components": [
{
"id": "input_hostname",
"type": "TextInput",
"name": "hostnameInput",
"position": { "x": 40, "y": 40 },
"size": { "width": 320, "height": 40 },
"properties": {
"label": "Hostname",
"placeholder": "e.g. test-host-123",
"defaultValue": "",
"visible": true,
"disabled": false
},
"events": [],
"bindings": []
},
{
"id": "btn_run",
"type": "Button",
"name": "runButton",
"position": { "x": 40, "y": 100 },
"size": { "width": 160, "height": 40 },
"properties": {
"label": "Fetch Data",
"visible": true,
"disabled": false
},
"events": [
{
"event": "onClick",
"actionId": "action_httpbin"
}
],
"bindings": []
},
{
"id": "viewer_result",
"type": "JsonViewer",
"name": "resultsViewer",
"position": { "x": 40, "y": 160 },
"size": { "width": 560, "height": 300 },
"properties": {
"label": "Response",
"visible": true,
"disabled": false
},
"events": [],
"bindings": [
{ "bindingId": "binding_action_to_viewer" }
]
}
],
"events": []
}
],
"actions": [
{
"id": "action_httpbin",
"name": "Httpbin GET (malformed template)",
"description": "Contains a malformed template: {{components.hostnameInput.value — missing closing }}.",
"method": "GET",
"url": "https://httpbin.org/get",
"headers": {
"Accept": "application/json"
},
"queryParameters": {
"hostname": "{{components.hostnameInput.value",
"source": "conductor-step-16-5-malformed"
},
"pathParameters": {},
"bodyTemplate": "",
"authenticationType": "anonymous",
"responseMapping": []
}
],
"bindings": [
{
"id": "binding_action_to_viewer",
"source": "actions.action_httpbin.response",
"target": "components.resultsViewer.value",
"trigger": "onClick"
}
],
"variables": {},
"settings": {}
}
}