generate_ui_schema
Generate Zod schemas and live UI previews by mapping messy API JSON to Vue/React Design System component props for type-safe frontend integration.
Instructions
Maps messy API JSON to Vue/React Design System component props using Zod schema. Returns both the generated schema code and a live UI preview. Optionally saves preview as HTML file.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"api_json_sample": "<api_json_sample>",
"vue_component_code": "<vue_component_code>"
},
"name": "generate_ui_schema"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| api_json_sample | Yes | A sample JSON response from the backend API | |
| vue_component_code | Yes | The Vue component code from the Design System | |
| output_path | No | Optional path to save the HTML preview file (e.g., ./preview.html) |