Extract response parsing into a separate method.