starting to build js wrappers for persistence API