Do the same way we do in mica_export