@staticmethod
  def parse_response(resp):
    if resp.status_code in [200, 201, 202]:
      return resp.json()
    elif resp.status_code == 204:
      return None
    elif resp.status_code == 400:
      raise error.BadRequestError(resp.text)
    elif resp.status_code == 401:
      raise error.UnauthorizedError(resp.text)
    elif resp.status_code == 403:
      raise error.ForbiddenError(resp.text)
    elif resp.status_code == 404:
      raise error.NotFoundError(resp.text)
    elif resp.status_code == 429:
      raise error.TooManyRequestsError(resp.text)
    elif resp.status_code == 503:
      raise error.ServiceUnavailableError(resp.text)
    else:
      raise error.OptimizelyError(resp.text)
Perform operations specific to the router type in preparation for
dataset/ETHPy150Open optimizely/optimizely-client-python/optimizely/client.py/Client.parse_response--crossover with--dataset/ETHPy150Open openstack/networking-cisco/networking_cisco/plugins/cisco/l3/drivers/__init__.py/L3RouterBaseDriver.create_router_precommit