DynamoVisualProgramming.ZeroTouchLibrary by Autodesk

<PackageReference Include="DynamoVisualProgramming.ZeroTouchLibrary" Version="1.0.0-beta2" />

 TypeSpecificSerializers

public Func<GeometryDataSerializer, IDesignScriptEntity> GetReader(string geomType)

public void RegisterSerializers<T>(string type, Func<GeometryDataSerializer, IDesignScriptEntity> reader) where T : IDesignScriptEntity

public IGeometryDataCollection WriteEntity(IDesignScriptEntity entity, out string typeName)

Finds the underlying interface implementation type and uses appropriate writer to serialize the given entity.