Add a field to a kind
add_fieldAdd a property to a content type, updating its schema and table so existing records get the default value. Returns how many records were affected.
Instructions
Add a property to a content type, for everyone: a due date on notes, a priority on tasks. The type's schema file and its table change at once, and every record has the field from then on: the ones already there read as its default (nothing, when it has none), and the answer says how many there are and what they got. Adding is safe; nothing else they hold changes.
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": {
"type": "<type>",
"name": "<name>",
"kind": "<kind>"
},
"name": "add_field"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| to | No | For ref: the content type it points at. | |
| kind | Yes | string is a line of text, text a paragraph, markdown structured text, datetime a day or a moment, repeat how often it happens again (every Tuesday), enum one of values, list several strings, ref another record's id (say which type in to), bool yes or no. | |
| name | Yes | Lowercase letters, digits and underscores, such as due or priority. | |
| type | Yes | The content type to add the field to. | |
| values | No | For enum: the choices. | |
| default | No | What a record has when nothing was given. | |
| required | No | ||
| description | No | What the field is for, in a few words: shown to people and to you. |