add_field
Adds a new field to an ArcGIS Pro layer or table, specifying name, type, and properties like alias, domain, and length.
Instructions
Add a field to a layer or table.
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": {
"layer_name": "<layer_name>",
"field_name": "<field_name>"
},
"name": "add_field"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| map_name | No | Map to act on; defaults to the active map. | |
| nullable | No | NULLABLE or NON_NULLABLE. | NULLABLE |
| field_name | Yes | New field name. | |
| field_type | No | TEXT, LONG, SHORT, DOUBLE, FLOAT, DATE, BIGINTEGER, GUID or BLOB. | TEXT |
| layer_name | Yes | Layer or table name as shown by get_layers, or a full dataset path. | |
| field_alias | No | Display alias. | |
| field_scale | No | Numeric scale. | |
| field_domain | No | Attribute domain to assign. | |
| field_length | No | Length for TEXT fields. | |
| field_precision | No | Numeric precision. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |