convert_data
Convert data between JSON, YAML, TOML, CSV, XML, and PSD1 files or text; infer the source format from file extensions and return results or write them to an output path.
Instructions
Convert between json, yaml, toml, csv, xml and psd1 (PowerShell data files). Provide either path or text. from_format is inferred from the file extension when omitted. With output_path the result is written there; otherwise it is returned. Reading psd1 needs pwsh (restricted language mode, no code execution); XML uses @attr / #text conventions.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | No | ||
| text | No | ||
| to_format | Yes | ||
| from_format | No | ||
| output_path | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |