Replace a document's source
set_document_sourceReplace a document's full ArchScript source in one undoable step and return diagnostics; specify a document or omit to use the frontmost.
Instructions
Replaces the whole source of a document (one undoable step in the user's window). Returns diagnostics.
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": {
"source": "<source>"
},
"name": "set_document_source"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| source | Yes | Complete new ArchScript source. | |
| document | No | Document id (e.g. doc1), file name or project name. Omit for the frontmost document. |