@override Object toJson() => { 'parent': parent, 'endpoint': ?endpoint?.toJson(), if (endpointId.isNotDefault) 'endpointId': endpointId, };