This function has been written to accept only geometry; the test is here:
https://github.com/irstv/H2GIS/blob/master/h2spatial-ext/src/main/java/org/h2gis/h2spatialext/function/spatial/properties/ST_Extent.java#L61
We should be able to accept also VarChar and cast to geometry by modifying the code.But I don't know if this is usefull..