changing bitcoin to use api