fix apitest and make it work with integers