WIP getting api working