Changed how api address is specified.