JSONC — 18 Operations for AI Agents
JSONC is the configuration dialect of the editor world — VS Code settings, `tsconfig`, tool configs that allow comments. act101 navigates keys and values structurally, comments intact, so agents change settings without flattening human context.
This page is the canonical reference an AI coding agent uses to refactor, query, and analyze JSONC code through the act MCP server. 18 operations available: 0 refactor, 18 query, 0 analysis. Each operation is callable from Claude Code, Cursor, Codex, OpenCode, or any MCP-compatible agent host. Click any operation for a stable anchor link suitable for citation.
Worked JSONC examples
act101 reads a JSONC file's // comments as whitespace and walks the object tree beneath them: every key whose value is itself an object surfaces in the skeleton as a module declaration, at whatever depth it sits, so a nested exporter config gets its own entry alongside its parent. symbols goes further, listing every key in the file, comments excluded, as a field. The unit of structure in this grammar is still the object key, but unlike plain JSON's skeleton, JSONC's descends past the top level into nested objects, stopping only at keys whose value is a scalar or sits inside an array. Each example below is the verbatim output of the command shown, run against the file shown. Query outputs are pretty-printed with the timing block omitted.
Read nested exporter objects as a skeleton
exporters.jsonc configures a telemetry pipeline; its otlp exporter is nested one level inside the top-level exporters key, with two // comments documenting the retry and compression choices.
$ act query skeleton exporters.jsonc
Before
{
// otlp is the primary collector; batches are gzip-compressed in transit
"exporters": {
"otlp": {
"endpoint": "collector.internal:4317",
"compression": "gzip",
"timeout_ms": 3000
}
},
"pipelines": [
{ "name": "traces", "batch_size": 512, "flush_ms": 200 },
{ "name": "metrics", "batch_size": 1024, "flush_ms": 500 }
],
// retry applies to every exporter above; backoff doubles each attempt
"retry": {
"max_attempts": 5,
"backoff_ms": 1000
}
}
Output
{
"type": "Skeleton",
"declarations": [
{
"kind": "module",
"name": "exporters",
"range": {
"start": {
"file": "exporters.jsonc",
"line": 3,
"column": 16,
"byte_offset": 92
},
"end": {
"file": "exporters.jsonc",
"line": 9,
"column": 4,
"byte_offset": 216
}
},
"name_range": {
"start": {
"file": "exporters.jsonc",
"line": 3,
"column": 4,
"byte_offset": 80
},
"end": {
"file": "exporters.jsonc",
"line": 3,
"column": 13,
"byte_offset": 89
}
}
},
{
"kind": "module",
"name": "otlp",
"range": {
"start": {
"file": "exporters.jsonc",
"line": 4,
"column": 13,
"byte_offset": 106
},
"end": {
"file": "exporters.jsonc",
"line": 8,
"column": 6,
"byte_offset": 212
}
},
"name_range": {
"start": {
"file": "exporters.jsonc",
"line": 4,
"column": 6,
"byte_offset": 99
},
"end": {
"file": "exporters.jsonc",
"line": 4,
"column": 10,
"byte_offset": 103
}
}
},
{
"kind": "module",
"name": "pipelines",
"range": {
"start": {
"file": "exporters.jsonc",
"line": 10,
"column": 16,
"byte_offset": 233
},
"end": {
"file": "exporters.jsonc",
"line": 13,
"column": 4,
"byte_offset": 363
}
},
"name_range": {
"start": {
"file": "exporters.jsonc",
"line": 10,
"column": 4,
"byte_offset": 221
},
"end": {
"file": "exporters.jsonc",
"line": 10,
"column": 13,
"byte_offset": 230
}
}
},
{
"kind": "module",
"name": "retry",
"range": {
"start": {
"file": "exporters.jsonc",
"line": 15,
"column": 12,
"byte_offset": 449
},
"end": {
"file": "exporters.jsonc",
"line": 18,
"column": 4,
"byte_offset": 500
}
},
"name_range": {
"start": {
"file": "exporters.jsonc",
"line": 15,
"column": 4,
"byte_offset": 441
},
"end": {
"file": "exporters.jsonc",
"line": 15,
"column": 9,
"byte_offset": 446
}
}
}
]
}
The skeleton reports exporters, pipelines, and retry at the top level, plus otlp nested one level inside exporters; the // comments produce no declarations of their own.
List every configuration key as symbols
The pipelines array holds two entries, traces and metrics, each repeating the same batch_size and flush_ms keys.
$ act query symbols exporters.jsonc
Before
{
// otlp is the primary collector; batches are gzip-compressed in transit
"exporters": {
"otlp": {
"endpoint": "collector.internal:4317",
"compression": "gzip",
"timeout_ms": 3000
}
},
"pipelines": [
{ "name": "traces", "batch_size": 512, "flush_ms": 200 },
{ "name": "metrics", "batch_size": 1024, "flush_ms": 500 }
],
// retry applies to every exporter above; backoff doubles each attempt
"retry": {
"max_attempts": 5,
"backoff_ms": 1000
}
}
Output
{
"type": "Symbols",
"symbols": [
{
"name": "\"exporters\"",
"kind": "field",
"range": {
"start": {
"file": "exporters.jsonc",
"line": 3,
"column": 3,
"byte_offset": 79
},
"end": {
"file": "exporters.jsonc",
"line": 3,
"column": 14,
"byte_offset": 90
}
},
"visibility": "unknown"
},
{
"name": "\"otlp\"",
"kind": "field",
"range": {
"start": {
"file": "exporters.jsonc",
"line": 4,
"column": 5,
"byte_offset": 98
},
"end": {
"file": "exporters.jsonc",
"line": 4,
"column": 11,
"byte_offset": 104
}
},
"visibility": "unknown"
},
{
"name": "\"endpoint\"",
"kind": "field",
"range": {
"start": {
"file": "exporters.jsonc",
"line": 5,
"column": 7,
"byte_offset": 114
},
"end": {
"file": "exporters.jsonc",
"line": 5,
"column": 17,
"byte_offset": 124
}
},
"visibility": "unknown"
},
{
"name": "\"compression\"",
"kind": "field",
"range": {
"start": {
"file": "exporters.jsonc",
"line": 6,
"column": 7,
"byte_offset": 159
},
"end": {
"file": "exporters.jsonc",
"line": 6,
"column": 20,
"byte_offset": 172
}
},
"visibility": "unknown"
},
{
"name": "\"timeout_ms\"",
"kind": "field",
"range": {
"start": {
"file": "exporters.jsonc",
"line": 7,
"column": 7,
"byte_offset": 188
},
"end": {
"file": "exporters.jsonc",
"line": 7,
"column": 19,
"byte_offset": 200
}
},
"visibility": "unknown"
},
{
"name": "\"pipelines\"",
"kind": "field",
"range": {
"start": {
"file": "exporters.jsonc",
"line": 10,
"column": 3,
"byte_offset": 220
},
"end": {
"file": "exporters.jsonc",
"line": 10,
"column": 14,
"byte_offset": 231
}
},
"visibility": "unknown"
},
{
"name": "\"name\"",
"kind": "field",
"range": {
"start": {
"file": "exporters.jsonc",
"line": 11,
"column": 7,
"byte_offset": 241
},
"end": {
"file": "exporters.jsonc",
"line": 11,
"column": 13,
"byte_offset": 247
}
},
"visibility": "unknown"
},
{
"name": "\"batch_size\"",
"kind": "field",
"range": {
"start": {
"file": "exporters.jsonc",
"line": 11,
"column": 25,
"byte_offset": 259
},
"end": {
"file": "exporters.jsonc",
"line": 11,
"column": 37,
"byte_offset": 271
}
},
"visibility": "unknown"
},
{
"name": "\"flush_ms\"",
"kind": "field",
"range": {
"start": {
"file": "exporters.jsonc",
"line": 11,
"column": 44,
"byte_offset": 278
},
"end": {
"file": "exporters.jsonc",
"line": 11,
"column": 54,
"byte_offset": 288
}
},
"visibility": "unknown"
},
{
"name": "\"name\"",
"kind": "field",
"range": {
"start": {
"file": "exporters.jsonc",
"line": 12,
"column": 7,
"byte_offset": 303
},
"end": {
"file": "exporters.jsonc",
"line": 12,
"column": 13,
"byte_offset": 309
}
},
"visibility": "unknown"
},
{
"name": "\"batch_size\"",
"kind": "field",
"range": {
"start": {
"file": "exporters.jsonc",
"line": 12,
"column": 26,
"byte_offset": 322
},
"end": {
"file": "exporters.jsonc",
"line": 12,
"column": 38,
"byte_offset": 334
}
},
"visibility": "unknown"
},
{
"name": "\"flush_ms\"",
"kind": "field",
"range": {
"start": {
"file": "exporters.jsonc",
"line": 12,
"column": 46,
"byte_offset": 342
},
"end": {
"file": "exporters.jsonc",
"line": 12,
"column": 56,
"byte_offset": 352
}
},
"visibility": "unknown"
},
{
"name": "\"retry\"",
"kind": "field",
"range": {
"start": {
"file": "exporters.jsonc",
"line": 15,
"column": 3,
"byte_offset": 440
},
"end": {
"file": "exporters.jsonc",
"line": 15,
"column": 10,
"byte_offset": 447
}
},
"visibility": "unknown"
},
{
"name": "\"max_attempts\"",
"kind": "field",
"range": {
"start": {
"file": "exporters.jsonc",
"line": 16,
"column": 5,
"byte_offset": 455
},
"end": {
"file": "exporters.jsonc",
"line": 16,
"column": 19,
"byte_offset": 469
}
},
"visibility": "unknown"
},
{
"name": "\"backoff_ms\"",
"kind": "field",
"range": {
"start": {
"file": "exporters.jsonc",
"line": 17,
"column": 5,
"byte_offset": 478
},
"end": {
"file": "exporters.jsonc",
"line": 17,
"column": 17,
"byte_offset": 490
}
},
"visibility": "unknown"
}
]
}
symbols lists all 15 keys in the file, including the repeated name, batch_size, and flush_ms from both pipeline entries, each reported as a field.
Query
18 query tools, the same on every supported language. Descriptions live in the shared reference: /docs/query-tools.
callers control_flow data_flow definition diagnostics effect_closure effect_summary fix_auto get_type graph import_organize interface mutations references repo_outline skeleton symbols symbols_batch