Pruned API code to test