small update to httpApi.js