code: def _call_resource_method(self, cls, id, method_name, data):
          
  
          if cls.api_root != "a":
              url_path = "/{name}/{id}/{method}".format(
                  name=cls.collection_name, id=id, method=method_name
              )
          else:
              # Management method.
              url_path = "/a/{app_id}/{name}/{id}/{method}".format(
                  app_id=self.app_id, name=cls.collection_name, id=id, method=method_name
              )
  
          url = URLObject(self.api_server).with_path(url_path)
          converted_data = convert_datetimes_to_timestamps(data, cls.datetime_attrs)
  
          session = self._get_http_session(cls.api_root)
          response = session.post(url, json=converted_data)
  
          result = _validate(response).json()
          return cls.create(self, **result)
docs: POST a dictionary to an API method,
          for example /a/.../accounts/id/upgrade