toJson method
The wire form. Keys here are what every surface shows and what an agent parses, so they are part of the action's contract.
Implementation
@override
Map<String, Object?> toJson() => {
'kind': kind,
'address': address.toString(),
if (path != null) 'path': path,
if (text != null) 'text': text,
if (meta.isNotEmpty) 'meta': meta,
};