@override Map<String, dynamic> toJson() => { 'type': type, 'tool_use_id': toolUseId, if (content != null) 'content': content, if (isError) 'is_error': isError, };