parse response correctly