api get works correctly