working before changing bubbles fn to work with api