set_workspace
Sets the default folder or geodatabase for geoprocessing inputs and outputs, so tools can run without specifying full file paths.
Instructions
Set arcpy.env.workspace — the default location for inputs/outputs when no full path is provided to geoprocessing tools.
Args: workspace: Full path to folder or GDB (e.g. C:/data or C:/data/mydb.gdb)
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": {
"workspace": "<workspace>"
},
"name": "set_workspace"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| workspace | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |