insert_row
Add a new row at any position in CSV data using dictionary, list, or JSON string formats with proper null value handling.
Instructions
Insert new row at specified index with multiple data formats.
Supports dict, list, and JSON string input with null value handling. Returns insertion result with before/after statistics.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| row_index | Yes | Index to insert row at (0-based, -1 to append at end) | |
| data | Yes | Row data as dict, list, or JSON string |
Input Schema (JSON Schema)
{
"properties": {
"data": {
"anyOf": [
{
"additionalProperties": {
"anyOf": [
{
"type": "string"
},
{
"type": "integer"
},
{
"type": "number"
},
{
"type": "boolean"
},
{
"type": "null"
}
]
},
"type": "object"
},
{
"items": {
"anyOf": [
{
"type": "string"
},
{
"type": "integer"
},
{
"type": "number"
},
{
"type": "boolean"
},
{
"type": "null"
}
]
},
"type": "array"
},
{
"type": "string"
}
],
"description": "Row data as dict, list, or JSON string"
},
"row_index": {
"description": "Index to insert row at (0-based, -1 to append at end)",
"type": "integer"
}
},
"required": [
"row_index",
"data"
],
"type": "object"
}