Send text message to telegram user. Text message should be markdown
        formatted.

        :param text: markdown formatted text.
        :return: status code on error.
351113
def send_text(self, text):
        
        if not self.is_token_set:
            raise ValueError('TelepythClient: Access token is not set!')

        stream = StringIO()
        stream.write(text)
        stream.seek(0)

        return self(stream)
1057422
def SendTextMessage(self, Text):
        
        if self.Type == cctReliable:
            self.Stream.Write(Text)
        elif self.Type == cctDatagram:
            self.Stream.SendDatagram(Text)
        else:
            raise SkypeError(0, 'Cannot send using %s channel type' & repr(self.Type))
1334641
def setText(self, text):
        
        self._text = text
        
        # update the label
        btn = self.widget()
        if btn:
            btn.setText(text)
1154813
def direct_reply(self, text):
        
        channel_id = self._client.open_dm_channel(self._get_user_id())
        self._client.rtm_send_message(channel_id, text)
604515
@ObjectiveCName("sendMessageWithMentionsDetect:withText:withMarkdownText:")
    public void sendMessageWithMentionsDetect(@NotNull Peer peer, @NotNull String text, @NotNull String markdownText) {
        sendMessage(peer, text, markdownText, null, true);
    }
554748
def send(self, text):
        
        if text:
            self.send_buffer += text.replace('\n', '\r\n')
            self.send_pending = True
566108
def text(
    body, status=200, headers=None, content_type="text/plain; charset=utf-8"
):
    
    return HTTPResponse(
        body, status=status, headers=headers, content_type=content_type
    )
934835
def debug_text_simple(self, text: str):
        
        self._debug_texts.append(self.to_debug_message(text))
923629
def text(self, text):
        '''
        
        '''

        if text:
            if not isinstance(text, str):
                text = _pformat(text)
            text += '\n\n'
            self.m(
                'add text to mail',
                more=dict(len=len(text))
            )
            self.__message.attach(_MIMEText(text, 'plain', 'UTF-8'))
380478
def sendMessage(self,chat_id,text,parse_mode=None,disable_web=None,reply_msg_id=None,markup=None):
		'''  '''
		payload={'chat_id' : chat_id, 'text' : text, 'parse_mode': parse_mode , 'disable_web_page_preview' : disable_web , 'reply_to_message_id' : reply_msg_id}
		
		if(markup):
			payload['reply_markup']=json.dumps(markup)
			
		response_str = self._command('sendMessage',payload,method='post')
		
		return _validate_response_msg(response_str)
752896
def send_text(self, message, opcode=OPCODE_TEXT):
        

        # Validate message
        if isinstance(message, bytes):
            message = try_decode_UTF8(message)  # this is slower but ensures we have UTF-8
            if not message:
                logger.warning("Can\'t send message, message is not valid UTF-8")
                return False
        elif sys.version_info < (3,0) and (isinstance(message, str) or isinstance(message, unicode)):
            pass
        elif isinstance(message, str):
            pass
        else:
            logger.warning('Can\'t send message, message has to be a string or bytes. Given type is %s' % type(message))
            return False

        header  = bytearray()
        payload = encode_to_UTF8(message)
        payload_length = len(payload)

        # Normal payload
        if payload_length <= 125:
            header.append(FIN | opcode)
            header.append(payload_length)

        # Extended payload
        elif payload_length >= 126 and payload_length <= 65535:
            header.append(FIN | opcode)
            header.append(PAYLOAD_LEN_EXT16)
            header.extend(struct.pack(">H", payload_length))

        # Huge extended payload
        elif payload_length < 18446744073709551616:
            header.append(FIN | opcode)
            header.append(PAYLOAD_LEN_EXT64)
            header.extend(struct.pack(">Q", payload_length))

        else:
            raise Exception("Message is too big. Consider breaking it into chunks.")
            return

        self.request.send(header + payload)
1138567
async def set_reply_markup(msg: Dict, request: 'Request', stack: 'Stack') \
        -> None:
    

    from bernard.platforms.telegram.layers import InlineKeyboard, \
        ReplyKeyboard, \
        ReplyKeyboardRemove

    try:
        keyboard = stack.get_layer(InlineKeyboard)
    except KeyError:
        pass
    else:
        msg['reply_markup'] = await keyboard.serialize(request)
    try:
        keyboard = stack.get_layer(ReplyKeyboard)
    except KeyError:
        pass
    else:
        msg['reply_markup'] = await keyboard.serialize(request)
    try:
        remove = stack.get_layer(ReplyKeyboardRemove)
    except KeyError:
        pass
    else:
        msg['reply_markup'] = remove.serialize()
821019
def post_message(self, channel, text, **kwargs):
        
        if not channel.startswith('#'):
            channel = '#' + channel
        self.params.update({
            'channel': channel,
            'text':    text,
            })
        if kwargs:
            self.params.update(kwargs)
        return FromUrl('https://slack.com/api/chat.postMessage', self._requests)(data=self.params).post()
488024
function sendTextMessage(recipientId, textToSend, token) {
      textMessageData = {
        text:textToSend
      }
      request({
        url: FB_MSG_URL,
        qs: {access_token:token},
        method: 'POST',
        json: {
          recipient: {id:recipientId},
          message: textMessageData,
        }
      }, function(error, response, body) {
        if (error) {
          node.log('Error sending text message: ', error);
        } else if (response.body.error) {
          node.log('Error: ', response.body.error);
        }
      });
    }
885372
def setText( self, text ):
        
        if text is None:
            text = ''
        
        super(XLineEdit, self).setText(projex.text.encoded(self.formatText(text), self.encoding()))
176524
def device_text_string_request(self):
        
        msg = StandardSend(self._address, COMMAND_FX_USERNAME_0X03_0X01)
        self._send_msg(msg)
795474
def debug(self, text):
		
		self.logger.debug("{}{}".format(self.message_prefix, text))