tweaks to support the JS API.