pull from the window.location to get api destination