code: async def capability_check(self, optional=None, required=None):
          
  
          self._check_receive_loop()
          # If the returned response is an error, self.query will raise an error
          await self.query(
              "version", {"optional": optional or [], "required": required or []}
          )
docs: Perform a server capability check.