code: def send_request(self, method, params):
          
          msg, msgid = self._encoder.create_request(method, params)
          self._send_message(msg)
          self._pending_requests.add(msgid)
          return msgid
docs: Send a request