code: def unfederate(self, serverId):
          
          url = self._url + "/servers/{serverid}/unfederate".format(
              serverid=serverId)
          params = {"f" : "json"}
          return self._get(url=url,
                           param_dict=params,
                           proxy_port=self._proxy_port,
                           proxy_url=self._proxy_ur)
docs: This operation unfederates an ArcGIS Server from Portal for ArcGIS